Hi,

I am attempting to create a querytable, as soon as a workbook is opened.

I have had a bit of a nightmare with the Syntax for the SQL.

I am attempted to pull all records from a table, that were received between 07:00:00 and 20:00:00 "yesterday".

Could someone please provide me with some sample code, that would do this for me.
I've tried tried passing the dates as variables in my vb module, but had no luck!

Any help would be appreciated!!

Mitch