Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a matrix format in excel that i need to fill in with a formula.
I was wondering if there was any vba code that could help me with this. Example, Policy Number Name Date 429438 975288 759284 I am going to be using a lookup function to fill in name and date, I was hoping to get code that evaluates the # of fields and rows first then copies in the encompassing cells. Thanks for the help. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
set rng = Range(Cells(2,1),Cells(2,1).End(xldown))
rng.offset(0,1).Formula = "=Vlookup(A2,Sheet2!$A$1:$C4200,2,False))" rng.offset(0,2).Formula = "=Vlookup(A2,Sheet2!$A$1:$C4200,3,False))" -- Regards, Tom Ogilvy wrote in message oups.com... I have a matrix format in excel that i need to fill in with a formula. I was wondering if there was any vba code that could help me with this. Example, Policy Number Name Date 429438 975288 759284 I am going to be using a lookup function to fill in name and date, I was hoping to get code that evaluates the # of fields and rows first then copies in the encompassing cells. Thanks for the help. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Got an extra ")" in there and a 4 instead of a $
set rng = Range(Cells(2,1),Cells(2,1).End(xldown)) rng.offset(0,1).Formula = "=Vlookup(A2,Sheet2!$A$1:$C$200,2,False)" rng.offset(0,2).Formula = "=Vlookup(A2,Sheet2!$A$1:$C$200,3,False)" -- Regards, Tom Ogivly "Tom Ogilvy" wrote in message ... set rng = Range(Cells(2,1),Cells(2,1).End(xldown)) rng.offset(0,1).Formula = "=Vlookup(A2,Sheet2!$A$1:$C4200,2,False))" rng.offset(0,2).Formula = "=Vlookup(A2,Sheet2!$A$1:$C4200,3,False))" -- Regards, Tom Ogilvy wrote in message oups.com... I have a matrix format in excel that i need to fill in with a formula. I was wondering if there was any vba code that could help me with this. Example, Policy Number Name Date 429438 975288 759284 I am going to be using a lookup function to fill in name and date, I was hoping to get code that evaluates the # of fields and rows first then copies in the encompassing cells. Thanks for the help. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How can I transpose nXm matrix to mXn Matrix | Excel Worksheet Functions | |||
The fill feature in Excel that gives option to fill or copy | New Users to Excel | |||
How to fill colour in Excel, it appers No fill in my computer? | Excel Discussion (Misc queries) | |||
excel matrix | Excel Worksheet Functions | |||
If/Then Matrix? Can Excel do this? | Excel Programming |