Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default use the range value from a cell to update the cell with data

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.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default use the range value from a cell to update the cell with data

Sub place_it()
value01 = 20
value02 = 13
value03 = 123.456
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759


"wvan" wrote:

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.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default use the range value from a cell to update the cell with data

Thank you. How do I get the value for instance from a4 to replace the
current value 20 you assigned?


"Gary''s Student" wrote:

Sub place_it()
value01 = 20
value02 = 13
value03 = 123.456
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759


"wvan" wrote:

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.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default use the range value from a cell to update the cell with data

Thank you. How do I get the value, for instance from cell a4 to replace the
current value 20 you assigned?

"Gary''s Student" wrote:

Sub place_it()
value01 = 20
value02 = 13
value03 = 123.456
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759


"wvan" wrote:

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.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default use the range value from a cell to update the cell with data

Sub place_it()
value01 = Range("A1").Value
value02 = Range("A2").Value
value03 = Range("A3").Value
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759


  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default use the range value from a cell to update the cell with data

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.

"Gary''s Student" wrote:

Sub place_it()
value01 = Range("A1").Value
value02 = Range("A2").Value
value03 = Range("A3").Value
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759

  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default use the range value from a cell to update the cell with data

Cells() needs two arguments, Range() only needs one.
--
Gary''s Student - gsnu200759


"wvan" wrote:

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.

"Gary''s Student" wrote:

Sub place_it()
value01 = Range("A1").Value
value02 = Range("A2").Value
value03 = Range("A3").Value
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default use the range value from a cell to update the cell with data

Just perfect, thanks so much.

"Gary''s Student" wrote:

Cells() needs two arguments, Range() only needs one.
--
Gary''s Student - gsnu200759


"wvan" wrote:

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.

"Gary''s Student" wrote:

Sub place_it()
value01 = Range("A1").Value
value02 = Range("A2").Value
value03 = Range("A3").Value
Cells(value01, value02).Value = value03
End Sub

--
Gary''s Student - gsnu200759

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Data Validation lists update orginal cell with list update [email protected] Excel Worksheet Functions 3 July 11th 08 07:56 AM
Summed Cell won't update as I add data into the cell range... mrmer Excel Worksheet Functions 2 February 2nd 06 12:38 AM
Update cell based on date range deversole Excel Discussion (Misc queries) 3 July 6th 05 01:58 PM
Enter data into a cell and dynamically update another cell Tom Ogilvy Excel Programming 0 September 13th 03 12:28 AM
Enter data into a cell and dynamically update another cell Otto Moehrbach[_4_] Excel Programming 0 September 12th 03 10:43 PM


All times are GMT +1. The time now is 10:35 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"