Solved

Microsoft Access  Me.Form.AllowEdits  works too well

Posted on 2013-01-29
3
523 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

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

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…
When you are entering numbers in a speadsheet, and don't remember what 6×7 is, you just type “=6*7" instead. It works in every cell! This is not so in Access. To enter the elusive 42 in a text box, you have to find a calculator, and then copy the re…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

758 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now