Hi Jeff: Have you tried sending a Window Message to the message Box? I have 
never used a WindowMessage in, or out, of WE but from the reading about Windows 
Messages it sounds like you can do allot with them. I'm not sure about 
modifying a Button's text after it is displayed but it might be worth a little 
reading and an experiment to see how it works. 
That would be the only possible method of modifying the text of controls once 
displayed and, as you mentioned, the MsgBox buttons are pre-defined so you 
can't do it at design or compile time as far as I know. 
Post up if you try using the Window Message process since that is something I 
was going to try and use until Chip came up with the Foreground constant value 
for my MsgBox which seemed to work for what I needed.
Anyway, I'm interested in the results of your experiments if you go that route.
Rick USA
  ----- Original Message ----- 
  From: Chip Orange 
  To: [email protected] 
  Sent: Saturday, April 30, 2011 11:29 AM
  Subject: RE: MsgBox


  Sorry Jeff; as you say, you'll either need to use the GW toolkit, or take 
your chances, and modify the captions of the buttons by use of an event handler 
after the message box has been displayed.  who knows what visual effects this 
will have if you try this though (I don't know for instance if the "no" button 
is sized to fit this caption, and so what would happen if you inserted a longer 
string).

  Chip




------------------------------------------------------------------------------
  From: Jeff Weiss [mailto:[email protected]] 
  Sent: Friday, April 29, 2011 11:28 AM
  To: [email protected]
  Subject: MsgBox


  Chip,

  That is great.  

  I never saw that 

  vbMsgBoxSetForeground

  anywhere.  Now another question about the MsgBox-is there any way to 
customize the names of the buttons?

  I would like to use the VbYesNo buttons, but change the names to Next and 
Previous.

  I know we can do this with the Window-Eyes toolkit messageBox, but is there 
any way to do it with the MsgBox?

  Thanks,

  Jeff Weiss

   

   

Reply via email to