Since a couple of weeks I started to develop a new database with Access 2010 (.accdb). And somethings have changed. In my database I have the following issues which I can't figure out how it works.
1. Treeview
Previousley I had a sample database with a preview of a treeview. Unfortnatley I can't import that form in to the .accdb database. Can anyone help me to design a treeview. It will be a multilevel treeview for employees. with on top an Add Node, which should open a record in the add new mode. I should looks like this:
2. repeat option in VBA
I have created a form with a field called number. For example if this field contains the number 3, it should add 3 records to a table. If I change it to 2, it should delete 1 record.
I have written a code but this will only add or delete 1 record. Can't figure out how to repeat the code for example 3 times if the figure has changed from 0 to 3.
Example:
3. retrieve a specified record in a subform
The main form will contain a treeview object on the right side. On the left side a subform is created. After changing the selection on the treeview the appropriate record in the subform should be shown. How can I programm this in VBA.
Thanks for your help so far.
(To avoid answers like do not use the new database accdb, but the old one. A lot of hours were invested in my new database, which can not be converted into an older format of access).
1. Treeview
Previousley I had a sample database with a preview of a treeview. Unfortnatley I can't import that form in to the .accdb database. Can anyone help me to design a treeview. It will be a multilevel treeview for employees. with on top an Add Node, which should open a record in the add new mode. I should looks like this:
Code:
Add Employee
-A
-Alfa Mr
-B
-C
Charlie B Mr
Charlie C Mr
2. repeat option in VBA
I have created a form with a field called number. For example if this field contains the number 3, it should add 3 records to a table. If I change it to 2, it should delete 1 record.
I have written a code but this will only add or delete 1 record. Can't figure out how to repeat the code for example 3 times if the figure has changed from 0 to 3.
Example:
Code:
Main table : Number 3
Sub Table : Sequence 1 Datafields
2
3
after changing Number 3 into 2 the subtable will only contain sequence 1 and 2.
3. retrieve a specified record in a subform
The main form will contain a treeview object on the right side. On the left side a subform is created. After changing the selection on the treeview the appropriate record in the subform should be shown. How can I programm this in VBA.
Thanks for your help so far.
(To avoid answers like do not use the new database accdb, but the old one. A lot of hours were invested in my new database, which can not be converted into an older format of access).