Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating a random message box on screen

Status
Not open for further replies.

harjitgill

IS-IT--Management
Jul 11, 2003
22
0
0
GB

Hello all,

I am a newbie to VB and i am attempting to create a random message box on screen where the message box displays at a random location on screen and the user has to click the OK button rather than pressing the keyboard. If any one can help it would be appreciated.

Thanks
 
I'd say it would be easiest to do this with a form made to look like a msgbox.

You will be able to control how the form is closed (i.e. with the mouse not the keyboard) and you will be able to set the position of the form when it is opened.

Hope this helps

HarleyQuinn
---------------------------------
Get the most out of Tek-Tips, read FAQ222-2244 before posting.
 
thanks for the info but do i use the msgbox function as i would like to use the wscript.shell rather than compiling it to an EXE file
 
You can't make msgbox appear in a prescribed place on the screen. It appears in the middle. You could attempt to use API calls to grab the window handle and move it once it comes up if you like.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top