Command button on form

  • Thread starter Thread starter KLR
  • Start date Start date
K

KLR

I have created a form which shows a list of visit reports in Tabular
view.

I want to place a command button next to the visit report entry, so
that a user can click on the button and go directly to that report.

How do I go about this?

Many thanks
 
Hi,
I assume you mean a Continuous Form. Just add a button to the right of the
record in design view. The button could then have code behind it like this:

DoCmd.OpenReport Me.ControlWhichHoldsReportName, acViewPreview

The button will be repeated for each record in the form. This is how
Continuous Forms behave.
HTH
Good luck
 
I believe the button wizard will walk you right through that. Turn on your
wizard by depressing the magic wand icon in your tool box, then place a
button on your form. The wizard will ask you all the right questions.
 
I used the button wizard which worked brilliantly, thanks very much. I
am going to study the code behind it though as I believe this will be
of interest. Thanks very much!
 
Back
Top