On Sun, Jan 13, 2013 at 9:22 AM, Staffan Tylen <staffan.tylen@gmail.com> wrote:

hex is exactly right.

This is one of the main reasons I dislike auto detection.  After the initDialog in your dialog executes, then auto detection goes through and resets all the controls.  Causing what you see.

I scanned my source tree and found the following:

-- The above doesn't allow public routines to be used!

So it's been commented out, but it was a long ago so can't remember the details.

Yes, the public routines just invoke the standard dialogs.  Many of those dialogs rely on data attributes.  So, if you use them in an application, you can't turn of auto detection for the whole application.  Personally, I never use the public routines, other than the message box routines which don't use data attributes.

So the app is using the default behaviour and the setText already in place is working. But the code I just posted is also using the default behaviour but doesn't work. Guess I need to fiddle around with autoDetection...

Hopefully my other post helped.   setText() always works.  In your other app, you must have invoked setText() after initDialog() had already run.  In your current app, your setText() works in initDialog().  It is just that the framework has set the text back to the empty string.

Mark Miesfeld