russkie
10-21-2005, 11:16 AM
Hello,
In the macro i have a Var that hold the range:
Dim InvCell As Range
Dim ItemFound(10, 2), i As Long
Dim RmmbrItem As Range
Set WS1 = Worksheets("Sheet1")
With WS1.Range("B:B")
Set InvCell = .Find(scanned, lookat:=xlWhole)
If Not InvCell Is Nothing Then
Firstaddress = InvCell.address
Set RmmbrItem = InvCell
Do
Set InvCell = .FindNext(InvCell)
If Not InvCell Is Nothing Then
i = i + 1
ItemFound(i, 1) = InvCell.Value
ItemFound(i, 2) = InvCell.Offset(0, -1).Value
End If
Loop While Not InvCell Is Nothing And InvCell.address <> Firstaddress
End If
End With
Cool.
Now, Paste all the information in ItemFound to some cells... Grab that information with a Userform. User Pick one of them. Lovely..
But now, I need "InvCell" to be assigned to the range of the item the user selected in the Form. I am bamboozeled(wtf?)
In the macro i have a Var that hold the range:
Dim InvCell As Range
Dim ItemFound(10, 2), i As Long
Dim RmmbrItem As Range
Set WS1 = Worksheets("Sheet1")
With WS1.Range("B:B")
Set InvCell = .Find(scanned, lookat:=xlWhole)
If Not InvCell Is Nothing Then
Firstaddress = InvCell.address
Set RmmbrItem = InvCell
Do
Set InvCell = .FindNext(InvCell)
If Not InvCell Is Nothing Then
i = i + 1
ItemFound(i, 1) = InvCell.Value
ItemFound(i, 2) = InvCell.Offset(0, -1).Value
End If
Loop While Not InvCell Is Nothing And InvCell.address <> Firstaddress
End If
End With
Cool.
Now, Paste all the information in ItemFound to some cells... Grab that information with a Userform. User Pick one of them. Lovely..
But now, I need "InvCell" to be assigned to the range of the item the user selected in the Form. I am bamboozeled(wtf?)