i have a trouble in inherit value list of access 2007

N

nancy

i am new programmer and use access 2007 to do customed software. I have a
trouble with a combo box. i enable its properties of inherit value list and
Allow value list edit, which make user can add items in the list. But when i
changed the progam to be a .accdr , function above is disable, user can not
add new item in the value list , why ? what happened? i think it is
unreasonable, mybe something i did is wrong, maybe something i have to do.


thank you for help

it seems to be related to "allow full menus". i must offer user a .accdr ,
how can i do?
 
T

Tom van Stiphout

On Sun, 14 Dec 2008 04:16:00 -0800, nancy

This property is new in A2007 and it is very poorly documented.
I will ask my MVP colleagues to see if there is more. For now I would
suggest finding an alternate way.

-Tom.
Microsoft Access MVP
 
A

Arvin Meyer [MVP]

As a well seasoned developer, may I suggest that is extremely poor database
design, despite the fact that Microsoft allows it in Access 2007 (but no
previous versions) Users will invariably enter bad data, or worse yet,
delete or edit good data. It won't take long before your database has piles
of garbage data. In certain circumstances, users need to be able to enter
new data in a table using a combo box or list box, but never should they be
allowed to enter data in a value list.

There are lots of ways to make a mistake and ruin a database with poor
design. IMO, this is one of them. You might consider, using a table to store
the contents of the list, and allow adding data to the table (do not allow
edits or deletes). You can do that with code in the NotInList event. Sample
code is at:

http://www.datastrat.com/Code/NotInListCode.txt

and a sample database using this code is at:

http://www.accessmvp.com/Arvin/NotInListDemo.zip

Even then, unless you regularly need to add data, such as a new customer,
avoid this technique.
 
A

AccessVandal via AccessMonster.com

Have you check the Trusted Locations? Just a guess.

Are the users using full version of Access2007? or Runtime?
 
N

nancy

thank you for your help

i suspected that it may a bug of access2007, now i thik my guess is right
based on your instruction. acturally i can finish it by a table like before
version. because that is a beautiful look and attractive for clients, so i
try my best to do it, now i have to give up. thank you
 
A

Albert D. Kallal

Nancy just as a side note (now you've got a lot of advice), that a value
list is actually hard coded and becomes part of the actual form itself.
(this is why you can't change this when you use a accdr - this prevents
users from modifying your design).

As you move up the tree of learning about development, you'll find that when
you deploy an application to your client or your users desktops, you want to
deploy in such a way that they're not going to be allowed to develop or
change or modify what you've created so far.

To make a long story short, using a value list for something that's going to
change is a bad idea. However, since you have a requirement to allow users
for yourself to add to this list, then I suggest you simply use a table
in place of those values hard coded into the form.

If you do the above, then the new features in access 2007 fine to use.Note
that using values from a table means your have to create a form with
wizard (or yourself) that allows you to edit that list (which is now in a
table). You then specify this form in the setting called:

List items edit form.

In other words the above approach is not a whole lot of difference
then using a bunch of code and "not in list feature" for a combo box.
(Both approaches will allow all your users to add new values to this list).

So, the above approach allows you to do this whole thing without
writing one line of code.
 
A

AccessVandal via AccessMonster.com

Those aren’t bugs. The accde and accdr format does not allow form design
changes. The accdb allows design changes and must be trusted locations or at
least with macros enabled.

The links given by Tom and Arvin should be the way to go.

PS. I misread your “Allow value list edit†part.
 
A

Arvin Meyer [MVP]

nancy said:
thank you for your answer.

i can open http://allenbrowne.com/ser-27.html, after talking with you,i
feel i have to give up.

No, don't give up. Re-assess your criteria and ask the best way to
accomplish, or possible if you should accomplish it at all. There's always a
preferred way to go about things. As a new developer, it might be good to
get a handle on how to best accomplish that. Crystal Long, Access MVP
Extraordinaire has a great tutorial:

http://www.accessmvp.com/Strive4Peace/Index.htm

and Michael J Hernandez has a great introduction to data modeling in his
book:

Database Design For Mere Mortals
 
Top