[mso] Re: Access 03 - Form Field Controls

  • From: Cathy.Evans@xxxxxxxxx
  • To: mso@xxxxxxxxxxxxx
  • Date: Thu, 3 Feb 2005 08:28:50 -0500

April, I'm thinking you can add an option group to your form, set your
labels for your choices, i.e., Realtor, Friend, etc. that you want to
select.  Name the option group frame optReferredBy (or any name you choose,
as long as you name your select case same).  Modify the action events under
Case 1, 2, etc. on this sample code to match what you want to happen
depending on the selection.  You can add more Case if you have more than 2
choices.  This sample should open specific data entry forms you may have
set up, depending on result.  The option labels have corresponding number
values, match your label/case statement number with the action event you
would like to happen.

Select Case optReferredBy
   Case 1
    DoCmd.OpenForm "frmRealtorDataEntry"
   Case 2
    DoCmd.OpenForm "frmFriendDataEntry"
   Case Else
   MsgBox "Please Select Referral Type!", vbOKOnly + vbExclamation, "Select
Referral Type!"
   Me!ReferredBy.SetFocus
   Exit Sub
End Select
End Sub

I'm not good at explaining, so don't hesitate to ask if something doesn't
make sense, thanks,
Cathy


                                                                                
                                             
                      "4Groups"                                                 
                                             
                      <4groups@bellsouth.      To: <mso@xxxxxxxxxxxxx>          
                                             
                      net>                                                      
                                             
                      Sent by:                 cc:                              
                                             
                      mso-bounce@freelist                                       
                                             
                      s.org                    Subject:  [mso] Access 03 - Form 
Field Controls                               
                      02/02/2005 06:19 PM                                       
                                             
                      Please respond to                                         
                                       ..... 
                      mso                                                       
                                             
                                                                                
                                             
                                                                                
                                             




I have a form that has a field Called "Referredby"  which is a look up with
these values (the ReferredbyID is the valued saved on the Contact
Table/Form):

Yellowpages
Direct-Mailer
Other Contact
Other Realtors
Personal Friends

Now if the Referredby is Yellowpages or Direct-Mailer - then no problem....
if the Referredby is Other Contact, then I need to (automatically) add a
comment to the activity table:

1 for the New Contact - who he was referred by and 1 for the referring
contact - of who he referred.

If the Referredby is Other Realtor - then I need to log what Realtor made
the referral

If the Referredby is Personal Friend... I want to open another table and
chose or add the Friend who made the referral.

What is the best way to do this???  Do I need to start over how I am
originally logging the Referredby??  or can I force events to happen if
certain Referredby types or chosen??

April






-----------------------------------------------------------------------------------------------------
The information transmitted is intended only for the person
or entity to which it is addressed and may contain proprietary,  
business-confidential and/or privileged material.
If you are not the intended recipient of this message you 
are hereby notified that any use, review, retransmission, 
dissemination, distribution, reproduction or any action taken
in reliance upon this message is prohibited. If you received
this in error, please contact the sender and delete the 
material from any computer.  Any views expressed in this message
are those of the individual sender and may not necessarily reflect 
the views of the company.
-------------------------------------------------------------------------------------------------------

*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or 
MicrosoftOffice@xxxxxxxxxxxxxxxx

To send mail to the group, simply address it to mso@xxxxxxxxxxxxx

To Unsubscribe from this group, send an email to 
mso-request@xxxxxxxxxxxxx with the word "unsubscribe" (without the quotes) in 
the subject line.

Or, visit the group's homepage and use the dropdown menu.  This will also allow 
you to change your email settings to digest or vacation (no mail).
//www.freelists.org/webpage/mso

To be able to use the files section for sharing files with the group, send a 
request to mso-moderators@xxxxxxxxxxxxx and you will be sent an invitation with 
instructions.  Once you are a member of the files group, you can go here to 
upload/download files:
http://www.smartgroups.com/vault/msofiles
*************************************************************

Other related posts: