Search This Blog

Do Case Code

When you have a multiple case which you would want a different action, you can use the Do Case. Do case is very useful code when used wisely.

DO CASE
CASE THISFORM.txtSqlId.VALUE = 1
MESSAGEBOX("Argentina", "Information")
CASE THISFORM.txtSqlId.VALUE = 2
MESSAGEBOX("Bangladesh", "Information")
CASE THISFORM.txtSqlId.VALUE = 3
MESSAGEBOX("Malaysia", "Information")
CASE THISFORM.txtSqlId.VALUE = 4
MESSAGEBOX("Philippines", "Information")
CASE THISFORM.txtSqlId.VALUE = 5
MESSAGEBOX("Taiwan", "Information")
CASE THISFORM.txtSqlId.VALUE = 6
ENDCASE