By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 916 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

stupid access db, can't do good stuff

P: n/a
This db i created has been driving me nuts. I have this one table
LOCATIONS, and in the data entry forms, the user is suppose to change
the locations of the equipment or set a location when first entered. I
set the property not to expand and limit to list, yet they somehow
edit the data there anyways. I want to prevent that. I want them to be
able to choose the options in combo box (with data from table
locations) but not edit the locations it self (the choices)...the
locked option is not going to work because it doesn't let the user to
change from location to location...it needs to be able to do that but
not edit the listing (the list it self) help anyone...
Nov 12 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Almir wrote:
This db i created has been driving me nuts.
Its possible the db is a figment of your imagination.
I have this one table
LOCATIONS, and in the data entry forms, the user is suppose to change
the locations of the equipment or set a location when first entered. I
set the property not to expand and limit to list, yet they somehow
edit the data there anyways. I want to prevent that. I want them to be
able to choose the options in combo box (with data from table
locations) but not edit the locations it self (the choices)...the
locked option is not going to work because it doesn't let the user to
change from location to location...it needs to be able to do that but
not edit the listing (the list it self) help anyone...


Is the field they are updating a text box? Or is the field a Combo box?

If it is a combo box, you Set Limit To List to true/yes In the NotInList
event, you could enter something like
Msgbox "Select a location from the list."
Response = acdataerrcontinue

Now if you have a textbox, in the BeforeUpdate event you could do
something like this
Dim varLoc As Variant
varLoc = Dlookup("YourLocationTableFieldName", _\
"LocationTableName","YourLocationTableFieldNam e = " &
Me.YourLocationTableFieldName
If IsNull(varLoc) Then
msgbox "Please don't enter new locations"
Cancel = True
Endif
Due to your frustration, you didn't cover your problem suffieciently. Let
us know if you have a combo, a text box, both text and combo, how the data
is selected in the combo...whatever else that will help us in helping you.


Nov 12 '05 #2

P: n/a
My guess is that the user(s) is going to the table that provides the
list for the combo box, and changing that list. It's easy to do if
you're using a table to populate the dropdown list.

If the source is a table, can make the table hidden (right-click on the
table's name, click properties, check-yes "Hiddden"). Then make sure
the user's machine is set to not show hidden objects (Tools - Options -
View).

You also can set up an enforced relationship between such a short-list
table and the main table. Use Tools - Relationships

You can make them leave the table alone, or you can set the dropdown
list items another way. You could do it in the properties box (Row
Source Type = Value List, and Row Source is a list of items, like:
apples;peaches;bananas;pears;oranges
Another way is to set the list values via VBA code.

Good luck!
Bruce Pick

Almir wrote:
This db i created has been driving me nuts. I have this one table
LOCATIONS, and in the data entry forms, the user is suppose to change
the locations of the equipment or set a location when first entered. I
set the property not to expand and limit to list, yet they somehow
edit the data there anyways. I want to prevent that. I want them to be
able to choose the options in combo box (with data from table
locations) but not edit the locations it self (the choices)...the
locked option is not going to work because it doesn't let the user to
change from location to location...it needs to be able to do that but
not edit the listing (the list it self) help anyone...

Nov 12 '05 #3

P: n/a
"Almir" <al*****@yahoo.com> wrote in message
news:72**************************@posting.google.c om...
This db i created has been driving me nuts. I have this one table
LOCATIONS, and in the data entry forms, the user is suppose to change
the locations of the equipment or set a location when first entered. I
set the property not to expand and limit to list, yet they somehow
edit the data there anyways. I want to prevent that. I want them to be
able to choose the options in combo box (with data from table
locations) but not edit the locations it self (the choices)...the
locked option is not going to work because it doesn't let the user to
change from location to location...it needs to be able to do that but
not edit the listing (the list it self) help anyone...


Normally one uses a different table for the list of choices than the one
being written to by the form. Is that what you're doing? In cases where a
ComboBox gets it choices by looking back at the same table it is writing to
then any time an entry is made that is not in the list then of course the
choices in the list will change, but the LimitToList property should
prevent that.

Are you allowing any other access to the data besides this one form?
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Nov 12 '05 #4

P: n/a

"It's possible the db is a figment of your imagination."
--Salad
Your combo box Control Source is set to the wrong table because your
database schema is wrong, because you have no clue how to build a database,
and because you are a moron.


"Almir" <al*****@yahoo.com> wrote in message
news:72**************************@posting.google.c om...
This db i created has been driving me nuts. I have this one table
LOCATIONS, and in the data entry forms, the user is suppose to change
the locations of the equipment or set a location when first entered. I
set the property not to expand and limit to list, yet they somehow
edit the data there anyways. I want to prevent that. I want them to be
able to choose the options in combo box (with data from table
locations) but not edit the locations it self (the choices)...the
locked option is not going to work because it doesn't let the user to
change from location to location...it needs to be able to do that but
not edit the listing (the list it self) help anyone...

Nov 12 '05 #5

P: n/a
"Brett Conway" <BC****@hotmail.com> wrote
Your combo box Control Source is . . .


"Brett" posted from the semi-anonymous news server "teranews" with a return
address of "hotmail", both frequently used by Don P Mellon hiding behind
aliases and impersonating others.
Nov 12 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.