fill a dropdown at runtime ?

hello here i am again :slight_smile: does anybody know a possibilty to fill an option string during runtime so i can change the values shown by a dropdown box on a form ? i want that after my user chooses a field in another box (most option-fields) he 'll get another field in which he can choose the possible values for this field … *** quack ***

You can’t do this with option fields. Instead You can do it by applying filters depending on the Users choice and then use the filtered record in IF FORM.RUN(FORM::[Formname],FilterRecord) = Action::LookupOK THEN //Lars

Alex : Just a work around : - Fill a temporary table instead - Put your code which launch the form on the OnDrillDown() Trigger of your control ######

yap i am trying a solution with a table and filter and so on … a temporary table would be more nice :slight_smile: … but how i understood a temporary table /record must depend on a exisiting table or ? *** quack ***

Yes temporary table must depend on an existing table. Your temporary table will inherit all the triggers, keys, propertie, … of your actual table So you can VALIDATE, fire triggers, set the keys, etc,etc… ######

Easy solution with just a bit of code: Create the different option dropdown boxes and hide the ones that are not being shown by default… on aftervalidate of the box, set the visible property on the other ones for showing just the ones you’re wanting to… (you can put a box over another one and just show the one you’re wanting to). Use a function to set the values on the record properly… Regards, Alfonso Pertierra (Spain)