Hi,
I have a form with a Listbox and a Date/time field. My goal is when a user enters a date into the Date/time field the selection of the Listbox choices should be changed. The Listbox is always populated with the same choices but the selection should be changed.
Let say there are 5 choices to select in the Listbox, A:B:C:D:E. If a user enters today’s date then A, C and D is seleted. If the date is in the past then C and B is selected, if the date is in the future then E is selected. The user must be able to modify the selection.
I put my LS codes into the Exiting event of the Date/time field and it works if I select only 1 choice from the Listbox - Call uiDoc.FieldSetText(ListboxFieldName, “A”) - but cannot figure out how to set multiple selection. I also tried:
Call uiDoc.FieldSetText(ListboxFieldName, “A : B”) , (with comma as well)
Call uiDoc.FieldSetText(ListboxFieldName, {“A” : “B”}) and (with comma as well)
Call uiDoc.FieldSetText(ListboxFieldName, v) where v is a string variable
None of them worked…
Thanks for your help.
Etyien