Search results

  1. A

    Not in List Multiple Combo Box with the same row source

    So, the complication is that I want to use the same form for multiple combo boxes on this form, as well as other forms. Here is the code I have for using on multiple forms: Private Sub cmdClose_Click() Me.Refresh DoCmd.RunCommand acCmdSaveRecord If IsNull(NameOfPerson) Then 'do nothing...
  2. A

    Not in List Multiple Combo Box with the same row source

    I have a form with 3 combo boxes that all have the same row source, say frmCombo. I would like to use a Not In List event to open a new form to enter new data, say frmDataEntry. Is there a way for the frmDataEntry on closing to go back to the combo box on frmCombo that was the source of the...
  3. A

    Open Report with Where Clause 2 criteria on one control

    Thanks for the tip. Revised code worked, and is cleaner. DoCmd.OpenReport "rptSubmittals", acViewPreview, , "[Job] = '" & Me![Job] & "' AND ([Status] = '" & x & "' OR [Status] = '" & y & "')"
  4. A

    Open Report with Where Clause 2 criteria on one control

    Answered my own question - Changed the code to: DoCmd.OpenReport "rptSubmittals", acViewPreview, , "[Job] = '" & Me![Job] & "' AND [Status] = '" & x & "' OR [Job] = '" & Me![Job] AND &[Status] = '" & y & "'"
  5. A

    Open Report with Where Clause 2 criteria on one control

    I'm trying to open a report with 2 criteria on one control, with no luck. Here is the code: Private Sub cmdPrintOpen_Click() Dim x As String Dim y As String x = "Not Approved" y = "Make Corrections Noted" DoCmd.OpenReport "rptSubmittals", acViewPreview, , "[Job] = '" & Me![Job] & "' AND...
  6. A

    Troulbe with Where Clause

    June7 - your solution works. Thanks! First time I looked at it I missed the Not in the If statement. Mike, your's work too. I don't want to use 2 separate forms though. One form is easier to manage.
  7. A

    Troulbe with Where Clause

    From the subform "frmToDoListAll" I want to double click on the "What" field to open the form "frmToDoListEntry" and display the record that I click on. I've attached some screen shots. The onload for "frmToDoListEntry" set it's data entry to false
  8. A

    Troulbe with Where Clause

    June, Yes, there is code behind the form to change it from dataentry true to false. Ridders, Downloaded your version. It still opens to all the records.
  9. A

    Troulbe with Where Clause

    OK. Changed the code to: If Me.Dirty Then Me.Dirty = False DoCmd.OpenForm "frmToDoListEntry", , , "[ID]=" & Me.[ID] & "" Still get all the records.
  10. A

    Troulbe with Where Clause

    I'm trying to open one from from another with a where clause to take me to the same record. From frmToDoListAll, in the Subform, I have the code: Private Sub What_DblClick(Cancel As Integer) DoCmd.OpenForm "frmToDoListEntry", , , "[ID]=" & Me.[ID] & "" End Sub frmToDoListEntry shows all...
  11. A

    Filtering a Subform from an unbound combo box

    I am trying to filter a subform from an unbound combobox on the main form. I have the following code in the after update event for the combo box: Me.frmPublicCommentRecallList.Visible = True Me.frmPublicCommentRecallList.Form.Filter = "[Job]= " & Me.Job...
  12. A

    Display sub Sub Report based on response to message box

    Got it! Works like a charm. Dim res As Integer DoCmd.RunCommand acCmdSaveRecord ' This message box will allow the user to show the critieria that is missing, if they want res = MsgBox("Do you want to include missing criteria on the reply to contractor?", _ VbMsgBoxStyle.vbYesNo Or...
  13. A

    Display sub Sub Report based on response to message box

    Thanks Paul. I'll play around with that, though sending openargs is not something I know well. I'll do my best and let you know how it works. Andy
  14. A

    Display sub Sub Report based on response to message box

    I would like to give the user the option to display a sub report using a message box. This is the code I have tried, unsuccessfully: Private Sub cmdPrint_Click() Dim res As Integer DoCmd.RunCommand acCmdSaveRecord If MsgBox("Do you want to include missing criteria on the reply to...
  15. A

    Filter "This" or "That" on one field.

    Great! I have been struggling with this all day.
  16. A

    Filter "This" or "That" on one field.

    I'm trying to use code to filter a form field with the citeria being either one value or the other. Me.frmSubmittalListSubForm.Form.Filter = "Status<>'Approved'" & "Or Status<>'Resubmitted'" Me.frmSubmittalListSubForm.Form.FilterOn = True The code runs, but doesn't filter. What is my error?
  17. A

    Filtering a Subform

    Thanks! I modified the code as such and got it to work. Me.frmRFIListSubForm.Form.Filter = "IsNull(DateToContractor) = True" Me.frmRFIListSubForm.Form.FilterOn = True
  18. A

    Filtering a Subform

    Here is a portion of my database with the problem form.
  19. A

    Filtering a Subform

    I don't get an error, however a window pops up Titled "Enter Parameter Value" I'll attach a screen shot of it.
  20. A

    Filtering a Subform

    Yes, Open and Close show properly. The button is on the parent form. Attached is a screen shot.
Back
Top Bottom