Using a formula to copy a value of a cell in another column

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

If I give each column in an array a number value, how do I copy a cell value into the same row and relevant column by entering the number of the column beside the cell that I want to copy. eg making up an excle spreadsheet for a cashbook that looks like this ...............
123 456 789 155
Cheque Date Amount Code Fees Sales Advert Sundr
123456 1/1 100.00 456 100.0
123457 2/1 400.00 789 400.0
123458 3/1 18.00 155 18.0
But I only want to enter cheque no., date, amount and code and it automatically selects the column and enters the amount or a percentage of the amount in that column
 
Hi
not quite sure but do you have a lookup table which matches your code
with a value??
If yes what's the layout of this lookup range?

Probably VLOOKUP or INDEX/MATCH could be the right formula(s) for you
 
Assume your Line 1 - that is (123, 456 789 155) are in cells
E1:H1
Also the Header Columns in Row 2
Enter your data (as below in cells)
A3:D50
In Cell E3 enter: If($D3=E$1,$C3,0)
Copy E3 across and down
That should work...

Treena said:
If I give each column in an array a number value, how do I copy a cell
value into the same row and relevant column by entering the number of the
column beside the cell that I want to copy. eg making up an excle
spreadsheet for a cashbook that looks like this ................
123 456 789 155
Cheque Date Amount Code Fees Sales Advert Sundry
123456 1/1 100.00 456 100.00
123457 2/1 400.00 789 400.00
123458 3/1 18.00 155 18.00
But I only want to enter cheque no., date, amount and code and it
automatically selects the column and enters the amount or a percentage of
the amount in that column
 
Hi
forget my question: didn't read your example carefully enough. Use
JMay's response
 
Of course you know to precede the If($D3=E$1,$C3,0)
with a "=" that is,, =If($D3=E$1,$C3,0)
good,,
 
Back
Top