Date Criteria from Combobox

jlundbe2

Registered User.
Local time
Today, 10:09
Joined
Jul 29, 2008
Messages
10
Hey everyone!

I am stuck on an issue with my db. I am trying to run a query with data from multiple tables based on a date selection in a combobox. When entering the date on the criteria design (#9/16/2008# for example) the query runs fine. However when trying to run the same query with the combobox selection I get the following error: "The expression is typed incorrectly, or is too complicated to be evaluated. For example..."

Not too sure what to do. I have checked that the bound column of the cbo is the date, checked that data types match, etc. and have gotten nowhere. The criteria in the query is [Forms]![frmLaunch]![cboDate] under IssueDate.

Thanks for the feedback!

Jason.

P.S. One thing that might be possible. The field name IssueDate is on two tables identically (not linked) in the query.
 
Hi -

Would you please post your querySQL.

Thanks - Bob
 
Thanks for the response. I can also provide additional code if necessary.

Code:
SELECT tblCustomers.ClientName, tblContracts.ContractID, tblContracts.ContractDescription, tblOrder.ContractedIssueDate, tblItems.ItemDescription, tblOrder.AdRunConfirmation, tblContracts.TearsheetsRequired, tblOrder.TearsheetFiled, tblOrder.MakegoodNotes
FROM (tblItems INNER JOIN ((tblCustomers INNER JOIN tblContracts ON tblCustomers.CustomerID = tblContracts.CustomerID) INNER JOIN tblOrder ON tblContracts.ContractID = tblOrder.ContractID) ON tblItems.ItemID = tblOrder.ItemID) INNER JOIN tblIssues ON tblOrder.ContractedIssueDate = tblIssues.IssueDate
WHERE (((tblOrder.ContractedIssueDate)=[Forms]![frmLaunch]![cboDate]))
ORDER BY tblCustomers.ClientName;
 
So, I went ahead and changed the fields with identical names so that they are no longer the same and get the same issue. This database is very driven off of this date so I am not really sure where to start to resolve this issue. I will try remaking the query and seeing if that does the trick (sometimes Access 2007 is finicky like that). The error message seems so vague and their isn't much guidance I have found online on how to approach it. Any help is appreciated. Thanks!
 
Hey! Looks like I figured it out. The combobox format did not match the query format for that field (short date), Live and learn I guess.
 

Users who are viewing this thread

Back
Top Bottom