View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Noemi Noemi is offline
external usenet poster
 
Posts: 74
Default Remove Modules not working

Hi

I have the following code which should remove modules have it doesn't seem
to work unless I step through it using F8.

Activesheet.cmdSendEmail.Visible = True
Application.SendKeys ("%te" & "^{TAB}" & "{TAB}{DEL}" & "{TAB}{DEL}" &
"{ENTER}")
Call RemoveModules
Cells.Select
Selection.Locked = True
Range("B6").Select
Call ProtectSheet
ActiveWorkbook.SaveAs "C:\Adv.xls"
MsgBox "CLICK EMAIL BUTTON", vbOKOnly

Any suggestions would be very much appreciated.

Thanks
Noemi