Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I just recorded a macro for which one of the steps is a rather complicated
ISNUMBER/MATCH function: ActiveCell.FormulaR1C1 = _ "=IF(AND(ISNUMBER(MATCH(LEFT(RC[-18],3),'[ELR expense account identification.xls]Sheet1'!R2C1:R12C1,0)),ISNUMBER(MATCH(RC[-17],'[Frank''s expense codes--GDCS and non-GDCS.xls]Sheet1'!R2C1:R39C1,0))),""Extract"","""")" Two questions: 1) How do I get the macro to always insert this formula into cell T2? 2) Why does the macro recorder record in R1C1 format? Is it possible to get it to record in regular A1 format? Thanks, Dave |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Dave,
1. This is going to put the formula in the activecell, so to make sure the activecell is T2 have a line before it: Range("T2").Select 2. The macro recorder always seems to use R1C1 format - I don't know if there is a setting to change this, but you can always edit the formula after recording the macro. Hope this helps. Pete On Mar 19, 2:27 pm, Dave F wrote: I just recorded a macro for which one of the steps is a rather complicated ISNUMBER/MATCH function: ActiveCell.FormulaR1C1 = _ "=IF(AND(ISNUMBER(MATCH(LEFT(RC[-18],3),'[ELR expense account identification.xls]Sheet1'!R2C1:R12C1,0)),ISNUMBER(MATCH(RC[-17],'[Frank''s expense codes--GDCS and non-GDCS.xls]Sheet1'!R2C1:R39C1,0))),""Extract"","""")" Two questions: 1) How do I get the macro to always insert this formula into cell T2? 2) Why does the macro recorder record in R1C1 format? Is it possible to get it to record in regular A1 format? Thanks, Dave |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Thanks, just figured 1 out, and as for number 2 I suppose it doesn't matter
as long as I know the formula works in A1 format. Dave -- A hint to posters: Specific, detailed questions are more likely to be answered than questions that provide no detail about your problem. "Pete_UK" wrote: Dave, 1. This is going to put the formula in the activecell, so to make sure the activecell is T2 have a line before it: Range("T2").Select 2. The macro recorder always seems to use R1C1 format - I don't know if there is a setting to change this, but you can always edit the formula after recording the macro. Hope this helps. Pete On Mar 19, 2:27 pm, Dave F wrote: I just recorded a macro for which one of the steps is a rather complicated ISNUMBER/MATCH function: ActiveCell.FormulaR1C1 = _ "=IF(AND(ISNUMBER(MATCH(LEFT(RC[-18],3),'[ELR expense account identification.xls]Sheet1'!R2C1:R12C1,0)),ISNUMBER(MATCH(RC[-17],'[Frank''s expense codes--GDCS and non-GDCS.xls]Sheet1'!R2C1:R39C1,0))),""Extract"","""")" Two questions: 1) How do I get the macro to always insert this formula into cell T2? 2) Why does the macro recorder record in R1C1 format? Is it possible to get it to record in regular A1 format? Thanks, Dave |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
My excel macro recorder no longer shows up when recording macro | Excel Discussion (Misc queries) | |||
My excel macro recorder no longer shows up when recording macro | Excel Discussion (Misc queries) | |||
Macro recorder | Excel Discussion (Misc queries) | |||
Macro Recorder-Relative relation | Excel Discussion (Misc queries) | |||
Change result of Macro Recorder | Excel Discussion (Misc queries) |