Hi.
As I told in my first post, I'm trying to re-learning to work on Access.
I need to do it because I have to build a project in my job.
This is my question (please, don't get me wrong, but my english is not quite good!):
I have build a form with to combo boxes: in the fist one I have 5 records; in then second one, I have 3.
I reached to make a filter between the two combo boxes, I mean, when the third option of the first combo is choosen, the second combo turns visible. I made this with the event procedure "after update". This is the VBA coomand:
Private Sub Caixa_de_combinação28_AfterUpdate()
If Me![Caixa de combinação28].Text = "Execução" Then
Me![Caixa de combinação30].Visible = True
Else
Me![Caixa de combinação30].Visible = False
End If
Me![Caixa de combinação30].Requery
End Sub
"Caixa de combinação28" is the first combo;
"Execução" is the third option - the one that makes visible the second combo;
"Caixa de combinação30" is the second combo
My question is: when I open the form, and it has some records already, if one of them has the third option choosed on the first combo box, I want to make the second one visible when i load this record. I mean, in this case, the second combo would be already visible, because when the record is loaded, the first combo has the third option.
I think this must be a little confuse!!! Sorry!!!
Thanks for your support.
Best regards,
Pedro
As I told in my first post, I'm trying to re-learning to work on Access.
I need to do it because I have to build a project in my job.
This is my question (please, don't get me wrong, but my english is not quite good!):
I have build a form with to combo boxes: in the fist one I have 5 records; in then second one, I have 3.
I reached to make a filter between the two combo boxes, I mean, when the third option of the first combo is choosen, the second combo turns visible. I made this with the event procedure "after update". This is the VBA coomand:
Private Sub Caixa_de_combinação28_AfterUpdate()
If Me![Caixa de combinação28].Text = "Execução" Then
Me![Caixa de combinação30].Visible = True
Else
Me![Caixa de combinação30].Visible = False
End If
Me![Caixa de combinação30].Requery
End Sub
"Caixa de combinação28" is the first combo;
"Execução" is the third option - the one that makes visible the second combo;
"Caixa de combinação30" is the second combo
My question is: when I open the form, and it has some records already, if one of them has the third option choosed on the first combo box, I want to make the second one visible when i load this record. I mean, in this case, the second combo would be already visible, because when the record is loaded, the first combo has the third option.
I think this must be a little confuse!!! Sorry!!!
Thanks for your support.
Best regards,
Pedro