With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.
Private Sub Form_Open(Cancel As Integer) Dim db As DAO.Database Dim rst As DAO.Recordset Dim qdf As DAO.QueryDef Dim prm As DAO.Parameter Dim vnotfound As Boolean Set db = CurrentDb Set qdf = db.QueryDefs("z nmdf iitdata review mr and adjust") For Each prm In qdf.Parameters prm.Value = Eval(prm.Name) Next Set rst = qdf.OpenRecordset If Not (rst.BOF And rst.EOF) Then vnotfound = True Else vnotfound = False End If If vnotfound = True Then rst.Close DoCmd.CancelEvent DoCmd.Close acForm, "z supplier qty adjustment" MsgBox "No records found." ElseIf vnotfound = False Then DoCmd.OpenForm "z supplier qty adjustment" DoCmd.Maximize DoCmd.ApplyFilter "z supplier qty adjustment filter" Me.FilterOn = True End If rst.Close Set rst = Nothing Set qdf = Nothing Set db = Nothing Set prm = Nothing End Sub
Join the community of 500,000 technology professionals and ask your questions.