'Display message if C-Form no exists on cancellation of Sales Invoice'

def validate_c_form_on_cancel(self):

    if ((self.c_form_applicable == u'Yes') and self.c_form_no):
        msgprint(_(u'Please    remove    this    Invoice    {0}    from    C-Form    {1}').format(self.name, self.c_form_no), raise_exception=1)
