cparralesl
Programmer
Ui guys,
I have had hard tme with a subform placed in a tab. I've spend two day woith no luck. Here is the issue:
The main form doesn't have a recordSource. There is a tab control and in each page i have a ListBox on wich I load records using code. I also created a sub form that I want to tie to the ListBox, the final behavior I want toahve is: For each item selected in the listbox, the sub form change the set of records according to the item selected in the Listbox.
Ex: The use selects a Prodcut Category in the listbox, the subform shows all the products that belongs to that category. I've place the same controls in differents pages of the tab. Of course, the data for each tab are all different, the Product/Category its an example.
The problem is with LinkMasterFields and the LinkChildFields . I'm setting this properties with code, but i can not make it work.
The value for the LinkMasterFields I save it in a Label.
Here is my code:
The above is not workinh.
I Also have read all the posts about LinkMasterFields and LinkChildfields, but does not works.
Huys, I really appreciate the help you can give me about it.
Regards,
So, the code I use
Cesar Humberto Parrales
Application Support
I have had hard tme with a subform placed in a tab. I've spend two day woith no luck. Here is the issue:
The main form doesn't have a recordSource. There is a tab control and in each page i have a ListBox on wich I load records using code. I also created a sub form that I want to tie to the ListBox, the final behavior I want toahve is: For each item selected in the listbox, the sub form change the set of records according to the item selected in the Listbox.
Ex: The use selects a Prodcut Category in the listbox, the subform shows all the products that belongs to that category. I've place the same controls in differents pages of the tab. Of course, the data for each tab are all different, the Product/Category its an example.
The problem is with LinkMasterFields and the LinkChildFields . I'm setting this properties with code, but i can not make it work.
The value for the LinkMasterFields I save it in a Label.
Here is my code:
Code:
Me.[SFGinteresxCiudad].LinkMasterFields = Me.lblBarComValue.Caption
Me.[SFGinteresxCiudad].LinkChildFields = Me.[SFGinteresxCiudad].Form.ID_DEPARTAMENTO
The above is not workinh.
I Also have read all the posts about LinkMasterFields and LinkChildfields, but does not works.
Huys, I really appreciate the help you can give me about it.
Regards,
So, the code I use
Cesar Humberto Parrales
Application Support