Dropdown list to equal two values?
In a dropdown list I have an application name a user will choose. This application resides on a server with a different name. But it is a 1:1 ratio. 1app to 1 server.
So app1=serv1, app2=server2
What I would like is that if a user picks app1 from the drop down list, in one section it uses the app1 name, but in another it will need to use the serv1 name to tell my application which server to look at.
The data is being put into a command line. So for example -a=app and -s=server.
So currently I have: " -a "+Edittext$("app1")
but in the same line I need to have a -s (app1 picked but use serv1 name)
One fix would to have two drop down lists, one for app and one for server, but if it can be all tied together in one drop down list since it is a 1:1 ratio, then that would be best. I am just not sure the best way to achieve this.
Re: Dropdown list to equal two values?
Any suggestions or am I stuck with two dropdown lists?
Re: Dropdown list to equal two values?
Hmm.. not really sure what you mean... wever I might have a solution...
First I need to know how the servers are identified... name (string) or ID (value)
Re: Dropdown list to equal two values?
I'm not too sure if I understand what you want to do..
Are the items in the drop-down entered like "app1=server1" and so on? If so, you could use the QuickToken object to split up the application name and the server:
On selection changed
- GetToken$( "Quick Token Object", Combo Select$( "Combo Box" ), "=", 0) (application)
- GetToken$( "Quick Token Object", Combo Select$( "Combo Box" ), "=", 1) (server)
Re: Dropdown list to equal two values?
There is item data (AKA private data per item), but that is numeric only. The easiest way to invisibly store text is to have a seperate list box (with a 1:1 relationship), but you could also use an array.
Re: Dropdown list to equal two values?
The invisible seperate list box sounds like it might be what I need. I kind of wondered if what I was asking wasn't clear enough.
In the dropdown list I have the text app1, app2, app3, app4. Those are seperate choices, not one line.
So in my command line, if a user chooses app1 from the dropdown list, then it would look something like: client.exe " -a "+Edittext$("app1") which really is client.exe -a app1
but the actual command I need is client.exe -a app1 -s server1
So the question is if I have the dropdown list chosen for app1, is there a way(hidden value) that I can have it put in the server1? app1 will always be associated with server1, app2 will be with server2. So it is that 1:1 ratio.