In Delphi 7 (maybe earlier versions too) there's a DaysBetween() function. If you don't have access to this or want more control of logic employed, look at decodedate().
soonhuat ong wrote: >Hi, > > > >I have 2 strings as following: > >str1 := '2005/10/28'; >str2 := '2005/11/03'; > >Now i want to calculate the differents days in between those two strings(after >convert it to TDateTime type), any idea ? > >P/S : The Datetime is in yyyy/MM/dd format > > > >Thx in advance > > > >--------------------------------- > Yahoo! FareChase - Search multiple travel sites in one click. > >[Non-text portions of this message have been removed] > > > > >----------------------------------------------------- >Home page: http://groups.yahoo.com/group/delphi-en/ >To unsubscribe: [EMAIL PROTECTED] >Yahoo! Groups Links > > > > > > > > > > ------------------------ Yahoo! Groups Sponsor --------------------~--> Get Bzzzy! (real tools to help you find a job). Welcome to the Sweet Life. http://us.click.yahoo.com/A77XvD/vlQLAA/TtwFAA/i7folB/TM --------------------------------------------------------------------~-> ----------------------------------------------------- Home page: http://groups.yahoo.com/group/delphi-en/ To unsubscribe: [EMAIL PROTECTED] Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/delphi-en/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

