22-degrees
Well-known member
Hi all,
I need to provide a feature to allow a user to select one of several options form several different categories which can then be used to construct an If Statement to access data stored in arrays etc and return a result.
Basic Example: (using arbitrary headers and data)
Each header represents a combobox, each box has several options.
[TABLE="width: 500"]
[TR]
[TD]Argue
[/TD]
[TD]Stock
[/TD]
[TD]Oper.
[/TD]
[TD]Amt
[/TD]
[TD]Msg
[/TD]
[/TR]
[TR]
[TD]IF
[/TD]
[TD]Apples[/TD]
[TD]>[/TD]
[TD]1[/TD]
[TD]Order More[/TD]
[/TR]
[TR]
[TD]AND
[/TD]
[TD]Oranges[/TD]
[TD]<[/TD]
[TD]2[/TD]
[TD]Lower Price[/TD]
[/TR]
[TR]
[TD]OR
[/TD]
[TD]Pears[/TD]
[TD]=[/TD]
[TD]3[/TD]
[TD]Give them away[/TD]
[/TR]
[TR]
[TD]ELSE
[/TD]
[TD]Plums[/TD]
[TD]<>[/TD]
[TD]4[/TD]
[TD]Dump them[/TD]
[/TR]
[/TABLE]
So if the user selects "if", "Oranges", "<", "2", "Order More", the statement built would be:
In reality, the number of options and parameters are vastly greater than the demonstration above but I wanted to keep it simple. As I don't have the greatest knowledge of VB.net, I was hoping someone could provide a few keywords that I might research to hopefully achieve what I need.
What kind of options do I have, if any?
I need to provide a feature to allow a user to select one of several options form several different categories which can then be used to construct an If Statement to access data stored in arrays etc and return a result.
Basic Example: (using arbitrary headers and data)
Each header represents a combobox, each box has several options.
[TABLE="width: 500"]
[TR]
[TD]Argue
[/TD]
[TD]Stock
[/TD]
[TD]Oper.
[/TD]
[TD]Amt
[/TD]
[TD]Msg
[/TD]
[/TR]
[TR]
[TD]IF
[/TD]
[TD]Apples[/TD]
[TD]>[/TD]
[TD]1[/TD]
[TD]Order More[/TD]
[/TR]
[TR]
[TD]AND
[/TD]
[TD]Oranges[/TD]
[TD]<[/TD]
[TD]2[/TD]
[TD]Lower Price[/TD]
[/TR]
[TR]
[TD]OR
[/TD]
[TD]Pears[/TD]
[TD]=[/TD]
[TD]3[/TD]
[TD]Give them away[/TD]
[/TR]
[TR]
[TD]ELSE
[/TD]
[TD]Plums[/TD]
[TD]<>[/TD]
[TD]4[/TD]
[TD]Dump them[/TD]
[/TR]
[/TABLE]
So if the user selects "if", "Oranges", "<", "2", "Order More", the statement built would be:
VB.NET:
If oranges < 2 then
msgbox("Order More " & comboStock.selecteditem.tostring)
End if
In reality, the number of options and parameters are vastly greater than the demonstration above but I wanted to keep it simple. As I don't have the greatest knowledge of VB.net, I was hoping someone could provide a few keywords that I might research to hopefully achieve what I need.
What kind of options do I have, if any?
Last edited: