Search results

  1. M

    too few paramaters, expected 1 - dao recordset

    Thanks though for your response, it's useful to know!
  2. M

    too few paramaters, expected 1 - dao recordset

    Never mind! I've fixed it with this code for the where clause instead: strBanksianWhere = " WHERE ((((DatePart('yyyy',[tblShow].[dtmShowDate])) between " & Me.numShowYear - 2 _ & " AND " & Me.numShowYear & ")" _ & " AND...
  3. M

    too few paramaters, expected 1 - dao recordset

    Hi there, Ok, so I found the typo and it fixed it but I then had to adjust my code to make it more well-rounded by putting some qualifiers in: My code is this: Case Is = "Banksian Medal" 'Most points in horticultuaral classes. Can only be won by same person every 3 years. Dim...
  4. M

    too few paramaters, expected 1 - dao recordset

    And that now works! Thanks very much.
  5. M

    too few paramaters, expected 1 - dao recordset

    Hi, yeah I looked for that but I have just looked again and found a sp mistake in the order by statement. Thanks!
  6. M

    too few paramaters, expected 1 - dao recordset

    Hi all, I am trying to open a record set based on a query and then with the results of the query, post 2 values in to 2 variables for use later on in a module. My code so far is: Dim strBanksianWinner1 As String Dim strBanksianWinner2 As String...
  7. M

    Unbound Combo Box on report

    Please ignore me, I've re-designed and done it properly :)
  8. M

    Unbound Combo Box on report

    Hi all, I have an unbound combo box on a report that looks up to a table of address data. I have a specific requirement where if one of the bound fields on the report is a specific value, I want the combo box to show data. If the bound control on the report is a different value, I want the...
  9. M

    Changing Stock levels of multiple product components by one command

    Hi there, Thanks for the reply - do you mean take it out of the quote marks, so .fields(ComponentStockLevel) = ComponentStockLevel - (QuantityUsedForProduct * numQTY) instead of .Fields("ComponentStockLevel") = ComponentStockLevel - (QuantityUsedForProduct * numQTY) or do you mean...
  10. M

    Changing Stock levels of multiple product components by one command

    Hi all, So I have my code like this so far: Private Sub btnOK_Click() Dim rstProduct As DAO.Recordset Dim numQTY As Integer Dim strSELECT As String Dim strWHERE As String Dim strSQL As String Select Case OpenArgs Case Is = 1 numQTY =...
  11. M

    Changing Stock levels of multiple product components by one command

    I saw nothing in that article about not storing a value if it can be calculated, that's only about database normalisation, but I appreciate your concern that I do it correctly.
  12. M

    Changing Stock levels of multiple product components by one command

    Thank you. May I ask why it's bad practice to store a value in a database and then update that value? It seems a pretty normal idea to me.
  13. M

    Changing Stock levels of multiple product components by one command

    Hi thanks for your reply. I'm not trying to store a result, I'm trying to update a value in multiple records. I've been doing some research too, whilst seeing if any replies would happen and then I found I need to work with a recordset and loop through it.
  14. M

    Changing Stock levels of multiple product components by one command

    Hi all, I have the following form and subform combination: The subform is linked to the main form by way of the "ProductID" control. (It's hidden in the subform). Basically, each product (the finished article) is made up of many components. What I would like to do is this: 1. Increase...
  15. M

    Insert query syntax error

    Aha! You're amazing. That worked. Thank you so much.
  16. M

    Insert query syntax error

    It didn't :(
  17. M

    Insert query syntax error

    Have it sorted, by not having the last value in as I don't really need it there. However, knowing how to do the boolean thing would be great
  18. M

    Insert query syntax error

    DtmDate is date/time component is number history is number quantity is number update is yes/no Sorry, should have said.
  19. M

    Insert query syntax error

    Hi All, I'm trying to do an insert into query via VBA that takes the values of some controls in a form and puts them in to another table. Basically frmPurchaseHistory, if a new record, will insert a new entry in to tblComponentHistory. My Code is as follows but it is getting a syntax error...
  20. M

    Update query in VBA

    Update, I have just worked out that I needed to use CurrentDb.Execute instead of Db.Execute. Sorry to bother you.
Back
Top Bottom