Dates with future years

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Richd
    New Member
    • Jun 2007
    • 2

    Dates with future years

    HI,
    Any help would be appreciated, I am trying to use dates to show things as past due (yesterday and earlier are past due). Problem:Because of space constraints on the form the stored procedure returns an 8 char field for dates which is no problem to work with at all I.E. mm/dd/yy. My real issue is when some one entering the dates does a fat finger and enters 06/07/2077 on the entry form the system returns it to the screen as 06/06/77 - cool no problem there - except when i try to do a compare to see if it is past due. It appears the system is reading this as 1977 instead of 2077 and making this date past due when its is not. Any one know of a setting or another way to handle this on the .NET side of things?



    Thanks
  • tifoso
    New Member
    • Apr 2007
    • 41

    #2
    A bit blurry but it sounds like u r stating u get the values from a result set as a string so there is not setting that will help you there. Probably you should get the values with full year and keep them so in your code at moment of displaying format it to to show a shorter date

    Ciao

    Comment

    • Richd
      New Member
      • Jun 2007
      • 2

      #3
      Originally posted by tifoso
      A bit blurry but it sounds like u r stating u get the values from a result set as a string so there is not setting that will help you there. Probably you should get the values with full year and keep them so in your code at moment of displaying format it to to show a shorter date

      Ciao

      Yes, thought that way also...just seeing if anyone knew a different way ....

      Thanks

      Comment

      • debasisdas
        Recognized Expert Expert
        • Dec 2006
        • 8119

        #4
        May i know please what is the database you are using for the purpose.

        Comment

        • jeffbroodwar
          New Member
          • Oct 2006
          • 118

          #5
          Why not try using format mm/dd/yyyy

          Comment

          Working...