+ Reply to Thread
Results 1 to 7 of 7

Can I use an IF function to Autofill?

  1. #1
    Registered User
    Join Date
    10-31-2017
    Location
    Livingston, NJ
    MS-Off Ver
    2016
    Posts
    7

    Can I use an IF function to Autofill?

    Hello everyone,

    I have a simple IF function, but I would like to have the value if false auto-fill from the line above, is that possible? I've looked around the forum but I can't find anything.

    In context, we receive orders from the night before, if they have the same PO number I would assign them the same order number (alpha numeric - Otherwise I could just put the previous cell +1) as the order above, but if they have different PO numbers it would autofill to the next order number.

    So, my IF statement would look something like this (with the auto-fill part of the false value being incorrect - obviously since that's my question):

    IF(G3=G2,C2,AUTOFILL(C2))

    Thank you!
    Last edited by DStravato; 10-31-2017 at 10:34 AM.

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,613

    Re: Can I use an IF function to Autofill?

    How about:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Best Regards,

    Kaper

  3. #3
    Registered User
    Join Date
    10-31-2017
    Location
    Livingston, NJ
    MS-Off Ver
    2016
    Posts
    7

    Re: Can I use an IF function to Autofill?

    Hello Kaper,

    Thank you for the response.

    That doesn't work because C2 is alpha-numberic (IE: CA123456). So if I do C2+1 it ends up coming back as #VALUE!

  4. #4
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,613

    Re: Can I use an IF function to Autofill?

    Is first part always 2 characters?
    If so:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    10-31-2017
    Location
    Livingston, NJ
    MS-Off Ver
    2016
    Posts
    7

    Re: Can I use an IF function to Autofill?

    YES THAT WORKED!!!

    But... can you explain what exactly all that means? I would like to understand as well as use it.

    Thank you.

  6. #6
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,613

    Re: Can I use an IF function to Autofill?

    this is obvious:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    then instead of just (as in post #2)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    we have
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    two leftmost characters of text in C2
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    concatenation
    with
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    middle part of value (string) in C2 starting from character 3 and having all remaining characters (total length - 2 leftmost we used before)
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    This last part is text, but containing only digits, so as we made (1+this string it is treated by excel as a number and incremented by 1.

  7. #7
    Registered User
    Join Date
    10-31-2017
    Location
    Livingston, NJ
    MS-Off Ver
    2016
    Posts
    7

    Re: Can I use an IF function to Autofill?

    Whoa, still don't understand exactly, but I appreciate all of your help. I'll look up those functions you used and see if I can learn more.

+ 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: 0
    Last Post: 01-19-2013, 01:35 PM
  2. Autofill function with offset
    By guts80 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-20-2012, 06:40 AM
  3. Autofill function with filter
    By Sascha93 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-21-2011, 05:30 AM
  4. Using Autofill for a LINEST function?
    By jmbky1 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 01-21-2011, 06:44 PM
  5. Autofill VLOOKUP function
    By gutter_mutt in forum Excel General
    Replies: 8
    Last Post: 10-01-2010, 07:05 AM
  6. Using the autofill function but increment by certain number in function
    By rishid in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 09-06-2005, 03:05 PM
  7. Autofill Function
    By PGalla06 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-23-2005, 03:23 PM
  8. INDIRECT Function and Autofill
    By Neil Grantham in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-20-2005, 08:07 PM

Tags for this Thread

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