same row different column

G

Guest

Hi,

I have been looking every where for answers, still learning!!

I have numbers in column A and need to lookup a certain value, from a
userform the number that needs to be looked up should be entered in textbox1
and on the same userform another number is entered in textbox2. When
textbox1's number is found in column A the number in textbox2 should be
inserted in the same row but in column J.

Thanks in advance
Christiaan
 
G

Guest

Dim r as range
set r = columns("A").Find(What:=TextBox1.Value)
r.Offset(,9) = TextBox2.Value
 
G

Guest

Thats great!!! But it gives an error when the number that is being searched
for is not in column A_ "Object variable or With block variable not set"

Much thanks
 
G

Guest

JustLearning said:
Hi,

I have been looking every where for answers, still learning!!

I have numbers in column A and need to lookup a certain value, from a
userform the number that needs to be looked up should be entered in textbox1
and on the same userform another number is entered in textbox2. When
textbox1's number is found in column A the number in textbox2 should be
inserted in the same row but in column J.

Thanks in advance
Christiaan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top