Board index » delphi » Filters and TDateTime Fields

Filters and TDateTime Fields

How can I apply a filter to a date field in a TTable?

Something like...

table1.filter='DocDate=1/15/1998'

(This one gives an error: Invalid filter character expression character:
'/')

 

Re:Filters and TDateTime Fields


Try this..   table1.filter='DocDate=1.15.1998'
It works for me  :-)

I think you can change the caracter in regionale setting's   "."  "/"

Bernt
Nettsenteret..

Quote
Humberto Gutierrez wrote:
> How can I apply a filter to a date field in a TTable?

> Something like...

> table1.filter='DocDate=1/15/1998'

> (This one gives an error: Invalid filter character expression character:
> '/')

Re:Filters and TDateTime Fields


Hi Humberto,
table1.filter='DocDate='+QuotedStr('1/15/1998')

--
Roman
I...@rksolution.cz (please remove STOPSPAM. in header)
Delphi corner now open at my website http://www.rksolution.cz

Quote
Humberto Gutierrez wrote in message <01bdb0e0$c01052a0$4f5231cf@humbertg>...
>How can I apply a filter to a date field in a TTable?

>Something like...

>table1.filter='DocDate=1/15/1998'

>(This one gives an error: Invalid filter character expression character:
>'/')

Other Threads