Quoting [EMAIL PROTECTED]: > > I filter a database using the following code taking dates from two > datetime pickers. > > DateFilter := 'Solddate >= ''' + Datetostr(dates.First.datetime) + ''''; > DateFilter := DateFilter + ' AND Solddate <= ''' + > Datetostr(dates.last.datetime); > items.filter := datefilter; > > The problem is that it does not filter right. > I set shortdateformat to dd/mm/yyyy and it worked better but it is still > incorrect when selections are made from multipule months. > > The tables are paradox 7. Normally in SQL the date format is mm/dd/yyyy. Does this apply? I'm not sure The other probelm you have to watch with datetimepickers is that the time gets included in the date. I assume datetostr will chop that out for you. --------------------------------------------------------------------------- New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED] Website: http://www.delphi.org.nz