View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default If Statement help

I guess I spoke out of turn. Looks like Charles nailed it.

--
Regards,
Tom Ogilvy

"Charles " wrote in message
...
If its already on the worksheet why do a find. However the following
code assumes you have a userform.

On Error Resume Next
Cells.Find(What:=UserForm1.textbox1.Text).Activate
If Err = "91" Then
Range("a16").EntireRow.Insert shift:=xlDown
End If

HTH
Charles


---
Message posted from http://www.ExcelForum.com/