+ Reply to Thread
Results 1 to 27 of 27

Date/INDIRECT Issues

  1. #1
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Date/INDIRECT Issues

    I am pulling a date from a cell to another and I need to create a formula based off of the result.

    This is the formula I am using to pull the date over
    =MID(AA3,FIND("/",AA3)-2,10)

    This is what I need to do to the result
    =WORKDAY(M3,6)

    I believe =INDIRECT should be used, but I'm having difficulty making it work.

    Thanks in advance.

  2. #2
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    That works for me if AA3 contains a text string with a valid date in it, such as
    "this is a date 10/15/2014 my friend"

    In what way does it not work for you?
    Do you get an error? What error?
    Do you get the wrong result? What result did you actually get, and what result did you expect?

    Can you post some examples of the contents of AA3 ?

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,726

    Re: Date/INDIRECT Issues

    I assume the first formula is in M3. It will return what looks like a date, but is in fact a text value that looks like a date. Change it to this to get a proper date:

    =--MID(AA3,FIND("/",AA3)-2,10)

    Then the other formula should work, adding on 6 working days to the date in M3. Ensure that both cells are formatted as a date.

    Hope this helps.

    Pete

  4. #4
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    @Pete

    It works for me as is, without the text to number conversion.
    Again, assuming the text string contains a valid date in the format of mm/dd/yyyy

    I believe all the date functions (DAY, YEAR, MONTH, DATE, WORKDAY, NETWORKDAYS, EOMONTH etc..) will auto convert text to number whenever possible..

  5. #5
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,726

    Re: Date/INDIRECT Issues

    It wouldn't work for me, anyway, as we use a different date format. That might be what the problem is for the OP if s/he has:

    "this is a date 15/10/2014 my friend"

    in AA3.

    Pete

  6. #6
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    Yep, I was thinking that too.

  7. #7
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    If the date in AA3 is in the format dd/mm/yyyy
    Then the formula in M3 should be changed to

    =DATE(MID(AA3,FIND("/",AA3)+4,4),MID(AA3,FIND("/",AA3)+1,2),MID(AA3,FIND("/",AA3)-2,2))

  8. #8
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    Thanks for all the help. Here is what I am trying to pull the dates from...I included AA3 and others so you can see the variations:

    561-550-113 1/22

    561-265-222 (922) DUE 1/22

    561-728-216 (960) DUE 1/21

    Jonmo: the formula worked perfectly, but the date came out wrong...I'm sure it's because the date format is different than what you were expecting. I wish I could tweak your formula to make it work for me, but I'm not that good. Is there anyway you can make it work for my date format?

  9. #9
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    Those samples don't make sense when compared to the formula you used.
    =MID(AA3,FIND("/",AA3)-2,10)
    That indicates you're pulling a 10 digit date as in mm/dd/yyyy or dd/mm/yyyy

    Can you could post a sample book?

  10. #10
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    You are correct...I had to tweak it to

    =MID(AA3,FIND("/",AA3)-2,4)

  11. #11
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    I was going to suggest

    =TRIM(MID(AA3,FIND("/",AA3)-2,5))

    You need 5 to account for 2 digit month + 2 digit day.

  12. #12
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,726

    Re: Date/INDIRECT Issues

    Well, 4 will only work if you have a 1-digit month, but if the date is always at the end you can do this:

    =TRIM(RIGHT(AA3,5)&"/2013")

    assuming your year is always the same, and that the day part is always 2 digits.

    Please post some more examples.

    Pete

  13. #13
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    Sorry I'm starting to confuse myself...the dates are in this format

    561-550-113 1/22/2014

    561-265-222 (922) DUE 1/22/2014

    but where they are populating is in a 1/22 format.

  14. #14
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    ok, so then back to the 10, but add TRIM

    =TRIM(MID(AA3,FIND("/",AA3)-2,10))

  15. #15
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,726

    Re: Date/INDIRECT Issues

    Okay, try this in M3:

    =--RIGHT(AA3,10)

    Format it how you want it to appear.

    Do you have any examples of single-digit days? Do the days have leading zeros, even if the months don't?

    Pete

  16. #16
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    Boom! Worked...Awesome...Thanks for the help!!!

  17. #17
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    You're welcome.

  18. #18
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    It worked! Thanks so much for the help!

  19. #19
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    I just ran into two more issues that I didn't think about...first not every cell in AA has a date, so it's populating #VALUE!...not the end of the world it's just annoying and secondly I need to have the date that was pulled from AA3 to be 3 workdays in advance when it populates into column M. Am I getting too crazy? If so, just let me know. Thanks

  20. #20
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    3 working days advanced from the date in AA

  21. #21
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    You can use the IFERROR function to handle the error.

    =IFERROR(TRIM(MID(AA3,FIND("/",AA3)-2,10)),"")

    Add 3 work days..
    It seemed you already had a handle on the WORKDAY funciton.
    Can't you just change the workday function you already have in another cell to 9 instead of 6 ?

  22. #22
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    The IFERROR worked perfectly, thanks! The workday issue I do have worked out for the other cells that will populate based on this one.

    Below is what is going on. The Plan Assy Start is where the above formula is populating. The other columns build on themselves with =WORKDAY. So for the plan to be correct I need to add 3 workdays to the formula pulling from AA to populate the correct start date.

    Plan Assy Start Plan Assy Finish Plan FT Finish Plan QA Finish Plan Ship
    From AA +3 +1 +2 +1 +1

  23. #23
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    Damn it, that posted oddly...hold on

  24. #24
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    =iferror(workday(trim(mid(aa3,find("/",aa3)-2,10)),3),"")

  25. #25
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    These are columns, but it's not posting right so I will make them look like rows

    Plan Assy Start
    (From AA +3 working days)

    Plan Assy Finish
    (+1 working day from Plan Assy Start)

    and so on...they build on each other. I have the others figured out because, well it's the easy part, but adding 3 working days to the already growing formula is above my ability.

  26. #26
    Registered User
    Join Date
    08-14-2012
    Location
    Washington, USA
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Date/INDIRECT Issues

    Wow! That is awesome...works perfectly! Thank you so much...I might just get a raise outta this...I appreciate it!!!

  27. #27
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Date/INDIRECT Issues

    You're welcome.

    Quote Originally Posted by liquidtrails View Post
    I might just get a raise outta this.
    Where do you work? I'll send in my resume. J/K

+ 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] Issues with VLOOKUP/INDIRECT and retrieving from multiple sheets
    By nicolerork in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 08-28-2013, 12:53 AM
  2. Worksheets, Indirect References and Performance Issues
    By Rikkdh in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-28-2013, 09:36 AM
  3. [SOLVED] Having issues with INDIRECT and cell references
    By qaliq in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 05-31-2013, 06:10 AM
  4. date issues
    By nightcrawler-jay in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-01-2010, 05:53 AM
  5. Date issues
    By CobraLAD in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-01-2009, 05:27 AM

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