View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Bernard Liengme[_2_] Bernard Liengme[_2_] is offline
external usenet poster
 
Posts: 563
Default Excel 2003 + macro

Sub Somename()
If UCASE(Range("D4")) = "NO" Then
msgbox "Printer mismatch"
Exit Sub
End If

existing code
End Sub

best wishes
--
Bernard Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme

"Neil Holden" wrote in message
...
I want to place some code at the start of my macro.

If D34 = no then a message box "Your printer code doesnt match" end macro
else yes run the macro.

Please help.