Jul 17, 2002 #1 chuq2001 Programmer Jul 15, 2002 24 US I want to use a switch statement, but don't know correct syntax. Like this Code: Switch(var) case "NF" xxx=xxx case "MW" xxx=xxx I just need correct syntax Chuck
I want to use a switch statement, but don't know correct syntax. Like this Code: Switch(var) case "NF" xxx=xxx case "MW" xxx=xxx I just need correct syntax Chuck
Jul 17, 2002 #2 Quehay Programmer Feb 6, 2000 804 US Hint: ALT F11 > F1 > Contents > Language Reference > Functions Here's the example found there (just wrap a field name in []'s to be sure it understands: Switch(CityName = "London", "English", CityName _ = "Rome", "Italian", CityName = "Paris", "French" Jeff Roberts Analysis, Design, & Implementation RenaissanceData.com Upvote 0 Downvote
Hint: ALT F11 > F1 > Contents > Language Reference > Functions Here's the example found there (just wrap a field name in []'s to be sure it understands: Switch(CityName = "London", "English", CityName _ = "Rome", "Italian", CityName = "Paris", "French" Jeff Roberts Analysis, Design, & Implementation RenaissanceData.com
Jul 17, 2002 #3 MikeDNova Programmer Jul 3, 2002 86 US think this might be what you want.... Select Case Me![DataType] Case "List" Me.rptPrintComments.Report.Visible = True Me.rptPrintCost.Report.Visible = False Case "Cost" Me.rptPrintComments.Report.Visible = False Me.rptPrintCost.Report.Visible = True End Select this is just an example from some code i was using. i know they call it switch in java. i think its called a select in VB -mike Upvote 0 Downvote
think this might be what you want.... Select Case Me![DataType] Case "List" Me.rptPrintComments.Report.Visible = True Me.rptPrintCost.Report.Visible = False Case "Cost" Me.rptPrintComments.Report.Visible = False Me.rptPrintCost.Report.Visible = True End Select this is just an example from some code i was using. i know they call it switch in java. i think its called a select in VB -mike