Results 1 to 4 of 4

Code Not Identifying Yesterday As Delinquent

Threaded View

  1. #1
    Forum Contributor
    Join Date
    01-04-2011
    Location
    Phoenix, Arizona
    MS-Off Ver
    Excel 2003
    Posts
    129

    Code Not Identifying Yesterday As Delinquent

    Hello All,

    The purpose of the below code is to identify if a shipment is delinquent or not. The intent of the code is to look at specific date and if that date is in the past then the shipment is delinquent. If that date is in the future it says whether it is next month or the month after, etc.

    However, I have run into a snag. It seems to only be looking at the month. I need it to look at the day so that I know a date of yesterday is delinquent if it hasn't shipped.


    With .Range(.Cells(2, "N"), .Cells(.Rows.Count, "N").End(xlUp))
        .Offset(, 1).Value = .Parent.Evaluate _
               ("IF(ISNUMBER(" & .Address & ")," & _
                    "LOOKUP(" & _
                       "(TEXT(" & .Address & ",""yyyy"")*12+TEXT(" & .Address & ",""mm""))" & _
                            "-" & _
                        "(TEXT(TODAY(),""yyyy"")*12+TEXT(TODAY(),""mm""))," & _
                   "{-9.99E+307,0,1,2,3}," & _
              "{""Past Due"",""Current Month"",""CM+1"",""CM+2"",""Beyond""}" & _ ")" & _
                        ","""")")
       End With
    End With
    Any help with this code is greatly appreciated.

    The original posting that helped me with this can be found here

    Thank you.

    Kelly
    Last edited by jkelly228; 03-29-2011 at 03:08 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