Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Help creating a Macro or Formula
I am trying to convert a Quattro Pro formula attached to
a button that is as follows {blockvalues sheet1:G35,@@ ("K10")}. This formula copies the value of Cell G35 located in sheet1 and paste the value in Sheet2 in a column determined by Cell K10. The formula in Cell K10 is ="sheet2:G"&A5. As the entry in Cell A5 is changed so does the cell address for the values to be pasted. Example Cell A5 has a value of 1 Cell K10 will show an address of Sheet2:G1 If Cell A5 has a value of 2 Cell K10 will show Sheet:G2, etc. The trouble that I am having is how to tell the macro or formula to copy cell G35 then go to cell K10 to find out where to paste the results in Sheet2 column G. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Help creating a Macro or Formula
Put this macro in a regular code module and assign it to the button:
Sub paste() Dim r As Long r = Sheet2.Range("A5").Value Sheet2.Range("G" & r).Value = Sheet1.Range("G35").Value End Sub Cheers...Mike F " wrote in message ... I am trying to convert a Quattro Pro formula attached to a button that is as follows {blockvalues sheet1:G35,@@ ("K10")}. This formula copies the value of Cell G35 located in sheet1 and paste the value in Sheet2 in a column determined by Cell K10. The formula in Cell K10 is ="sheet2:G"&A5. As the entry in Cell A5 is changed so does the cell address for the values to be pasted. Example Cell A5 has a value of 1 Cell K10 will show an address of Sheet2:G1 If Cell A5 has a value of 2 Cell K10 will show Sheet:G2, etc. The trouble that I am having is how to tell the macro or formula to copy cell G35 then go to cell K10 to find out where to paste the results in Sheet2 column G. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Creating macro for slightly complicated formula | Excel Discussion (Misc queries) | |||
Creating formula or macro | Excel Worksheet Functions | |||
Advice on Creating an Excel Formula or Macro - PLEASE HELP!!!! | Excel Worksheet Functions | |||
Help creating Formula (or macro) | Excel Discussion (Misc queries) | |||
help creating a macro | Excel Programming |