Renegade Form

G

Guest

I have an application with a number of forms. I can control read only access
to forms through a group in the workgroup file for all but one form. The
form uses a query that includes 2 tables.

- The form security is set to Open/Run only
- The query used for the form is set to Read Design and Read Data
- The tables that form the query are set to Read Design and Read Data

I wanted users who are part of this group to only read data. Problem is
they can modify data on the form. I have checked individual permissions for
the users and there are none set. The only odd thing I do with this form is
to set some properties depending how it is opened based on a parameter passed
to it by the particular button used to open it.

NewProjScr = Forms!frmProjectTab.OpenArgs

If NewProjScr = "1" Then
Me.AllowAdditions = True
Me.DataEntry = True
Else
Me.AllowAdditions = False
Me.DataEntry = False
End If

Can anyone suggest why the read only permission is being overridden for this
form?
 
J

Joan Wild

Based on the information provided, they would have only read permission.
Double-check each user's permission, as well as 'the' group of interest.

In addition, double-check other groups that the user(s) belong to i.e. Users
and any other custom groups. You are overlooking something.
 
G

Guest

Hi Joan
Checked all the above. Let me ask this question. Can any VBA command, or
form settings override the workgroup permissions.

Neville
 
J

Joan Wild

The settings won't over-ride permissions. The VBA code you've posted
wouldn't impact it. You'd actually have to change permissions in code for
it to happen. Do you have any code that modifies the form's recordsource,
or changes the SQL of the recordsource?
 
G

Guest

Hi Joan
I do change recordsource but both queries have restricted permissions.
Neville
 
J

Joan Wild

Changing the recordsource in code requires the user running the code to have
modify permissions on the query. Furthermore, if you use WITH OWNERACCESS
in this scenario, it's a non-starter as the user running the code would be
the 'owner' and would need permissions on the source tables/queries
involved.

For this query, you can create a RWOP query for each of the underlying
tables. Then create a query based on these queries. It is this final query
that you modify the SQL property in code.
 
G

Guest

Thanks Joan. That makes some sense and will give me something to work with.
The problem is probably in the area you identified. I will work on it next
week.
Thanks for all your help.
Neville
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top