Picklistcollection and selection

Hello,

I am facing a little problem, and I can’t see how I could resolve it. Here is my objective : I want a picklistcollection (based on an existing view) to pop up. Once I have selected a document (and only one), I want to open a database, based on fields’ values contained in the first document of the picklistcollection (quite obvious, since I restrict to one document).

The picklistcollection shows a list of documents which form contains two string arrays (one for the server’s name and one for the database’s path). Each time I want to add a database, I can add a line to this string array and write down the server and the database’s path.

The view displayed by the picklistcollection is single categorized, thus each entry would return the same document (that’s not a problem). Since I cannot get the number of the line selected or even the view entry’s number, I can’t open the wanted database, but I can enter a static value (such as StrinArray(x)), which is obvious not referring to the wanted database but only one of the databases referenced in the array contained in the document …

My question is : is there any way to get the view entry’s number selected before clicking on “OK” on the picklistcollection, or is there any way to get a value of the view entry’s line selected ? I could look up with Arraygetindex then …

Thanks by advance for your answers !

Subject: RE: Picklistcollection and selection

Not with PickListCollection – maybe with PickListStrings.

Subject: RE: Picklistcollection and selection

Hi Andre,As you said (I actually thought about it in the meantime) I went for the PickListStrings method, and managed to do something about it.

I first picked a server from the array of servers, then I took the databases contained in the databases array and which server is the only selected, and then I get the index in the array (both servers and databases are aligned when they are linked) with Arraygetindex.

I could then call an OpenDatabase from my workspace. Nicely done at last !! This works perfectly !