Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > Access Forms > Auto-Populate I...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 3 Topic 44658 of 46475
Post > Topic >>

Auto-Populate Info in Textbox when a selection is made in Combobox

by "cwAFcontractor" <u45335@[EMAIL PROTECTED] > Aug 7, 2008 at 06:03 PM

I'm new to this Access Database world and i'm tasked with creating a
database
to keep track of the inventory in my shop. I'm creating a form that will
imput information into a table. On this Form there is a section at the
bottom
where you can put the Authorizing information. There is a combo box which
you
can select the authorizing party (only two as of right now), and two text
boxs (one is email of AP and the other is Phone of AP). What i would like
to
happen is when the AP is selected in the combo box i would like the
corrisponding email and phone be imput into the corresponding text boxes.

I have no idea how to start this. I have tried reading a few threads and
books but can't find exactly what i'm looking for. I have tried to do the
afterupdate wizard when you used more then one column in the combo box
wizard
and don't think i did it right because it messed up the combo box and only
gave one option with all the info on one line. I also tried writing a vb
code
to imput the information but dont think i did that right either because
nothing happened when i selected the option in the combo box. As long as i
have only one column in the combo box it works fine for the combo box but
i
can't get the info populated. below is the vb code that i used but didnt
work.


Private Sub enterdata_AfterUpdate()

Set Number = Form_COTSRequest.CORPhoneNumber
Set Email = Form_COTSRequest.COREmail

If CmbCORName = "fn ln" Then
    Number = "XXX-225-XXX9"
    Email = "fname.lname@[EMAIL PROTECTED]
"
ElseIf CmbCORName = "MSgt fn Ln" Then
    Number = "XX-225-XXX8"
    Email = "fname.lname@[EMAIL PROTECTED]
"
End If
End Sub
 




 3 Posts in Topic:
Auto-Populate Info in Textbox when a selection is made in Combob
"cwAFcontractor"  2008-08-07 18:03:26 
Re: Auto-Populate Info in Textbox when a selection is made in Co
"Graham Mandeno"  2008-08-08 12:31:44 
Re: Auto-Populate Info in Textbox when a selection is made in Co
"cwAFcontractor via   2008-08-08 12:54:11 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Dec 1 20:54:58 CST 2008.