Results 1 to 4 of 4

Macro to Identify Largest Value Across Columns, Then Subtract Value Held in Other Cell

Threaded View

  1. #1
    Registered User
    Join Date
    08-02-2012
    Location
    Jacksonville, Florida
    MS-Off Ver
    Excel 2010
    Posts
    16

    Macro to Identify Largest Value Across Columns, Then Subtract Value Held in Other Cell

    I need a macro to identify the largest value across columns I2 - AS2. Once found, I need to replace the value with value found minus the value in BQ. The final step would be to highlight the cell that was changed across columns I2 - AS2, then move to the next row and do same until I reach the last row in the worksheet. The number of rows vary each day but the columns do not.

    I have written the attached code, which identifies the largest value in the first row, but I don't know how to replace the value found with the new value and then move to the next row until it reaches the final row for the day.

    In the attached file, my largest value sits in AC2. That value needs to be replaced with 486.17 (1,175.37 - the value in BQ2 of 689.20). The cell should then be highlighted so I can quickly identified what cells have been changed.

    Any help would be appreciated.
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Identified Largest and Smallest VALUES, but need to Identify Location
    By wilburr in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-07-2013, 12:51 AM
  2. How to use and step through cell references held as text in a sheet in a macro
    By runswick in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-22-2013, 01:21 PM
  3. How to write a macro to sort many columns from largest to smallest
    By brainiack18 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-17-2011, 03:51 PM
  4. Formlula: Subtract Largest Number then Average
    By alan_stephen75@ in forum Excel General
    Replies: 5
    Last Post: 10-10-2009, 12:13 PM
  5. Replies: 1
    Last Post: 01-26-2007, 02:25 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