+ Reply to Thread
Results 1 to 3 of 3

VBA- Insert formula up to last row

  1. #1
    Registered User
    Join Date
    10-21-2014
    Location
    Canada
    MS-Off Ver
    MS Office 2010
    Posts
    28

    Exclamation VBA- Insert formula up to last row

    Hi,

    I'm looking to insert a formula onto a sheet using a macro. So far my code works and looks like this

    Please Login or Register  to view this content.
    The problem is that it inserts the formula for the entire column D. I'd like to have the formula start from cell "D1" and finish wherever my last cell in column C is located (for example, "C75" so range "D1:D75").

    Is there any way I can do this? I sort of know how to use LastRow but not sure how to apply it here. Still a newbie

    Thanks!
    Johnathan

  2. #2
    Forum Expert Jakobshavn's Avatar
    Join Date
    08-17-2012
    Location
    Lakehurst, NJ, USA
    MS-Off Ver
    Excel 2007
    Posts
    1,970

    Re: VBA- Insert formula up to last row

    Consider:

    Please Login or Register  to view this content.
    Gary's Student

  3. #3
    Registered User
    Join Date
    10-21-2014
    Location
    Canada
    MS-Off Ver
    MS Office 2010
    Posts
    28

    Re: VBA- Insert formula up to last row

    @Jakobshavn WOW that's perfect! Works great.

    Thank you so much my friend.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 2
    Last Post: 02-03-2015, 09:14 PM
  2. To Find and Insert column and add Formula and copy formula down
    By Akatecho in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-27-2014, 11:52 PM
  3. Replies: 1
    Last Post: 02-02-2013, 02:28 PM
  4. excel formula calculation - how to insert the right formula
    By Manila.Boracay in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-17-2011, 04:21 AM
  5. Replies: 1
    Last Post: 05-26-2010, 03:33 AM
  6. Insert excel formula using VBA......MATCH function is what i want to insert
    By welchs101 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-07-2009, 07:31 PM
  7. Insert row insert formula
    By PhilH1982 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-28-2008, 03:13 PM

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