ComboBox hidden values

Archived support forum for customers who once purchased a PrimalForms product license. This forum is locked.
User avatar
boyddt_co
Posts: 76
Joined: Mon Dec 17, 2007 5:50 am

ComboBox hidden values

Post by boyddt_co »

I have a list that contains a user friendly site name and a corresponding OU for active directory, such as "Monument, OU=monument,DC=company,DC=local". I want to only display "Monument" in the combobox but pass the OU info through. Can that be done?David

User avatar
davidc
Posts: 5913
Joined: Thu Aug 18, 2011 4:56 am

ComboBox hidden values

Post by davidc »

I'm no familiar with AD objects, but if it is an object with properties you can use the DisplayMember to select the property to display in the combobox. See the Spotlight on the ComboBox control article for more information. If it is a string, then you will need to manually parse out the information. David
David
SAPIEN Technologies, Inc.

User avatar
boyddt_co
Posts: 76
Joined: Mon Dec 17, 2007 5:50 am

ComboBox hidden values

Post by boyddt_co »

Leaving AD out of the equation for now, if I have the text string "Monument,
OU=monument,DC=company,DC=local", can I display the first part and then pass the second part to the script? I've checked out the spotlight article but it wasn't very clear. Is DisplayMember a property of the control or can I only access it programatically?

User avatar
davidc
Posts: 5913
Joined: Thu Aug 18, 2011 4:56 am

ComboBox hidden values

Post by davidc »

DisplayMember is a property of the ComboBox. You can see how it is set by looking at the definition of the Load-ComboBox helper function. David
David
SAPIEN Technologies, Inc.