473,396 Members | 1,703 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Auto update data in form from another form

Can anyone help me get this working.

table1 has 3 field, CustId, CustName, CustRate

table2 has 7 fields TimeId, TimeCustId, TimeCustName, TimeDate,
TimeStartTime, TimeEndTime, TimeCustRate, TimeRemaks

Both forms work great by them selves.

Problem -- When I enter table2 - TimeCustId, I want the 2 fields
TImeCustName and TimeCustRate to be automatically update with the
CustName and CustRate from table1.

Looking for a quick and "CLEAN" way of doing this.

Thanks,

Rodney
Apr 7 '07 #1
1 2988

"Rodney Frisard" <rf******@cox.netwrote in message
news:kl********************************@4ax.com...
Can anyone help me get this working.

table1 has 3 field, CustId, CustName, CustRate

table2 has 7 fields TimeId, TimeCustId, TimeCustName, TimeDate,
TimeStartTime, TimeEndTime, TimeCustRate, TimeRemaks

Both forms work great by them selves.

Problem -- When I enter table2 - TimeCustId, I want the 2 fields
TImeCustName and TimeCustRate to be automatically update with the
CustName and CustRate from table1.

Looking for a quick and "CLEAN" way of doing this.

Thanks,

Rodney
Remove the TimeCustName and the TimeCustRate fields from table2 because this
is not good normalisation practice. You may need to keep the TimeCustRate
field in table2 if you need to keep a history of what that customers rate
was at the time of that transaction if the customer's rate changes over
time.

If you remove those two fields in table2, create a form using table2 as its
source and bind the 6 remaining fields: TimeID, TimeCustID, TimeDate,
TimeStartTime, TimeEndTime, TimeRemarks. On that form add an unbound text
box and call it txtCustRate with the label Customer Rate. Change its enabled
property to false and its locked property to true.

Change the TimeCustID text box to a combo box and name it cboCustID. For the
recordsource for the combo box choose all 3 fields from table1 and sort the
CustName to ascending. For the column count property of the combo box, set
this to 3. In the combo boxes column width property, set this to
0cm;3cm;1.5cm (or 0";1.2";0.6" if using inches) and change the list width
property to 5cm (1.8"). In the recordsource property of the txtCustRate type
"=cboCustID.Column(2)" without the quotes.

Save your form and when ever you select a customer from the combo box list,
you won't see the customer id and the customer's rate will automatically
appear in the rate field.

Jeff
Apr 7 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jerry Brenner | last post by:
Our users have potentially dirty legacy data that they need to get into our application. We provide a set of staging tables, which map to our source tables, that the users do their ETL into. ...
8
by: Bruce Stockwell | last post by:
the setup: Webservice/WinClient application/SQL server. VS.Net (visual basic) winform wizard creates a simple form with load cancel cancelall and datagrid bound to a simple Dataset with one...
6
by: Alpha | last post by:
I retrieve a table with only 2 columns. One is a auto-generated primary key column and the 2nd is a string. When I add a new row to the dataset to be updated back to the database. What should I...
5
by: Josselin | last post by:
I have a page 'pni.php' to which paypal is redirecting after payment thsi page contains a db update script, no problem it's running well but once this script is executed (transparently for the...
0
by: saraDotNet | last post by:
Hi, I'v Two Questions: 1-Is there a way to make an auto numbering avalible in vb.net form textbox as the one in Access db columns when we set the datatype as autonumbering?? 2- I'm working on a...
5
by: Stephen Plotnick | last post by:
I'm very new to VB.NET 2003 Here is what I have accomplished: MainSelectForm - Selects an item In a public class I pass a DataViewRow to ItemInformation1 Form ItemInformation2 Form
1
by: ainsley | last post by:
Hi this is going to sound like a very basic question, but I am creating a database in Access which is based on a number of unlimited tables. In my data entry form i have a number of combo boxes...
5
by: joshua.nicholes | last post by:
I have an access database that consists of two tables.A data collection table and a species list table. The data collection table has about 1500 records in it and the species list has about 600....
3
by: Puzzled and Confused | last post by:
It seems like a simple request, but I cannot get it to work. Does anyone know to how to make data from one field auto populate in another field, only if the answer is yes/true? I have a form that I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.