Results 1 to 9 of 9

Macro: mixed absolute and relative references for rows

Threaded View

Jendill Macro: mixed absolute and... 08-09-2012, 11:01 PM
rylo Re: Macro: mixed absolute and... 08-09-2012, 11:53 PM
Jendill Re: Macro: mixed absolute and... 08-10-2012, 08:10 AM
rylo Re: Macro: mixed absolute and... 08-12-2012, 06:00 PM
Jendill Re: Macro: mixed absolute and... 08-12-2012, 06:50 PM
rylo Re: Macro: mixed absolute and... 08-12-2012, 07:03 PM
Jendill Re: Macro: mixed absolute and... 08-12-2012, 07:06 PM
rylo Re: Macro: mixed absolute and... 08-12-2012, 07:34 PM
Jendill Re: Macro: mixed absolute and... 08-12-2012, 08:12 PM
  1. #1
    Registered User
    Join Date
    07-31-2012
    Location
    WI
    MS-Off Ver
    Excel 2010
    Posts
    5

    Macro: mixed absolute and relative references for rows

    Hi there,
    I have a problem with the macro I'm trying to set up. I have the equation:

    =MIN(IF($B$2:$B$5000=MAX(IF($B$2:$B$5000<(INT($B2)+1),$B$2:$B$5000,"")),$G$2:$G$5000,""))

    that I want to convert into a macro. I need everything to be an absolute reference except for the $B2 of the INT() function. I want that to change based on the row that the data is being entered into (so row 2 is $B2, row 3 reads $B3, etc). However, here's my problem (and which is why I can't figure out a solution to adapt in other posts), the equation above is located in each cell in column H, but the data being entered is in column G. For example

    A B C D E F G H
    1
    1.2
    1.3 8/6/12
    2

    so using the equation (desired macro) above, H1, H2, and H3 would all populate with 8/6/12.

    As a side note, even though I put "" in my equation, it still returns 0 (in this case, 1/0/1900) if the G cell is blank. Anyone know how to fix that?

    Thanks for your help!

    ---------- Post added at 10:01 PM ---------- Previous post was at 09:58 PM ----------

    Oops! Sorry. My example didn't translate very well. The 1, 1.2, 1.3, and 2 are in B1, B2, B3, and B4, respectively, and the 8/6/12 is in cell G3


    Thanks!
    Last edited by Jendill; 08-12-2012 at 08:16 PM.

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