+ Reply to Thread
Results 1 to 4 of 4

Macro to update formulas in multiple cells.

  1. #1
    Registered User
    Join Date
    12-17-2014
    Location
    toronto
    MS-Off Ver
    2010
    Posts
    16

    Macro to update formulas in multiple cells.

    Could anyone help my out with a macro?

    I have a spreadsheet with cells that contain the following formula or similar: "=+'anothertab'!A27"

    I am looking for a button that when clicked, will add 8 to the following cells: C6, D6, C8, D8, C14, and D14
    and then/also add 1 to the following cells: C17, D17, E26, E27, E34, E35

    For example, if cell C6 contained "=+'anothertab'!A27", the result after pressing the button would be "=+'anothertab'!A35"
    Likewise, if Cell C17 contained "=+'anothertab'!B27", the result after pressing the button would be "=+'anothertab'!B28"


    Currently, I have them all updating by individual buttons, but I would like one button to update all the cells at once. Any help is much appreciated. Thanks!

  2. #2
    Forum Expert
    Join Date
    08-28-2014
    Location
    Texas, USA
    MS-Off Ver
    2016
    Posts
    1,796

    Re: Macro to update formulas in multiple cells.

    Can you show the code you have for each button? No need to re-invent the wheel, combining then should be straightforward.
    I'm interested in starting a career working with VBA, if anyone knows of any opportunities!

  3. #3
    Registered User
    Join Date
    12-17-2014
    Location
    toronto
    MS-Off Ver
    2010
    Posts
    16

    Re: Macro to update formulas in multiple cells.

    Here is sample code for the button to add 8. The problem with this code is that I have to have the cells that I want changed by the button
    highlighted before the button is pressed. I would like the button to automatically change the cells I listed without having to select them.

    Please Login or Register  to view this content.

  4. #4
    Registered User
    Join Date
    12-17-2014
    Location
    toronto
    MS-Off Ver
    2010
    Posts
    16

    Re: Macro to update formulas in multiple cells.

    I think I could modify that code by changing the "Set R" property to something other than 'selection'?

+ 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. [SOLVED] Macro for Deleting Multiple Rows Based of 2 Cells and Update Quantity
    By michaelpair in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-05-2013, 11:02 AM
  2. Update Formulas in cell using Macro
    By vignesh rocks in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-29-2012, 06:09 AM
  3. Excel 2007: Formulas do not update across multiple files
    By cajunlibra in forum Excel General
    Replies: 0
    Last Post: 10-26-2012, 11:13 AM
  4. Glitch - Cells with formulas won't update automatically
    By Clue_Less in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-15-2012, 04:03 PM
  5. Stop update formulas when macro starts then update when complete
    By ruperupe in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-17-2012, 02:42 PM
  6. Formulas to automatically update on multiple sheets
    By tone640 in forum Excel General
    Replies: 7
    Last Post: 06-30-2011, 04:44 AM
  7. Macro to update multiple columns/cells
    By timchen in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-12-2008, 06:19 AM
  8. Replies: 2
    Last Post: 05-12-2008, 09:27 AM

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