Modal vs. Modeless Dialogs

Modal vs. Modeless Dialogs

Anonymous
Not applicable
268 Views
1 Reply
Message 1 of 2

Modal vs. Modeless Dialogs

Anonymous
Not applicable
I have a dialog class that contains a member of type AcDbVoidPtrArray*. A
pointer is passed to the dialog object during construction that points to an
external AcDbVoidPtrArray object. The dialog works fine as a Modal and the
external AcDbVoidPtrArray object retains its logical length and other
parameters. This is not the case when I change the dialog to Modeless. The
dialog creates and shows fine, but the AcDbVoidPtrArray* member (the object
pointed to I mean) does not retain its logical length and other parameters.
Again, all I have done is changed the dialog from a modal to a modeless
through the few appropriate lines of code.
Generally speaking, what are the nuances between modal and modeless dialogs?
I understand how to create, show/hide, and destroy modeless dialogs, but
there must be something else going on that I do not understand. Thank you in
advance for your enlightenment.
0 Likes
269 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Modal dialogs teke the full focus, you can't edit anything else in your
Applicatiuon except the dialog. Modeless dialogs let you edit other
parts of your application, they are floating.

So in you case, it is likely that your array gets modified from some
other part of the application.

HTH,
Andy

"Dan Engebretson" schrieb:

> I have a dialog class that contains a member of type
> AcDbVoidPtrArray*. A pointer is passed to the dialog object during
> construction that points to an external AcDbVoidPtrArray object. The
> dialog works fine as a Modal and the external AcDbVoidPtrArray
> object retains its logical length and other parameters. This is not
> the case when I change the dialog to Modeless. The dialog creates
> and shows fine, but the AcDbVoidPtrArray* member (the object pointed
> to I mean) does not retain its logical length and other parameters.
> Again, all I have done is changed the dialog from a modal to a
> modeless through the few appropriate lines of code. Generally
> speaking, what are the nuances between modal and modeless dialogs? I
> understand how to create, show/hide, and destroy modeless dialogs,
> but there must be something else going on that I do not understand.
> Thank you in advance for your enlightenment.
>
0 Likes