By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,269 Members | 1,332 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,269 IT Pros & Developers. It's quick & easy.

How to show a modal form, from within another thread?

P: n/a
Hi all,

I have written a program, which uses some threads.
I call thread t from the main thread, and then after some work t must
show a modal window.(e.g. a messagebox) but because t is not the main
thread, the window appears non-Modal.

Is it possible to show a modal form, from within another thread?

thnx in advance.
Nov 15 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi,

You really shouldn't try to interact with UI from within non-ui (main that
is) thread.
Rather use Invoke method to make UI thread do the action.

--
Miha Markic - RightHand .NET consulting & software development
miha at rthand com
www.rthand.com

"MSDousti" <MS******@myrealbox.com> wrote in message
news:bf**************************@posting.google.c om...
Hi all,

I have written a program, which uses some threads.
I call thread t from the main thread, and then after some work t must
show a modal window.(e.g. a messagebox) but because t is not the main
thread, the window appears non-Modal.

Is it possible to show a modal form, from within another thread?

thnx in advance.

Nov 15 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.