Lost Password?


  #1 (permalink)  
Old 08-23-2006, 07:02 AM
TcM's Avatar   
TcM TcM is offline
Code Warrior
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 8,332
Rep Power: 68
TcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of light
Exclamation VB 6.0: Tutorial, Using the MsgBox

Introduction:-

Ok, so here I will show you the basics of the MsgBox Function!

Requirements:-
  • Visual Basic (preferibly 6.0)

Let's begin!

So the most basic method to display a Msgbox is:-

Code:
MsgBox "testing"
This will just show a msg box with an Ok Button!

But lets elaborate more on it:-

Code:
MsgBox "testing", vbOKOnly, "title"
This will display a msgbox with a title with an Ok Button



ok so thats the basic now lets elaborate more on out msgbox

Code:
msg = MsgBox("Testing", vbYesNoCancel)
If msg = vbYes Then Print "Yes Pressed"
If msg = vbNo Then Print "No Pressed"
If msg = vbCancel Then Print "Cancel Pressed"
and

Code:
msg = MsgBox("Testing", vbAbortRetryIgnore)
If msg = vbAbort Then Print "Abort Pressed"
If msg = vbRetry Then Print "Retry Pressed"
If msg = vbIgnore Then Print "Ignore Pressed"
Here a msg box with 3 buttons ( Yes, No, Cancel or Abort, Retry, Ignore) will be shown!
And if you see we added "msg = " here msg ( a variable )will hold in it what button the user pressed! then we are using the if...then so to make different actions, if different buttons are pressed!



ok now lets make an effect to our msgbox!!

Code:
msg = MsgBox("Testing", vbMsgBoxRtlReading + vbCritical)
This will display a msg box Inverted! ( the other way round )
After the "+" you can make every other type of msgbox you want and it will be inverted!!



And there are MUCH more MsgBoxes, I gave you the basics now you can elaborate on it!!

Ending:-
If you have any questions/problems/feedback pls post here and I will sureley Help you!
So I'm waiting for your feedback
Ow and if you want me to make you some tutorials request what you want and I will see what I can do! I will be happy making some tuts here!

Last edited by Jordan; 10-02-2006 at 12:59 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #2 (permalink)  
Old 02-07-2007, 07:34 PM
SlamX's Avatar   
SlamX SlamX is offline
Newbie
 
Join Date: Feb 2007
Posts: 1
Rep Power: 0
SlamX is on a distinguished road
Default

ty, was looking for this. +rep
__________________
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-08-2007, 03:04 PM
TcM's Avatar   
TcM TcM is offline
Code Warrior
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 8,332
Rep Power: 68
TcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of lightTcM is a glorious beacon of light
Default

Thanks for the +rep .
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-27-2007, 01:55 PM
nokomoli nokomoli is offline
Newbie
 
Join Date: Feb 2007
Posts: 2
Rep Power: 0
nokomoli is on a distinguished road
Default

Thank you
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 10-21-2007, 08:38 PM
Noxa Noxa is offline
Newbie
 
Join Date: Oct 2007
Posts: 1
Rep Power: 0
Noxa is on a distinguished road
Default

Thanks for this, ive just started using VB and its helped alot.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #6 (permalink)  
Old 08-31-2008, 02:14 PM
ViRuSS's Avatar   
ViRuSS ViRuSS is offline
Learning Programmer
 
Join Date: Aug 2008
Location: London, England
Posts: 77
Rep Power: 2
ViRuSS will become famous soon enoughViRuSS will become famous soon enough
Default Re: VB 6.0: Tutorial, Using the MsgBox

thx i just needed a little help with msgbox
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 09-07-2008, 03:36 PM
Xav's Avatar   
Xav Xav is offline
Code Warrior
 
Join Date: Mar 2008
Location: On God's Planet
Posts: 9,852
Last Blog:
Web slideshow in JavaS...
Rep Power: 78
Xav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud of
Send a message via MSN to Xav
Default Re: VB 6.0: Tutorial, Using the MsgBox

For anyone using VB.NET, I would advise the MessageBox.Show() function over MsgBox() any day.
__________________


Mr. Xav | Website | Forums | Blog
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 09-07-2008, 05:27 PM
chili5's Avatar   
chili5 chili5 is offline
Code Warrior
 
Join Date: Mar 2008
Age: 15
Posts: 3,632
Rep Power: 32
chili5 is a name known to allchili5 is a name known to allchili5 is a name known to allchili5 is a name known to allchili5 is a name known to allchili5 is a name known to all
Default Re: VB 6.0: Tutorial, Using the MsgBox

Doesn't this tutorial apply to VB.NET also?
__________________
Emo Philips - "My computer beat me at checkers, but I sure beat it at kickboxing."
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 09-08-2008, 01:48 PM
Xav's Avatar   
Xav Xav is offline
Code Warrior
 
Join Date: Mar 2008
Location: On God's Planet
Posts: 9,852
Last Blog:
Web slideshow in JavaS...
Rep Power: 78
Xav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud ofXav has much to be proud of
Send a message via MSN to Xav
Default Re: VB 6.0: Tutorial, Using the MsgBox

Yes, but the MsgBox() function is an old overhand of VB6, so in all cases MessageBox.Show() should be used instead in .NET. This applies to all .NET languages.
__________________


Mr. Xav | Website | Forums | Blog
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
VB 6.0: Tutorial, Making a Port Scanner TcM VB Tutorials 93 Yesterday 08:14 AM
VB 6.0: Tutorial, How to Make Glass2K!! TcM VB Tutorials 12 09-28-2008 12:53 PM
VB 6.0: Tutorial, How to make a GIF in your application TcM VB Tutorials 17 07-01-2008 04:26 PM
VB 6.0: Tutorial, Explaining the VB 6.0 GUI TcM VB Tutorials 1 05-18-2007 11:25 AM
John's Java Tutorial Index John Java Tutorials 0 01-11-2007 04:05 PM


All times are GMT -5. The time now is 11:03 PM.

Contest Stats

WingedPanther ........ 2753.6
Xav ........ 2704
Brandon W ........ 1702.32
John ........ 1207.73
marwex89 ........ 1175.24
morefood2001 ........ 966.05
dcs ........ 655.75
Steve.L ........ 475.59
orjan ........ 418.58
Aereshaa ........ 383.54

Contest Rules

CodeCall Goal

Goal: 100,000 Posts
Complete: 100%


Complete - Celebrate!

Ads