View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
R.VENKATARAMAN R.VENKATARAMAN is offline
external usenet poster
 
Posts: 110
Default macro only run if cell is not empty



try this

Public Sub test()
If Range("A5") < "" Then
(macro name)
Else
MsgBox "A5 is empty Macro does not work."


End If
End Sub

"Pieter" wrote in message
...
i have a macro thats copy a row to a worksheet. To make it perfect i want
that the macro looks if for example Cell A 5 in that row is not empty. If

its
not empty run de macro thats copy the row to a worksheet. If its not empty
that the user got an error windows for example: A5 is empty Macro do not

work.

is this possible...?

greetings.