View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ray Kanner[_2_] Ray Kanner[_2_] is offline
external usenet poster
 
Posts: 14
Default MsgBox not displaying right away

I have the following code in my program.

myPDF.FileToPDF PSfilename, PDFfilename, ""
If Not FileExists(PDFfilename) Then _
MsgBox PDFfilename & " not created"

It is creating a PDF file from a PS (PostScript) file.
Everything is working fine with one exception.
If "PDFfilename" does not exist, and the code should
print out the message "PDFfilename not created", etc.,
the screen (kind of - the top blue part of the Excel
window) blinks, i.e. the message does not pop right up
(it's as if another program has the focus). I need to
click the mouse within Excel and then the message pops
up. What is happening and how do I get around this
problem?

Thanks

Ray -