Thanks everyone for your quick responses.
I found the culprit. Syntax. SQL doesn't like the use of square brackets on field names.
Removed the brackets . . . works perfectly.
Thanks again.
Thanks for the quick response Alvechurchdata. The sql string in my code is on one line for now, until I get it working.
I noticed that you removed the "." after "GROUP BY Code]. ". Other than that it's the same code. However, when I pasted you code into the report I get an "Expected: list or...
I copied and pasted this sql statement from the design view of an Access query into the code for a report. In the report I get a sintax error on the FROM clause??
This the qry statement from the datasheet query:
SELECT A.Code, A.Title, A.Wage, A.Year
FROM Positions AS A INNER JOIN [SELECT...
Thanks PHV. I had no idea such a simple query would have such a complex solution!! I must have read 40 threads. All of them equally complex, far too complex for my simple need, I thought.
Thanks again.
I am using Access 2002 and I am trying to create a query that selects the most current version of each code. Here is the data:
Code Title Wage Year
AC Account Clerk 1 2001
AL Advanced Lifeguard 9.56 2001
AM Assistant Manager 10.94 2001
BB Buddy Bear 1.00 2001
CA...
Another interesting note! If, while the envelope form is displayed on the screen, one pulls down the FILE menu from the tool bar and selectes PRINT PREVIEW. The report window is closed and the underlying form is displayed! (the one that prints)
Any help would be greatly appriciated. The...
I tried that. As long as the reference to the underlying form in present, it prints!!! Crazy.
strTemp = "SELECT * FROM [" & sYearFile & "] WHERE [" &
sYearFile & "].SSnum = '" & Forms![Applicant Form]!
SSnum & "';"
Set rst =...
I have an application that collects employee application info. When a new record is saved, it prints an envelope with the applicant's name and address and a code based on certain criterion.
The problem is, when the report preview (of the envelope) comes up and the user presses PRINT icon, a...
The forms are maximised. Therefor, the 'X' button cannot be turned off. I sertainly would be interested in your code in any event.
I once saw some code somewhere that, in leu of maximising, resized the form to the size of the screen resolution using Windows API calls. It was a bit over my...
Makes perfect sense. However, I don't see an event named DIRTY. I've checked the FORM properties, DETAIL properties and the TAB PAGE properties.
Suspecting that this might be an undocumented (Who!, Microsoft!) event, I went ahead with your suggestion and created the following sub in the...
I have a form with a Tab Control consisting of 4 pages. All of the controls are on the pages. There are no controls on the form itself. And I suppose that's why this makes sense: Testing for ME.DIRTY is always false. And trying to test for ME!PAGE2.DIRTY triggers an error.
How do I test...
Your right, that is deffinately a better way to do it. However, I'm not sure it will work in this case because the user often will need to go back and edit the quantities and/or prices and the tax amount needs to be recalculated whenever a quantity or price is changed.
I've got an invoicing application with a Main form containing Subtotal, Tax, Freight and Total. The subform contains the detail info; Item, Qty, Price and Extension.
I've got it all working fine with the usual calculations as discribed elsewhere in these forums, such as...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.