Hi Guys,
I would appreciate it very much if someone could help me with the following:
I have created a database application by making use of an Ms Access database format (not ODBC). The application consist of two forms:
fMain
fTest
Database Name: UserInfo.mdb
The first form asks the user his personal information like, Name, Surname etc. The user enter his details at the first form (and do not update the database yet) and click on a proceed button to go to the second form. At the second form the user complete a test. After the test is completed, he clicks on a button, btnCompute. The result of the the test are displayed by making use of a label, lblResult.
Now here is were I need help: When the user clicked on the compute button, the results that are displayed by the lblResult (label), must also be written to the database. The database must then be updated so that the final data in the database should look like this:
Name: James
Surname: Bond
Gender: Male
Test Result: 78%
NOTE: As you noticed, the data of the first form (fMain) are part of the data (test result) of the second form (fTest). I need some help on how to do this.
The second problem that I am having is the following:
As part of data in my database, I want to write the system time & date at the moment the update button is clicked. (If possible the system date must also be written to the database) – all together with the details of the user that he have entered at the first form. For example:
Name: James
Surname: Bond
Gender: male
Test Result: 78%
Time test was completed: 09:15
Date: 06/08/2002
I thought about something like this:
Create a Date/Time field (eg SystemTime) in the desired table.
-Create a recordset in code
-Use the .AddNew methode to create a new entry
-Set the desired field to Now(): .Fields("SystemTime".Value = Now()
-Update recordset
I am not really sure how to implement this – would appreciate some ideas…
Thanks guys for your time…
Regards
C-Power
I would appreciate it very much if someone could help me with the following:
I have created a database application by making use of an Ms Access database format (not ODBC). The application consist of two forms:
fMain
fTest
Database Name: UserInfo.mdb
The first form asks the user his personal information like, Name, Surname etc. The user enter his details at the first form (and do not update the database yet) and click on a proceed button to go to the second form. At the second form the user complete a test. After the test is completed, he clicks on a button, btnCompute. The result of the the test are displayed by making use of a label, lblResult.
Now here is were I need help: When the user clicked on the compute button, the results that are displayed by the lblResult (label), must also be written to the database. The database must then be updated so that the final data in the database should look like this:
Name: James
Surname: Bond
Gender: Male
Test Result: 78%
NOTE: As you noticed, the data of the first form (fMain) are part of the data (test result) of the second form (fTest). I need some help on how to do this.
The second problem that I am having is the following:
As part of data in my database, I want to write the system time & date at the moment the update button is clicked. (If possible the system date must also be written to the database) – all together with the details of the user that he have entered at the first form. For example:
Name: James
Surname: Bond
Gender: male
Test Result: 78%
Time test was completed: 09:15
Date: 06/08/2002
I thought about something like this:
Create a Date/Time field (eg SystemTime) in the desired table.
-Create a recordset in code
-Use the .AddNew methode to create a new entry
-Set the desired field to Now(): .Fields("SystemTime".Value = Now()
-Update recordset
I am not really sure how to implement this – would appreciate some ideas…
Thanks guys for your time…
Regards
C-Power