Populating DialogBox field value from uidoc

I have a goal of popping up a checkbox, allowing the user to select none/some/all and populate the parent uidoc with those options.

I have created a field on my form named fldForms (which computes to itself). My DialogBox form has two fields on it: fldForms (checkbox with a formula for options of FormsList) and FormsList (which is populated via LS in PostOpen, then the uidoc is refreshed to populate the options for fldForms).

This works except for one thing: if I make a choice and then open a new DialogBox to alter my selection, the checkbox doesn’t know about my previous selections. I would like to be able to edit my current choices rather than just reselecting everything. Can anyone lend me a hand here?

Subject: Populating DialogBox field value from uidoc

Store the most recently selected options in a field on your main document. When the dialog box is called, copy that field from your main document to the document behind your dialog box.

Subject: RE: Populating DialogBox field value from uidoc

Thanks. This worked.

I created a field on my main document named tmpTrackForms which calculates to fldTrackForms. The same field on my dialog form calculates to itself. Finally I have the following in my Post Open code:

Call Source.FieldSetText(“fldTrackForms”, Source.FieldGetText(“tmpTrackForms”))

Subject: Populating DialogBox field value from uidoc

If I’m understanding correctly, setting the default value of the fldForms field on your dialog form to itself should do it, since the dialog box is just displaying the currently-open document in a different form.

Subject: RE: Populating DialogBox field value from uidoc

Just getting back to this. Hopefully someone is still reading.

Unfortunately, this doesn’t work. I’m not sure if it’s because the field is text on the main form and a checkbox on the dialog, or what is causing this. I didn’t think anything would need to be done to make this work, but apparently it does.

I will investigate the other solution posted and see if I can make any headway.