I have a block of PowerBuilder code I want to replicate
using VB on a web page.

Anytime I add a datetime field to the filter, the filter
fails with the following error: SetFilter had an invalid
expression, Expression is : <filter>

Works: dwData.setFilter("code='001' and displayonform =
'Y'")
Fails: dwData.setFilter("code='001' and displayonform = 'Y'
and lastdisplaydt > 6/16/2009")
Fails: dwData.setFilter("lastdisplaydt > 6/16/2009")

This code functions perfectly in PowerBuilder but it will
not function in VB (2003).

I have tried different forms of the date; 6-16-2009,
06-16-2009, 06-16-09, 06/12/09, both with and without
quotes, with and without time information (6/16/2009
00:00:00).

Anytime I add a datetime field to the filter, it fails.

Does anyone have any ideas?