I've created a split form. One record's data elements appear at the top, while data sheet of all records in recordset is visbile below.
In the after update event for a combobox on the form I've placed the following code which works well:
I've placed the same code in the Form's Current Event, and it does not have the desired affect. If I navigate to a new record either via clicking on the data sheet, or using the form's navigation bar, the cboBiding control appears, but not the label, regardless of the records cbojobtype value. It also seems that the cboBinding control doesn't completely appear, it seems to be missing its border. Breaking the code and stepping through indicates the visible properties are indeed being changed appropriately during the From_Current event, but the form does not display the cboBinding control correctly.
Once present, the partially drawn cboBinding will not disappear again based on a record change.
Using the form's cboJobType control to change the value for a particular record results in the intended behavior on the cbo/lblBinding.
I can't explain it. Any ideas?
In the after update event for a combobox on the form I've placed the following code which works well:
Code:
Private Sub cboJobtype_AfterUpdate()
'visibility of Binding Combo based on Job type
Me!cboBinding.Visible = (Nz(Me!cboJobtype.Column(1)) = "Binding")
Me!lblBinding.Visible = Me!cboBinding.Visible
End Sub
I've placed the same code in the Form's Current Event, and it does not have the desired affect. If I navigate to a new record either via clicking on the data sheet, or using the form's navigation bar, the cboBiding control appears, but not the label, regardless of the records cbojobtype value. It also seems that the cboBinding control doesn't completely appear, it seems to be missing its border. Breaking the code and stepping through indicates the visible properties are indeed being changed appropriately during the From_Current event, but the form does not display the cboBinding control correctly.
Code:
Private Sub Form_Current()
'visibility of Binding Combo based on Job type
Me!cboBinding.Visible = (Nz(Me!cboJobtype.Column(1)) = "Binding")
Me!lblBinding.Visible = Me!cboBinding.Visible
End Sub
Once present, the partially drawn cboBinding will not disappear again based on a record change.
Using the form's cboJobType control to change the value for a particular record results in the intended behavior on the cbo/lblBinding.
I can't explain it. Any ideas?