Solved

Microsoft Access 2003 VBA coding to change a form's Record Locks property to Edited Record instead of No Locks.

Posted on 2008-06-19
1
378 Views
Last Modified: 2013-11-27
I need a VBA function that will allow me to enter the name of the form and change the form's Record Locks property to Edited Record instead of No Locks.

Thanks in advance.

Stephen
0
Comment
Question by:stephenlecomptejr
1 Comment
 
LVL 119

Accepted Solution

by:
Rey Obrero earned 500 total points
ID: 21823955
Sub changeP(sform As String)
Dim prp As Property
On Error Resume Next
DoCmd.OpenForm sform, acDesign, , , , acHidden
    For Each prp In Forms(sform).Properties
        If prp.Name = "RecordLocks" Then
        prp.Value = 2
        End If
    Next
DoCmd.Close acForm, sform, acSaveYes
End Sub
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

Title # Comments Views Activity
count unique records in access report 2 23
Run Time Error 3075 15 45
Library not Registered 16 49
access 7 25
In the article entitled Working with Objects – Part 1 (http://www.experts-exchange.com/Microsoft/Development/MS_Access/A_4942-Working-with-Objects-Part-1.html), you learned the basics of working with objects, properties, methods, and events. In Work…
I originally created this report in Crystal Reports 2008 where there is an option to underlay sections. I initially came across the problem in Access Reports where I was unable to run my border lines down through the entire page as I was using the P…
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…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

920 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

18 Experts available now in Live!

Get 1:1 Help Now