Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 325
Default MSGBOX not working

Good afternoon, all,

Has anyone ever come across instances of MSGBOX not displaying, even when
it's obvious that the code is processing the command?
I'm using MSGBOXes to debug some code - some of them work and some of them
don't, thought they all should, as the code goes past them all.
Any thoughts?
Thanks in advance
Pete
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default MSGBOX not working

Hi Peter,

Try putting a breakpoint at the first msgbox and when the code stops, use
the immediate window to check the condition which should trigger the
display. This will also verify that the relevant line is not being bypassed
due to earlier branch in the code - do you have an error handler for
example?


---
Regards,
Norman



"Peter Rooney" wrote in message
...
Good afternoon, all,

Has anyone ever come across instances of MSGBOX not displaying, even when
it's obvious that the code is processing the command?
I'm using MSGBOXes to debug some code - some of them work and some of them
don't, thought they all should, as the code goes past them all.
Any thoughts?
Thanks in advance
Pete



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 325
Default MSGBOX not working

Norman,
I sorted it - I had a SendKeys command that was supposed to send some
{Enter}s to suppress warning messages - unfortunately, whilst they were used
in the application from whiuch i copied the code, they weren't needed in this
one - hence the MsgBox es effectively had their "OK" buttons clicked, so
didn't appear to appear (if you see what I mean)
That'll teach me to take a break more often in the afternoon! :-)
Thanks for your time
Pete

"Norman Jones" wrote:

Hi Peter,

Try putting a breakpoint at the first msgbox and when the code stops, use
the immediate window to check the condition which should trigger the
display. This will also verify that the relevant line is not being bypassed
due to earlier branch in the code - do you have an error handler for
example?


---
Regards,
Norman



"Peter Rooney" wrote in message
...
Good afternoon, all,

Has anyone ever come across instances of MSGBOX not displaying, even when
it's obvious that the code is processing the command?
I'm using MSGBOXes to debug some code - some of them work and some of them
don't, thought they all should, as the code goes past them all.
Any thoughts?
Thanks in advance
Pete




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 325
Default MSGBOX not working

Crazybass2,
Thanks for your advice, but it was something a bit more simple than I
thought - I had a SendKeys command that was supposed to send some {Enter}s to
suppress warning messages - unfortunately, whilst they were used in the
application from whiuch i copied the code, they weren't needed in this one -
hence the MsgBox es effectively had their "OK" buttons clicked, so didn't
appear to appear (if you see what I mean)
That'll teach me to take a break more often in the afternoon and use
application.displayalerts=false! :-)
Thanks for your time
Pete


"crazybass2" wrote:

You can also use F8 to follow the code as it's running.


"Norman Jones" wrote:

Hi Peter,

Try putting a breakpoint at the first msgbox and when the code stops, use
the immediate window to check the condition which should trigger the
display. This will also verify that the relevant line is not being bypassed
due to earlier branch in the code - do you have an error handler for
example?


---
Regards,
Norman



"Peter Rooney" wrote in message
...
Good afternoon, all,

Has anyone ever come across instances of MSGBOX not displaying, even when
it's obvious that the code is processing the command?
I'm using MSGBOXes to debug some code - some of them work and some of them
don't, thought they all should, as the code goes past them all.
Any thoughts?
Thanks in advance
Pete




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Calculate working days but change working week SamB Excel Discussion (Misc queries) 1 September 1st 08 09:17 PM
Msgbox not working davegb Excel Programming 13 November 9th 05 09:46 PM
MsgBox Grey Newt Excel Programming 0 April 8th 04 12:01 AM
Adding sales from a non working day to the previous working day Alex Excel Programming 1 September 19th 03 08:48 AM
MsgBox Dave Peterson[_3_] Excel Programming 0 July 23rd 03 02:11 AM


All times are GMT +1. The time now is 02:13 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"