I have a text box on a form where a user can enter a customer control number. These numbers are formatted as follows RED12-HK001 or RED12-1Z001 where the characters HK or 1Z represent the account codes and other characters represent equipment (RED), the year (12) and the sequence number (001,002,,,).
What I would like to do is open a specific form depending on whether the user has entered a control number with either the account code HK or 1Z in it. Something like this:
If the control number contains the characters HK then open form a.
If the control number contains the characters 1Z then open form b.
I have no idea how write code that will search for specific characters in a larger string.
Thank you for any help you can provide.
What I would like to do is open a specific form depending on whether the user has entered a control number with either the account code HK or 1Z in it. Something like this:
If the control number contains the characters HK then open form a.
If the control number contains the characters 1Z then open form b.
I have no idea how write code that will search for specific characters in a larger string.
Thank you for any help you can provide.