PC Review


Reply
Thread Tools Rate Thread

Change operations from Excel to Access (Validations TO ???)

 
 
SKelly
Guest
Posts: n/a
 
      16th Apr 2009
I used a Validation rule in Excel but how do I do the same in Access.
I have two Tables
1. Account Group 2. Account Type (in two deferent tables)
Field 1 (only one) Field 1: Field 2:
-A -1 A
-B -2 B
-3 B

How do I get a Combo box with look up info. from Account Type to only show
the options from what is selected in Account Groups. (In a Form not a query
or table).
I.E. I select “B” in the Account Group drop down. Only “2, &3” should show
up as choices.
How do I make this happen? Thank you!

--
Susan Kelly
 
Reply With Quote
 
 
 
 
Crystal (strive4peace)
Guest
Posts: n/a
 
      17th Apr 2009
Hi Susan,

you have left out important details from your question ...

"to only show the options from what is selected in Account Groups

you did not show or specify the filed(s) from Account Groups that
determine this. I am assuming you have multiple entities you are
dealing with.


Warm Regards,
Crystal
remote programming and training

http://www.YouTube.com/user/LearnAccessByCrystal

Access Basics
http://www.AccessMVP.com/strive4peace
free 100-page tutorial that covers essentials in Access

*
(: have an awesome day
*


SKelly wrote:
> I used a Validation rule in Excel but how do I do the same in Access.
> I have two Tables
> 1. Account Group 2. Account Type (in two deferent tables)
> Field 1 (only one) Field 1: Field 2:
> -A -1 A
> -B -2 B
> -3 B
>
> How do I get a Combo box with look up info. from Account Type to only show
> the options from what is selected in Account Groups. (In a Form not a query
> or table).
> I.E. I select “B” in the Account Group drop down. Only “2, &3” should show
> up as choices.
> How do I make this happen? Thank you!
>

 
Reply With Quote
 
John W. Vinson
Guest
Posts: n/a
 
      17th Apr 2009
On Thu, 16 Apr 2009 15:44:01 -0700, SKelly <(E-Mail Removed)>
wrote:

>I used a Validation rule in Excel but how do I do the same in Access.
>I have two Tables
>1. Account Group 2. Account Type (in two deferent tables)
> Field 1 (only one) Field 1: Field 2:
> -A -1 A
> -B -2 B
> -3 B
>
>How do I get a Combo box with look up info. from Account Type to only show
>the options from what is selected in Account Groups. (In a Form not a query
>or table).
>I.E. I select B in the Account Group drop down. Only 2, &3 should show
>up as choices.
>How do I make this happen? Thank you!


Access and Excel are different. It SOUNDS like you want a "conditional combo
box", which is easy to create on a form. As Crystal says, though, we'll need
more information about the structure and relationship of your tables.
--

John W. Vinson [MVP]
 
Reply With Quote
 
SKelly
Guest
Posts: n/a
 
      17th Apr 2009
I have a total of three Tables total but one is combining the two first
tables and adding more detail to the overall table.
T1. Account Groups:
Fields are- Auto #: Account Group:
1 Alpha
2 Bravo
3 Charlie
4 Delta

T2. Account Types:
Auto # Account Group: Account Type:
(This is a drop down (text box)
pulled from above table)
1 Alpha IT support
2 Charlie Pricing
3 Bravo Maintenance
4 Alpha Security
5 Delta Facility
6 Alpha Pricing


T3. Main Account info.:
Auto #: Account Group: Account Type: Name:
Work location:
(Both are pulled from table 1 & table 2)
Alpha IT support Jeff Smith 1
2 Charlie Pricing Amy Jones 2
3 Bravo Maintenance Joe Backer 1
4 Alpha Security Mike Keller 1
5 Delta Facility Jan Johnson 2
6 Alpha IT support John Doe 1


When I add a new person to my form and select ….Alpha from my Account Group
(drop down box) I would like my Account Type to only show those options that
fall under that Account Group. (Example: Alpha) (Result: Only the choices IT
support, Security & Pricing show up)

I would also like to apply this to a multi selection search or filter form.
I hope this is enough information.

--
Susan Kelly


"John W. Vinson" wrote:

> On Thu, 16 Apr 2009 15:44:01 -0700, SKelly <(E-Mail Removed)>
> wrote:
>
> >I used a Validation rule in Excel but how do I do the same in Access.
> >I have two Tables
> >1. Account Group 2. Account Type (in two deferent tables)
> > Field 1 (only one) Field 1: Field 2:
> > -A -1 A
> > -B -2 B
> > -3 B
> >
> >How do I get a Combo box with look up info. from Account Type to only show
> >the options from what is selected in Account Groups. (In a Form not a query
> >or table).
> >I.E. I select “B” in the Account Group drop down. Only “2, &3” should show
> >up as choices.
> >How do I make this happen? Thank you!

>
> Access and Excel are different. It SOUNDS like you want a "conditional combo
> box", which is easy to create on a form. As Crystal says, though, we'll need
> more information about the structure and relationship of your tables.
> --
>
> John W. Vinson [MVP]
>

 
Reply With Quote
 
John W. Vinson
Guest
Posts: n/a
 
      17th Apr 2009
On Fri, 17 Apr 2009 11:24:01 -0700, SKelly <(E-Mail Removed)>
wrote:

>I have a total of three Tables total but one is combining the two first
>tables and adding more detail to the overall table.
> T1. Account Groups:
>Fields are- Auto #: Account Group:
> 1 Alpha
> 2 Bravo
> 3 Charlie
> 4 Delta
>
> T2. Account Types:
>Auto # Account Group: Account Type:
> (This is a drop down (text box)
> pulled from above table)
>1 Alpha IT support
>2 Charlie Pricing
>3 Bravo Maintenance
>4 Alpha Security
>5 Delta Facility
>6 Alpha Pricing
>


It sounds like you're another victim of Microsoft's misdesigned, misleading,
monstrous Lookup Field misfeature. See
http://www.mvps.org/access/lookupfields.htm
for a critique. The Account Group in your T2 APPEARS to contain "Alpha" but it
does not; it actually contains 1 - a numeric link to T1's primary key.

> T3. Main Account info.:
>Auto #: Account Group: Account Type: Name:
>Work location:
> (Both are pulled from table 1 & table 2)
> Alpha IT support Jeff Smith 1
>2 Charlie Pricing Amy Jones 2
>3 Bravo Maintenance Joe Backer 1
>4 Alpha Security Mike Keller 1
>5 Delta Facility Jan Johnson 2
>6 Alpha IT support John Doe 1
>


Same applies. The Account Type is actually storing a number (e.g. you see
"Pricing" but what's stored is 6.

>When I add a new person to my form and select .Alpha from my Account Group
>(drop down box) I would like my Account Type to only show those options that
>fall under that Account Group. (Example: Alpha) (Result: Only the choices IT
>support, Security & Pricing show up)


You can do this on a Form very easily. AFAIK you cannot do it in a table. Bind
a combo box to the Account Type field, based - not on your T3 - but on a Query
such as

SELECT [AccountTypeID], [Account Type] FROM T2 WHERE T2.[Account Group] =
Forms!YourFormName!YourFirstComboName ORDER BY [Account Type];

You'll need to adjust field and table names of course. You will also need to
Requery this combo box in the afterupdate event of the first combo.

>I would also like to apply this to a multi selection search or filter form.
>I hope this is enough information.


Well, a bit more info about what you mean by a "multi selection search or
filter form" would help. Multiselect listboxes can be used for searching but
it's a bit clumsy and requires some VBA code.
--

John W. Vinson [MVP]
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Data Validations SaM Microsoft Excel Programming 7 12th May 2010 03:02 AM
Help with validations in Excel Raj Microsoft Excel Programming 1 21st Sep 2009 05:21 AM
What are automation operations in Access and how can I change them K Bird Microsoft Access Macros 2 6th Dec 2007 10:03 AM
Validations in excel for particular column =?Utf-8?B?VmlqYXkgS290aWFu?= Microsoft Excel Misc 4 7th Nov 2006 05:39 PM
How do I put in more than 7 validations in IF FORMALA in EXCEL =?Utf-8?B?SG93IGRvIEkgcHV0IGluIG1vcmUgdGhhbiA3IHZh Microsoft Excel Worksheet Functions 3 26th Oct 2005 12:31 PM


Features
 

Advertising
 

Newsgroups
 


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