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 MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing between form View types.

Status
Not open for further replies.

newbilko

Technical User
Feb 28, 2006
6
GB
Hi,

This may seem like an odd request but I am trying to make an "idiot Proof" database.

I want users to be able to switch between "tabular" and "Form" views by pressing a command button on that particular form.

I have found that users do not want to, or do not understand how to use the standard button on the Access taskbar (top left corner)

What command line do I need to tell a command button to carry out this task...is this even possible?

Cheers!
 
Hi,

DoCmd.OpenForm "yourForm", acFormDS 'Datasheet

DoCmd.OpenForm "yourForm", acNormal 'Normal

-bearing in mind that if you switch to datasheet view, you won't have a command button so you might look to doing that using a subform.

Hope that helps.
 
Hi Thanks for the reply!

I now have the original form incorperated into a new one as a subform. How do I create buttons that control the subform rather than opening up the form again in a new window?

Also using the toggle buttons it should be possible to switch between modes i,e when the toggle is depressed or raised. How is this achieved.

I have tried searching the help files but to no avail :)

Many thnaks for you invaluable help!!



 
Have a look at the CurrentView property of the Form object.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top