A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Unchangeable field



 
 
Thread Tools Display Modes
  #1  
Old February 5th, 2009, 11:33 PM posted to microsoft.public.access.tablesdbdesign
MarianneZ
external usenet poster
 
Posts: 26
Default Unchangeable field

In my table I have 2 fields that I do not want users to change. It's okay if
Vba code changes the values, but not a user directly. Is there any way to
enforce this?
  #2  
Old February 5th, 2009, 11:46 PM posted to microsoft.public.access.tablesdbdesign
Jeanette Cunningham
external usenet poster
 
Posts: 2,190
Default Unchangeable field

Hi MarianneZ,
yes, instead of letting users type directly in the tables, give them forms
to use instead.

In a form, you can show the value for a field, but you can lock the control
so that they can't change it, but VBA code can change the value.

There is no way (that I am aware of) to prevent users from changing values
in tables when they can open the table themselves.

Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia


"MarianneZ" wrote in message
...
In my table I have 2 fields that I do not want users to change. It's okay
if
Vba code changes the values, but not a user directly. Is there any way to
enforce this?



  #3  
Old February 6th, 2009, 01:17 PM posted to microsoft.public.access.tablesdbdesign
bhicks11 via AccessMonster.com
external usenet poster
 
Posts: 529
Default Unchangeable field

Change the LOCKED property to YES. You can change it to NO in VBA if you
need to make changes and then change it back so users can't. You will find
the property in the DATA tab of the property sheet.

Bonnie
http://www.dataplus-svc.com

MarianneZ wrote:
In my table I have 2 fields that I do not want users to change. It's okay if
Vba code changes the values, but not a user directly. Is there any way to
enforce this?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...esign/200902/1

  #4  
Old February 6th, 2009, 08:58 PM posted to microsoft.public.access.tablesdbdesign
MarianneZ
external usenet poster
 
Posts: 26
Default Unchangeable field

I know I can do this in a form. It's in the table that I want the field to be
readonly. Don't other people need this capability also?

Do I need to force my users to go through a menu and a form? How do I
prevent them from just opening the table and changing this field? Maybe even
by accident.

By the way, I'm using Access 2007 and DAO

"bhicks11 via AccessMonster.com" wrote:

Change the LOCKED property to YES. You can change it to NO in VBA if you
need to make changes and then change it back so users can't. You will find
the property in the DATA tab of the property sheet.

Bonnie
http://www.dataplus-svc.com

MarianneZ wrote:
In my table I have 2 fields that I do not want users to change. It's okay if
Vba code changes the values, but not a user directly. Is there any way to
enforce this?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...esign/200902/1


  #5  
Old February 6th, 2009, 09:26 PM posted to microsoft.public.access.tablesdbdesign
Jeanette Cunningham
external usenet poster
 
Posts: 2,190
Default Unchangeable field

Yes, this is something many developers do.
Use a menu and a form.
Hide the nav pane from the users and make sure there are no options on the
ribbon that give users the ability to open the tables directly.

Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia

"MarianneZ" wrote in message
...
I know I can do this in a form. It's in the table that I want the field to
be
readonly. Don't other people need this capability also?

Do I need to force my users to go through a menu and a form? How do I
prevent them from just opening the table and changing this field? Maybe
even
by accident.

By the way, I'm using Access 2007 and DAO

"bhicks11 via AccessMonster.com" wrote:

Change the LOCKED property to YES. You can change it to NO in VBA if you
need to make changes and then change it back so users can't. You will
find
the property in the DATA tab of the property sheet.

Bonnie
http://www.dataplus-svc.com

MarianneZ wrote:
In my table I have 2 fields that I do not want users to change. It's
okay if
Vba code changes the values, but not a user directly. Is there any way
to
enforce this?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...esign/200902/1




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:11 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.