Solved

Microsoft Access  Me.Form.AllowEdits  works too well

Posted on 2013-01-29
3
534 Views
Last Modified: 2013-01-29
Access 2010  continuous form

I have added an option button to my access form.   See code below.   It works only once :)

What options do I have here.?

Private Sub OptAllowEdits_AfterUpdate()
       Me.Form.AllowEdits = OptAllowEdits
End Sub
0
Comment
Question by:peispud
3 Comments
 
LVL 14

Expert Comment

by:Bill Ross
ID: 38831078
Hi,

Once you set a form property it stays that way until you set it differently or close and repoen the form to get the default property setting.

What do you want to happen?

Regards,

bill
0
 
LVL 61

Accepted Solution

by:
mbizup earned 500 total points
ID: 38831088
Are you trying to toggle it?

The click event of a label works well for this sort of thing:

Private Sub lblMyLabel_Click()

Me.AllowEdits = Not (Me.AllowEdits )
Me.lblMyLabel.Caption = iif(Me.AllowEdits = true, "Disable Edits", "Enable Edits")

End Sub

Open in new window

0
 

Author Closing Comment

by:peispud
ID: 38831140
Yes,  I am trying to toggle.
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In the previous article, Using a Critera Form to Filter Records (http://www.experts-exchange.com/A_6069.html), the form was basically a data container storing user input, which queries and other database objects could read. The form had to remain op…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question