Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / March 2005

Tip: Looking for answers? Try searching our database.

Problem with Query or code?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Donald - 03 Mar 2005 16:29 GMT
I have a combo box(tech name) with its row souce query2. Query2 pulls
Tech_name; Tech_email; Tech_PhoneNumber from my tech table. I am running this
after update:

Private Sub Technician_AfterUpdate()
    [TECHNICIAN_PHONE] = Technician.Column(2)
    [TECHNICIAN_EMAIL] = Technician.Column(1)
End Sub

Basicly what I want it to do is after you select the name of the technician
the Technician_phone and Technician_Email are auto inputted. The problem is
only the value in column 1 is works. What I mean is the Technician_phone is
not updated whil the Technician_email is. Running the query shows both
columns populated But for some reason im not able to pull data from the
second column.
Steve Schapel - 04 Mar 2005 18:36 GMT
Donald,

I assume that Technician is the name of the combobox, and not tech name
as you started off with?  The only thought I have on the specific
question is that perhaps [TECHNICIAN_PHONE] is not the correct name for
the control on your form.

However, a couple of comments not directly on your question...  What you
are doing here would generally be regarded as an invalid process.  A
database is supposed to be used relationally, part of which means that
data should not be replicated from one part of the database to another.
 Whatever the record source of your form, it should only have one field
referring to the technician, corresponding to the unique identifier for
the technician.  There are various approaches to getting the Phone and
Email showing up on the form, but they do *not* include writing the data
into the fields.  By the way, it looks like the unique identifier
(primary key?) for the tech in the Tech table is Tech_name, am I right?
 If so, you have to consider whether it will ever be possible to have
two Techs with the same name.

Signature

Steve Schapel, Microsoft Access MVP

> I have a combo box(tech name) with its row souce query2. Query2 pulls
> Tech_name; Tech_email; Tech_PhoneNumber from my tech table. I am running this
[quoted text clipped - 11 lines]
> columns populated But for some reason im not able to pull data from the
> second column.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.