+ Reply to Thread
Results 1 to 4 of 4

apply formula to all cells in a column

  1. #1
    Registered User
    Join Date
    07-26-2007
    Posts
    3

    apply formula to all cells in a column

    Hi all,

    My first time in using Excel with calculations. Problem is as follows:

    I have three rows: First: beginning date, Second: end date, Third: time difference.

    third is calculated by obviously subtracting second from first. My problem is, I want to apply this formula to all cells in third column. i.e. :

    c3 = b3 - a3

    c4 = b4- a4

    c5 = b5 - a5

    ...

    cn = bn - an

    I need something like a for loop. How do I do that without manually writing the formula seperately to all cells in my third column?

    Thanks in advance..

  2. #2
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    apply formula to all cells in a column

    Try one of these approaches:

    C3: =B3-A3

    Method_1:
    Left-Click and HOLD on the lower right corner of cell C3
    (that corner will have a small black box...and the cursor will turn into a cross when you hover over it.)

    Drag the formula down as far as you need.

    OR
    Method_2:
    Select C3
    From the Excel Main Menu....<edit><copy>
    Click and Hold on C3 and paint down as many cells as you need.
    Press [Enter] to paste the formula

    Note: The cell references will change automatically.
    For more info on Relative/Absolute References...
    Check Excel Help for: relative
    Then select topics about relative references.

    Does that help?

    Regards,

    Ron
    Microsoft MVP (Excel)

  3. #3
    Registered User
    Join Date
    07-26-2007
    Posts
    3
    yeah I found it, drag the black cross on the right bottom of the cell and pull it to the end..

  4. #4
    Registered User
    Join Date
    07-26-2007
    Posts
    3
    Quote Originally Posted by Ron Coderre
    Try one of these approaches:

    C3: =B3-A3

    Method_1:
    Left-Click and HOLD on the lower right corner of cell C3
    (that corner will have a small black box...and the cursor will turn into a cross when you hover over it.)

    Drag the formula down as far as you need.

    OR
    Method_2:
    Select C3
    From the Excel Main Menu....<edit><copy>
    Click and Hold on C3 and paint down as many cells as you need.
    Press [Enter] to paste the formula

    Note: The cell references will change automatically.
    For more info on Relative/Absolute References...
    Check Excel Help for: relative
    Then select topics about relative references.

    Does that help?

    Regards,

    Ron
    Microsoft MVP (Excel)
    I've discovered the first method you've mentioned just as you were posting, thanks anyway and sorry to waste your time..

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1