Search results

  1. H

    Solved Form Data to Save to Table AND APPEND another Table

    I am doing some research on the error I keep getting. One question I have, is that I am not referencing the Primary Key field in the target table because I want to add a new record. Do I need to reference that field? I don't when I created an Append query in the Query Design Builder. Also...
  2. H

    Solved Form Data to Save to Table AND APPEND another Table

    I'm so sorry. It still gives me the Run-time error '3134': Syntax error in INSERT INTO statement. When I hit "DEBUG" on the error popup, it highlights the last line of the code: CurrentDB.Execute strSQL, dbFailOnError.
  3. H

    Solved Form Data to Save to Table AND APPEND another Table

    Private Sub SaveNew_Click() If Me.Dirty Then Me.Dirty = False End If Dim strSQL As String strSQL = "INSERT INTO Part Inventory(PARTID, RevLevel, ODID, RELID, RelNum, RQty, INVTRXID, CreatedDate ) " _ & "SELECT OrderReleases.PARTID, OrderReleases.RevLevel...
  4. H

    Solved Form Data to Save to Table AND APPEND another Table

    Thank you! With the code in response #17, I get a Run-time Error '3134': Syntax error in INSERT INTO statement. What do you see wrong with my coding?
  5. H

    Solved Form Data to Save to Table AND APPEND another Table

    I hope you had a wonderful Easter. I am back to working on this. I really want this to work. With adding the Me.Dirty statement, the record is saved to the first table, but the append does not happen. Here is what I have. I removed the execute statement, because it errors out on it. Maybe...
  6. H

    Solved Form Data to Save to Table AND APPEND another Table

    How would recommend would be the best way to accomplish this? If I want to run the APPEND query on a click event, how would I write the code to save the record first?
  7. H

    Solved Form Data to Save to Table AND APPEND another Table

    I copied what you typed, but now I get a Run-time error '3134" - Syntax error in INSERT INTO statement. I'm really scratching my head. When I created the Append query it worked fine. So I copied the SQL to create this statement. The only thing I can think of is that the record needs to be...
  8. H

    Solved Form Data to Save to Table AND APPEND another Table

    Is this what you mean? I get an error message. Private Sub SaveNew_Click() Dim strSQL As String CurrentDb.Execute strSQL, dbFailOnError strSQL = "INSERT INTO Part Inventory(PARTID, RevLevel, ODID, RELID, RelNum, RQty, INVTRXID, CreatedDate )" _ & "SELECT...
  9. H

    Solved Form Data to Save to Table AND APPEND another Table

    Okay, so just to make it clear. I place the execute command after my last line of the strSQL and before End Sub? I hope when I have learned all this, I can help others too.
  10. H

    Solved Form Data to Save to Table AND APPEND another Table

    Um. I think that is why it is not working. What would I need to type (and where) to execute the string? Sorry for seeming stupid about this. I am still learning.
  11. H

    Solved Form Data to Save to Table AND APPEND another Table

    Thank you! I'll give it a try.
  12. H

    Solved Form Data to Save to Table AND APPEND another Table

    Hi all, I have searched both Google and this forum to find the answer to my issue. I am trying to enter data into a table through a Form and then use the data in the form to "Append" another table. I can create the Append Query just fine, but when I try to add the code to a ONCLICK event, I...
  13. H

    Can I use and UPDATE statement on a Click Event?

    No worries. This database project is really taxing my programming abilities. I have many successes with the help from this group, but then I'm stumped in other areas. I am thinking of breaking down my inventory transactions into two different tables and query them for the inventory view on...
  14. H

    Can I use and UPDATE statement on a Click Event?

    I would normally agree with you, however, each "part" made can be held in inventory, shipped to a vendor for a secondary process, or placed on hold for future orders (more than one customer orders the part), so I have a different transaction ID code for each phase of the part. The owners want...
  15. H

    Can I use and UPDATE statement on a Click Event?

    I can run another query with the two tables to get the data that is needed to update the inventory table I have. As Plog mentioned, I may have too many tables. I have a PARTS table and a PART INVENTORY table that are linked by PARTID. I used the PARTS table to keep all the information about...
  16. H

    Can I use and UPDATE statement on a Click Event?

    Hi All, I have unique challenge. I have a main form that connects two subforms. Each subform get's it's data from 2 different queries/tables. But I have data in both forms that need to be updated into a different table. I want to use the UPDATE statement on a click button event. Am I on the...
  17. H

    Solved Use of Option Box to change field value on click or After Update

    OMG! I totally forgot about using the Case function. That will work. Thank you so much for solving my issue. I am getting better at programming, thanks to wonderful people like you. So glad I have this forum for a reference.
  18. H

    Solved Use of Option Box to change field value on click or After Update

    Hi All, I have a Option Box with two click options. Numbers 1 and 2 are assigned. I need the click on 1 option to change the value of two fields (status Id's), and the click on option to the change those same to fields to another value. Here what I've written to try and change the fields, but...
  19. H

    Selecting multiple records to Ship? Pick Your Brain

    CJ, How would I get the selected records from this filter to be used on another form? I'm stumped on how to write that code? Can you offer some assistance here?
Back
Top Bottom