+ Reply to Thread
Results 1 to 3 of 3

Using input box data to create formula

  1. #1
    Registered User
    Join Date
    12-04-2012
    Location
    Atlanta, GA
    MS-Off Ver
    Excel 2007
    Posts
    16

    Exclamation Using input box data to create formula

    Hello,

    I'm creating a macro that ranks data. The formula I currently want to use is the following: =RANK(N2,N$2:N$14,1)+SUMPRODUCT((N2=N$2:N$14)*(M2>M$2:M$14))

    Or in VBA: "=RANK(RC[-1],R2c14:R1000C14,1)+SUMPRODUCT((RC[-1]=R2C14:r1000c14)*(RC[-2]>R2C13:r1000c13))"

    The formula works, but I want it to be dynamic as the last row in this table will be changing every month. The last row of data is not the same as the last row of the table so I can't use that.

    What I was thinking of doing is creating an input box and using the input from there to write the dynamic formula. The code I have is listed below.
    Please Login or Register  to view this content.
    Say I input "14", is there any way to incorporate this number into the formula? Thanks!
    Last edited by smoothliving21; 02-12-2013 at 12:52 PM.

  2. #2
    Registered User
    Join Date
    12-04-2012
    Location
    Atlanta, GA
    MS-Off Ver
    Excel 2007
    Posts
    16

    Re: Using input box data to create formula

    Ok update time. Looks like I can indeed use the last row. Currently I have something that looks like this:
    Please Login or Register  to view this content.
    How do I take those principles and apply it to my final ranking formula that I showed in the first post? Thanks!

  3. #3
    Registered User
    Join Date
    12-04-2012
    Location
    Atlanta, GA
    MS-Off Ver
    Excel 2007
    Posts
    16

    Re: Using input box data to create formula

    bump. any suggestions?

+ 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