Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro/function to indirectly reference table?
I have a table of employees which is 60 columns of hire month (60
months) by employee (20 rows). Also in the table are salary and start month. I'd like to know how to automatically have a way to (maybe a function or macro) take the salary amount and plug it into the table once at the start of the month table plus the start month. This would then be replicated (by an existing formula in the table) thru the end of the months. I know I've seen something like this before, but I'm at a los of what functions/commands to use to do this. And suggestions on where to start to figure this out? Thanks. Alex Smariga |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro/function to indirectly reference table?
Alex,
Select all the cells that you want to do this with, then type in an equal sign, hit the left arrow once, then hit Ctrl-Enter. This will create references that propogate the value to the right. Enter the value in the cell immediately to the left of the first cell in each row with that formula, and you're done. HTH, Bernie MS Excel MVP "Alex Smariga" wrote in message news:NdncLKSOjoHH-pn2-Rs2osODRkTnJ@localhost... I have a table of employees which is 60 columns of hire month (60 months) by employee (20 rows). Also in the table are salary and start month. I'd like to know how to automatically have a way to (maybe a function or macro) take the salary amount and plug it into the table once at the start of the month table plus the start month. This would then be replicated (by an existing formula in the table) thru the end of the months. I know I've seen something like this before, but I'm at a los of what functions/commands to use to do this. And suggestions on where to start to figure this out? Thanks. Alex Smariga |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro/function to indirectly reference table?
Bernie,
Thanks very much for the technique to create the table with propogating values. Its a lot easier than the way I was doing it. But... once I create the table. . . My next problem is that I would like a function/macro that can look at the "start month" cell (e.g the value of the cell may be 5, since they start in month 5), and can copy the starting salary value in the salary cell to the start column of the table plus "5" columns from the beginning month cell. I am manually doing that right now, entering the starting salary number from the starting month cell after adding the start month to the first cell. But it is tedious and error prone, for the number of spreadsheets I have to maintain. Hence, the wish to have the spreadsheet make the copy for me, since all the data is there. Any hope? Alex On Wed, 23 Jun 2004 00:56:47 UTC, "Bernie Deitrick" <deitbe @ consumer dot org wrote: Alex, Select all the cells that you want to do this with, then type in an equal sign, hit the left arrow once, then hit Ctrl-Enter. This will create references that propogate the value to the right. Enter the value in the cell immediately to the left of the first cell in each row with that formula, and you're done. HTH, Bernie MS Excel MVP "Alex Smariga" wrote in message news:NdncLKSOjoHH-pn2-Rs2osODRkTnJ@localhost... I have a table of employees which is 60 columns of hire month (60 months) by employee (20 rows). Also in the table are salary and start month. I'd like to know how to automatically have a way to (maybe a function or macro) take the salary amount and plug it into the table once at the start of the month table plus the start month. This would then be replicated (by an existing formula in the table) thru the end of the months. I know I've seen something like this before, but I'm at a los of what functions/commands to use to do this. And suggestions on where to start to figure this out? Thanks. Alex Smariga |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro/function to indirectly reference table?
Alex,
Let's say that you have salaries in column A, and the starting month in column B, and your data labels are in row 1, and you actual data starts in row 2. If the value in B1 is a 1, then your data propogation will start in column C, if it is a 2, in column D, etc. In cell C2, enter the formula =IF(COLUMN()=($B2+COLUMN($B2)),$A2,"") and copy as far down and as far right as you need. I tried to make this compatible with what you are doing with my previous post. HTH, Bernie MS Excel MVP "Alex Smariga" wrote in message news:NdncLKSOjoHH-pn2-qg86eqw2DFOH@localhost... Bernie, Thanks very much for the technique to create the table with propogating values. Its a lot easier than the way I was doing it. But... once I create the table. . . My next problem is that I would like a function/macro that can look at the "start month" cell (e.g the value of the cell may be 5, since they start in month 5), and can copy the starting salary value in the salary cell to the start column of the table plus "5" columns from the beginning month cell. I am manually doing that right now, entering the starting salary number from the starting month cell after adding the start month to the first cell. But it is tedious and error prone, for the number of spreadsheets I have to maintain. Hence, the wish to have the spreadsheet make the copy for me, since all the data is there. Any hope? Alex On Wed, 23 Jun 2004 00:56:47 UTC, "Bernie Deitrick" <deitbe @ consumer dot org wrote: Alex, Select all the cells that you want to do this with, then type in an equal sign, hit the left arrow once, then hit Ctrl-Enter. This will create references that propogate the value to the right. Enter the value in the cell immediately to the left of the first cell in each row with that formula, and you're done. HTH, Bernie MS Excel MVP "Alex Smariga" wrote in message news:NdncLKSOjoHH-pn2-Rs2osODRkTnJ@localhost... I have a table of employees which is 60 columns of hire month (60 months) by employee (20 rows). Also in the table are salary and start month. I'd like to know how to automatically have a way to (maybe a function or macro) take the salary amount and plug it into the table once at the start of the month table plus the start month. This would then be replicated (by an existing formula in the table) thru the end of the months. I know I've seen something like this before, but I'm at a los of what functions/commands to use to do this. And suggestions on where to start to figure this out? Thanks. Alex Smariga |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Reference function from an out of sort table | Excel Worksheet Functions | |||
Is it possible to call an excel function indirectly? | Excel Discussion (Misc queries) | |||
What is function that evaluates other functions indirectly? | Excel Worksheet Functions | |||
refer indirectly to Name | Excel Worksheet Functions | |||
Need to indirectly reference columns 26 using A1 notation based on numeric column number- how to? | Excel Worksheet Functions |