Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Open Form

Status
Not open for further replies.

CLOS

MIS
Jan 30, 2002
23
0
0
US
Need Some Expert HELP,

I have some users that are complaining about when they
click on the "PREVIEW" button to preview a report, the preview screen in access doesn't center the report. So,
inorder for the user to view the entire report, he or she would have to click on the scroll bar and move it to the left to see additional columns. I don't think there is a
way to center a report thats in PREVIEW mode. However,
to get around this so called problem I set the preview reports up on forms which works great. But, How do I handle a situation where the form has no records to display. In otherwords, I have a search dialog box that
accepts a parameter, if the value in that parameter doesn't
match the forms record source, than I want to display a message to the user and cancel the action.
 
Hi,

Try this at the Form Open event

If Me.RecordSetClone.RecordCount=0 Then
MsgBox "No Records Found."
Cancel=True
End If

Hope this is of some help to you.

LSTAN
 
you can also add the command maximize after the report opened.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top