PDA

View Full Version : vb statement



ShakyOBJ
02-12-2008, 03:25 AM
hi all,
haven't done any vba before, so bear with me, thanks

i like to know what this line means:
Set Target_Date = .Find(what:=DateValue(Search_Date), lookat:=1)

Can Target_Date and Search_Date be null value?

I know its a bit silly to just ask one line.
the main thing is I don't get:
Find(what:=DateValue(Search_Date), lookat:=1)


Thanks

shasur
02-12-2008, 05:05 AM
The code finds Search_Date in the specified range and returns the range it found as Target_Date

Set Target_Date = .Find(what:=DateValue(Search_Date), lookat:=1)

IF the range is not found then Target_Date will be Nothing

If Not Target_Date is nothing then

End if