View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
Rick Rothstein \(MVP - VB\)[_1536_] Rick Rothstein \(MVP - VB\)[_1536_] is offline
external usenet poster
 
Posts: 1
Default Clearing Immediate window in VBA by code

Did that code work for you? All that happens for me is the date and time are
printed in the Immediate window... nothing is cleared.

Rick


"Mike H" wrote in message
...
very nice i never thought of sendkeys

"Anant Basant" wrote:

try the following code.

Sub DelInImmedate()
Debug.Print Now
Application.SendKeys "^g ^a {DEL}"
End Sub
--
Regards,
Anant


"Madiya" wrote:

I am using some debug.print statements in my code which prints current
value of my variables in the immediate window.
When I run the code again, I have to manually select all and delete
the values from the immediate window.

Is there any way by which I can just run the code to clear the
immediate window?

Thanks and Regards,
Madiya