Choose from Option Group, Enter Notes, & Preview the Report

  • Thread starter jlig via AccessMonster.com
  • Start date
J

jlig via AccessMonster.com

I have the following code behind my cmdPreview button on a Form:
---------------------------------------------------------------
Private Sub cmdPreview_Click()
On Error GoTo ErrorPreview

Select Case [Frame0]

Case Is = 1
DoCmd.OpenReport "rptCPUpdatedSusp", acViewPreview

Case Is = 2
DoCmd.OpenReport "rptCPUpdatedDisc", acViewPreview

Case Is = 3
DoCmd.OpenReport "rptCPUpdatedReco", acViewPreview

' If you don't chose a default value, this generates a message box if the
user clicks a button without making a selection
Case Else
MsgBox "Please check a service; Suspend, Disconnect or Reconnect?",
vbExclamation, "Reports"
End Select

ExitPreview:
Exit Sub

ErrorPreview:
MsgBox Err.Description
Resume ExitPreview

End Sub
-----------------------------------------------------------

I need to add the following feature:
---------------------------------------------
1) When user clicks the cmdPreview button
2) The frmNotes form opens up,
2) User enters any notes, and clicks CLOSE, which
3) Previews the appropriate report.
---------------------------------------------

Everything works fine now, but I need the User to Choose Option, Enter Notes,
& Preview the Report.

Thanks in advance for your help,
jlig
 
K

Klatuu

Where do these notes go?
Will the notes be stored in different tables depending on report option or
what?
What version of Access are you using?
 
J

jlig via AccessMonster.com

Thanks for the response Klatuu ,

I figured it out. I placed my Case statements on the frmNotes instead.

Thanks again,
jlig
Where do these notes go?
Will the notes be stored in different tables depending on report option or
what?
What version of Access are you using?
I have the following code behind my cmdPreview button on a Form:
---------------------------------------------------------------
[quoted text clipped - 42 lines]
Thanks in advance for your help,
jlig
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top