I am working on a userform that will allow a user to enter a number, that number is then searched for on a worksheet. If the number is found, I want to return the entire row of data that contains the number. (for ease of use the searched for number will be in column A) I would like to have the user see the return data in the userform as label captions but a single list box would be fine. Below is my code:
Code:
private sub command button1_click
Dim FndStr As String
Dim FndVal As Range
Dim as As Worksheet
FndStr = Me.txtNum (textbox)
Set ws = Worksheets ("Tracking")
Set FndVal = Worksheets("Tracking").Range("A3:A3089").Find(What:=FndStr, LookAt:=xlWhole)
If FndVal Is Nothing Then
MsgBox "Number not found"
Else
MsgBox "Number found"
[\code]