View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Jim Cone Jim Cone is offline
external usenet poster
 
Posts: 3,290
Default Msgbox Close Button

The X in the top right corner of a message box is not colored red
and there would be no normal reason to remove it.

The "Critical" notice on a message box ( a red X) is created by the
inclusion of the constant "vbCritical" as one of the msgbox arguments.
You can simply remove it or replace it with vbInformation or vbExclamation.
As an example, try both code lines below:

x = MsgBox("This is a test", vbOKCancel + vbCritical, " Test of X")
'---
x = MsgBox("This is a test", vbOKCancel , " Test of X")

'--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"jnf40"
wrote in message
Is there a way to disable the red X on a Msgbox, or would you have to create
a custom userform to do this?