View Full Version : Showing titles on MsgBox

Feb 11, 2009, 03:11 AM
I need to show the titles on MsgBox.
i used the code:

dim value as integer = MsgBox( "Message Text", 0, "Message Title")

But the title is not showing in the message box.
How can I display the title?

Thanks in advance

Feb 11, 2009, 03:03 PM
What language/platform is this for?

It might help to know what you are developing in.

Feb 11, 2009, 09:27 PM
It looks like Visual Basic or VBScript...which brings up the question of why you'd ask the question on a Mac forum (as far as I know, neither run on Macs). If it is something VB-related, though, I don't know why the title isn't showing because it looks like you have the format right.

Feb 11, 2009, 10:06 PM
I'm developing a REALBasic application in Tiger

Feb 12, 2009, 12:49 AM
OK, according to the REALBasic documentation for MsgBox:

Optional text displayed in the Title bar (Windows and Linux).
Title is not displayed on Macintosh.
The same appears to be true for the MessageDialog object, I'm not sure why but I guess some kind of interface convention. You may have to create your own custom dialog box class in this case if you really need a title on Mac.

Feb 12, 2009, 04:12 AM
Mac msgboxes don't have titles so as above says you'll need to make your own.

You could make it a new standard window, disable grow icon and closebox, and just add the button and statictext yourself.

Pretty simple:

yourWindow.show to display the window,

And in the "Ok" pushbutton's action event handler just add yourWindow.close