use the range value from a cell to update the cell with data

  • Thread starter Thread starter wvan
  • Start date Start date
W

wvan

I have 3 values. Value one refers to the row number, value 2 referes to the
column number and value 3 is the data I want to put in the cell. I would
like a button to use value 1 and 2 to locate the cell and put value 3 into it.

I can calculate the exact cell using Address function as follows but don't
know the code to update the value in the cell.

Thanks.
 
Sub place_it()
value01 = 20
value02 = 13
value03 = 123.456
Cells(value01, value02).Value = value03
End Sub
 
Thank you. How do I get the value for instance from a4 to replace the
current value 20 you assigned?
 
Thank you. How do I get the value, for instance from cell a4 to replace the
current value 20 you assigned?
 
> Sub place_it()
> value01 = Range("A4").Value
> value02 = 13
> value03 = 123.456
> Cells(value01, value02).Value = value03
> End Sub
 
Sub place_it()
value01 = Range("A1").Value
value02 = Range("A2").Value
value03 = Range("A3").Value
Cells(value01, value02).Value = value03
End Sub
 
Hi again,

A4 = $H$14 (used =ADDRESS(MATCH(B1,A1:A32,1),MATCH(B2,A5:EF5,1))) to
calculate A4
B3 = P1

value01 = Range("A4").Value
value03 = Range("B3").Value
Cells(value01).Value = value03

I get the error "Type Mismatch", can you help me again with this?

Thanks so much.
 

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

Back
Top