QUOTE(zakary @ 19 Mar, 2008 - 08:21 AM)

not sure what you mean. are you looking to display the messagebox in a form or is it a Textbox displaying your message on the form.
Lets assume I have a form where all my controls are and there is a textbox within that form. Lets also assume this textbox should only have integers put into it (no alpha characters, or numbers with a decimal).
If a user enters some invalid value, I throw an exception (myToolException, for instance).
When I catch the exception, I just show a messagebox that says something like "Invalid textbox input" or something like that.
However, right now, these messageboxes appear BELOW the main form.
Because its an exception, it pretty much halts all user input until the user selects "OK" on the messagebox. But because its below the main form, people dont often see it (and then they get frustrated).
But the thing is, it doesn't happen EVERY time, only sometimes. Sometimes the error pops up in front of the main form, but other times it doesn't.
Thoughts?