Search results

  1. Elana

    Frame Option Group, select a value by VBA

    Yikes! 100 Check boxes? I am curious why you have chosen an option group to capture the information. I would think instead you would have a table containing those 100 options and allow the user to choose the appropriate option with a listbox or combobox (or synchronize the listbox or combobox...
  2. Elana

    DLookUp

    I'm assuming you're placing this code on the BeforeUpdate event of the form? If yes, then you need only to add "Exit Sub" after your "cancel = true" statement You don't need to "undo" the other two fields as the record will not update. HTH E
  3. Elana

    Where Clause - trouble with Quotation Marks

    Never mind, I figured it out (needed to place quotation marks around the "and" operator: myfilter = "[showid] = " & "forms!frmexhibitorsbyshow!showid" & " And " & "[dateadded] = " & "Forms!frmexhibitorsbyshow!txtdate" Works great now.
  4. Elana

    Where Clause - trouble with Quotation Marks

    Hi - I'm trying to programmatically set a report filter behind a Print button using two criteria on the active form (showid) and (txtdate). I'm having trouble with this expression and I know it has to do with quotation marks: myfilter = "[showid] = " & "forms!frmexhibitorsbyshow!showid" And...
  5. Elana

    Irritating Combo Boxes

    Take a look at this MS Knowledge Base article - it might help you understand what's going on and how to fix it. 208866 HTH Elana
  6. Elana

    Parameter Query based on Form Control

    Great - glad I could help!
  7. Elana

    Parameter Query based on Form Control

    Well, that's the rub. I'm not as good at VBA coding as I would like - i.e., knowing the ins and outs of each property. I'll show you my code that I used to search the recordset of a parameter query (looking for records where the State=CA) - it works perfectly. Maybe it will give you some...
  8. Elana

    Parameter Query based on Form Control

    I think this problem has something to do with needing to use the eval() function. I have used this code after receiving error message 3061 and it solved the issue. Try inserting this code after your "set qd" and see if this helps at all. Add this variable first: Dim prm As Parameter Then...
  9. Elana

    tabbed control

    I would suggest on the afterupdate event of the listbox (after you've made the selection in the listbox on the first page), you refresh the form using me.refresh. HTH
  10. Elana

    Validation Rules

    On the Before Update event of the form, place code to check whether LTC is in either of the two fields: If me.[list_company] <> "LTC" and me.[sale_company]<> "LTC" then msgbox "LTC must be either the listing or sales agent."... cancel = true exit sub else ' do nothing, continue...
  11. Elana

    a2000 - deleting record from form - command button

    If absolutley nothing happens (not even an error) are you sure the command button has code behind on the On Click event? Simple, I know, but sometimes when troubleshooting and renaming things, the code gets disconnected from the control. Alternatively, can you post the form and table so I can...
  12. Elana

    a2000 - deleting record from form - command button

    Have you tried using the wizard to create the button? It uses "docmd.domenuitem ..." but works in A2000.
  13. Elana

    Error while opening connection string on form

    I searched for this error message in the Microsoft Knowledge base and found two articles: 248967 and 274211 Take a look and see if either of those helps.
  14. Elana

    Set criteria (filter) in a subform with command button

    Okay - so here's what I did. I changed the Quarter field in your table to be a numeric field. The combo box now has 2 columns. Then I named the Option Group on your form to "Quarter." I then linked the main form to the subform using the field Quarter. All the user has to do is select the...
  15. Elana

    Set criteria (filter) in a subform with command button

    Can you post this database so I can look at what you're trying to do?
  16. Elana

    Locking existing records in form

    One way to view the form properties is to select View/Properties from the menu bar. Another way is to double click on the box in the upper left hand corner of the form. You're right about reversing the code to show unlocked for new records and locked for old records. You don't need to place...
  17. Elana

    Locking existing records in form

    I took this from Access Help: The Me property contains an object reference to the current form or report and is faster than a fully qualified object reference. For example, the following two code fragments refer to the value of the LastName control for the current record on the Employees form...
  18. Elana

    Total Novice

    You need to create a table to hold the data and bind the table to the form. Since you have already created the form, you need to bind the table to the form under Record Source...then go to each field and bind each to the appropriate table field under Control Source. You don't need to have...
  19. Elana

    Before Update

    (I submitted this simultaneously with Rich I guess - we both have the same answer though) I tested this and it works perfectly. Private Sub Form_BeforeUpdate(Cancel As Integer) If Me.frImported = 2 And IsNull(Me.txtCountry) Then MsgBox "You need to enter a country" Cancel =...
  20. Elana

    counting records on another form

    be sure you are referring to the subform correctly. IS the name of the subform [parts sub] or [parts sub(original!!]? Also enclose the form names in brackets just to be sure.
Back
Top Bottom