Results 1 to 7 of 7

Thread: msgbox question

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 1999
    Location
    Vilnius, Lithuania
    Posts
    50

    Post

    Now after hard two days of training on vb6
    i know something about it but i have on small
    question

    how to change the caption of messagebox(msgbox)?
    well you know that text in the top

  2. #2
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Post

    The caption is the third argument of a MsgBox!

    Call MsgBox("This is a message, vbOKOnly, "Message")

    Good luck!

    ------------------
    Joacim Andersson
    joacim@programmer.net
    joacim@yellowblazer.com
    www.YellowBlazer.com



  3. #3

    Thread Starter
    Member
    Join Date
    Dec 1999
    Location
    Vilnius, Lithuania
    Posts
    50

    Post

    thanx

    -casparas

  4. #4
    Hyperactive Member venkatraman_r's Avatar
    Join Date
    Jul 1999
    Location
    Chennai, INDIA
    Posts
    284

    Post

    Hi,

    Its a simpler one.

    msgbox "Happy Millenium",vbokonly,"Your Title to appear in the msgbox heading"

    Thats all.

    Regards and happy learning.

    Venkat

  5. #5
    Frenzied Member Mark Sreeves's Avatar
    Join Date
    Nov 1999
    Location
    UK
    Posts
    1,845

    Post

    Joacim, why do you use Call with a message box?


  6. #6
    Guest

    Post

    I think hez calling the msgbox..

  7. #7
    Hyperactive Member
    Join Date
    Jan 1999
    Location
    Rotterdam, Netherlands
    Posts
    386

    Post

    *LOL* yes he's calling the msgbox..

    If you have function which want more then 1 parameter, you can call it like either
    MyFun Par1, Par2, Par3
    or
    Call MyFun(Par1, Par2, Par3)
    If you remove the Call in the 2nd one, you get an error... (instead of call you can also check the return type, for instance, a boolean:
    If MyFun(Par1, Par2, Par3) Then
    ' something
    Else
    ' something else
    End if

    By the way, I assume your keyboard has a F1 key to... if you press that, you get help :-)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width