Thanks I seem to have simplified my example too much, there are different tests....
Gauge: IIf(check=1,"test1", iif(anothercheck=2,"test2","not Found")
Thanks
Please help me with some code, i have a nasty IIF statement with 5 levels and getting confusing. Seems like code might be easier. How would I represent the following example in a nested iff in VBA. How would I call that function fromm a query.
Gauge: IIf(check=1,"test1"...
Please help - I have used this before with one stlinkcritera but now I have 2. Something is wrong with my stlinkcriteria statement.
Private Sub Command5_Click()
Dim stlinkcriteria As String
Dim stdocname As String
stdocname = "hangList_select"
stlinkcriteria = "[umps phase]=" &...
I have a table which contains some duplicate records - some fields duplicated, some different for example:
Equip_No, Name
121X, shaft
123X, motor
123X, motor starter
124X, timer
I want a query filter so that only...
I know what you are saying, but I do need something to tell me that the invoice was processed, and so using the date submitted = now() - I took the invoice total amount out - as you say thats a calculated field.
thanks
I figured out my problem. The form was based on a query which is not updatable. I changed it to be based on the original table and the code provided in earlier posts works.
However - the reason it was based on a query is because I only wanted to show certail records in the form, those that...
I kept getting errors with the lines in your last post...the whole thing looks like this at the moment:
Private Sub Command22_Click()
Me.[Amount Submitted] = Me.[labor amount] + Me.[oh Amount]
Me.[Invoice Date] = Now()
DoCmd.OpenReport "rptinvoice", acPreview, , "[new invoice...
On what line, so which line??
Not sure what the question is, the report runs and preview opens. Then an error message pops open with the message described above.
Stay with me...
thanks
Thanks again , I added the statement, but got the error
"You can't assign a value to this object"; here is the whole thing as it stands. The report part runs fine.
Dim strDocName As String
Dim strWhere As String
strDocName = "rptinvoice"
strWhere = "[new invoice No]='" & Me![NEW...
Thanks, but I still can't get it working. Here is the update query I would like to run, how can I convery this to run in the procedure.
UPDATE Invoicing SET Invoicing.[Amount Submitted] = [labor amount]+[oh Amount], Invoicing.[Invoice Date] = Now()
WHERE (((Invoicing.[NEW Invoice...
Thanks- thay was easy - but I think I need one more thing - the query is an update query and I want to update only the record where [new invoice No] = """ & Me.[new invoice no].
So my update query is filtered to only update that record, how can i pass the Me.[new invoice no] to the udate query...
I get by in Access without knowing any VBA, usually by copying macros I convert. I have the following simple code to open a report with the current record from a form. I would like to add some code to that procedure to run an update query. Below if the code to run the report and under that is a...
I have a linked spreadsheet. When I link the sheet I get no options to set the field type. The xls field formats are all General.
I get Numeric Field overflow errors.
If I change 2 of the columns in the xls sheet to Text everything works fine.
How can I get this automated, i.e so that the...
The Doc Man - that worked fine I see Ray H did it the same way -
seems like I need something in the data I get i.e not (CR) but l^
So if I get the data with the right carriage return symbol can I get this to work in Access??
thanks for your help...