Someone please explain..

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
jj45410
Junior Coder
Posts: 38
Joined: Tue Nov 18, 2008 8:14 pm

Someone please explain..

Post by jj45410 » Fri Apr 17, 2009 1:22 pm

Code: Select all

Let>YesNo=4

LibFunc>user32,MessageBoxA,r,0,Hello World,Message!,YesNo

If>r=6

MessageModal>You Pressed Yes

else

MessageModal>You Pressed No

endif
Okay, I was looking at this and I just like the message box because you can easily change the name of it and so on. ANYWAY, What is the significance of 6? No where else on the script does a 6 appear but if I change the number the script fails?

What does the R do and what does the 0 do? and is MessageBoxA just a name for it and can be changed to anything or..?

User avatar
Marcus Tettmar
Site Admin
Posts: 7391
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Fri Apr 17, 2009 2:06 pm

Look at the Windows API documentation for MessageBox. It tells you what it returns. My last blog post on using Windows API will also help.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts