Blank OnClick event of command button in modal dialog produces error

  • Thread starter Thread starter Ivan Starr
  • Start date Start date
I

Ivan Starr

Hello, thank you for helping.

I am trying to create a modal, non-data-bound dialog that will return a list
of record IDs.

While trying to write it I got the following error: "Statement invalid
outside type block".
There were no statements! I noticed that there was no error clicking just
the button with no OnClick before I created the OnClick event. The Modal
and Popup properties are both Yes.

Why is this happening? Any idea??


And in general, what is the best way to call a modal, custom, non-data-bound
dialog from code and then retrieve an array of results (in this case an
array of strings)?

Thank you oh helpful and knowledgeable one(s).

Ivan
 
You don't need Modal and Popup set. Once Modal is set,
the form shows up over everything else and will keep
focus until you close it. And actually you don't even
need the Modal option set either.

You can specify acDialog when you call the form - I
presume you are doing this from code.

To get the data back, since it is modal and will not lose
focus until it is closed, you have to save the info to
some global variable. j.
 
Back
Top