Recent content by meadows43

  1. M

    Combo Box Error: Recordset Not Updatable

    I recently had to alter my database to change the primary key in the Accounts table include the Country as well as the Master Number. A combo box I had on the [Transfer to Other Manager] form that was working fine before now produces the error "Recordset not updatable" when I try to select a...
  2. M

    Like keyword in Parameter Query

    If this answer had teeth, it would have bit me. Thanks for the help, it works now. Chris
  3. M

    Like keyword in Parameter Query

    I was wondering if it's possible to do pattern matching on the user's input for a parameter query? I've tried typing Like "*[Prompt goes here]*" in the criteria field in the QBE, but that doesn't work. Any suggestions? Thanks, Chris
  4. M

    Requery Combo Box but Keep Selection

    That did the trick. Thanks! Chris
  5. M

    Requery Combo Box but Keep Selection

    I have a form called "New Account" that opens another form called "New SAM" if a new value is entered in a certain combo box on the first form. After the second form closes, I requery the combo box on the first form, but I need the original value that the user entered (which has been added to...
  6. M

    Requery form using global variable

    Hi, I am trying to store the value from a control on one form in a global variable, open another form, change the value of a text box on the second form to the value of the global variable, and then requery the second form. I get an error when it tries to open the second form from the first...
  7. M

    NotInList code in Access 97

    Mile, The problem was that I had an underscore in the field name where there didn't need to be one. I changed that and now it works. Thanks again. Cheers, Chris
  8. M

    NotInList code in Access 97

    Thanks for this. But, now I get the error "Item not found in collection." and it still doesn't add it. I made a few changes. Here's what I've got: Private Sub cboAcct_NotInList(NewData As String, Response As Integer) On Error GoTo Err_ErrorHandler ' provide text constants to reduce...
  9. M

    NotInList code in Access 97

    Hi, I successfully use the code below in Access XP at home, but when I try at work in Access 97, nothing happens. I need the user to be prompted to add the value to the table if it is not in the combo box. Any suggestions? Here's the code: Private Sub cboAcct_NotInList(NewData As String...
  10. M

    Add Item to List Box

    Wayne, Thanks, now it works fine. I'm still feeling my way around VB, so I thought I could use the DoCmd.Requery syntax. Thanks for setting me straight (again). :cool: Chris
  11. M

    Add Item to List Box

    I removed the single quotes before and after Me.List32.ItemData(varItem) in the strSQL assignment statement. Ingredient Num is a number not a text string. Wayne, thanks for pointing out my error with the strSQL assignment. But now I get an error "Run time error '2109' There is no field...
  12. M

    Add Item to List Box

    Ok, I think I've almost got it. I'm getting a data type mismatch error for my query string when I click the command button, though. Here's the function I'm using Private Sub Command9_Click() Dim varItem As Variant Dim strSQL As String strSQL = "UPDATE Ingredients SET Ingredients.InQuery...
  13. M

    Add Item to List Box

    Thanks, that's a good idea. And no, I'm not in a multi-user environment. I am having trouble though retrieving the selected item from the first list box. I wrote a function that loops through the list of the ItemsSelected property, but I am using a macro for the command button's onclick...
  14. M

    Add Item to List Box

    Hi, I have two list boxes on my form. I want the user to select an item from the first list box, click a button, and have the item be added to the second list box. What's the most straightforward way to add an item to a list box with VBA? I know in Visual Basic.NET you use...
  15. M

    Opening a SQL query with DAO

    Wayne, I took your advice and tried typing my query in the SQL view window, and got the same results. I then realized I had the field names wrong. I changed it and now it works fine. Well, now I know what that error means! Thanks for all your help. Chris
Back
Top Bottom