PDA

View Full Version : Solved: run if this cell is blank



Djblois
02-22-2007, 01:04 PM
I am using some code to run only if certain conditions are met. It must find Sort by: in cell A4 and then cell D10 must be blank. However I can't get the second portion to work. Here is the code I am using:

Set findString = Range("A4").Find(What:="Sort By:")
If findString Is Nothing The
SalesReports.Show
End
Else
cantrun.Show
End
End If
Next
End If

Set findString = Range("E10").Find(What:="")
If findString Is Nothing Then
cantrun.Show
End
End If

CBrine
02-22-2007, 01:15 PM
Djblois,
I think you might be making this more complex then it needs to be. Try this instead.


if range("A4")<>"Sort By:" then
Sales Reports.show
else
cantrun.show
end if

if len(range("A10"))<>0 then
cantrun.show
End if

HTH
Cal