Here is how you refer to subforms and controls on it. Let's assume:
Subform name: "sfSubForm"
Label on the subform: "lblLabel"
Your code to hide label on the subform should be:
Code:
Me!sfSubForm.Form!lblLabel.Visible = False
Me!sfSubForm.Form!lblLabel.Visible = False
Set rst2 = Forms![frmMain]![subfrm_tblOverkeyDataBatchID].Form.Recordset Set rst1 = Forms![frmMain]![subfrmgd_tblPrimaryDataBatch].Form.Recordset
FinalString: [EMP_ID]&Format(Fix([dedamt]) & Right(Format([dedamt];"#,00");2);"00000000")
Dim ctl As Control Dim ctlName As String Private Sub Combo5_Enter() Me!Combo5.RowSource = "" For Each ctl In Me!sfTable1.Form.Controls If ctl.ControlType = acTextBox Then Me!Combo5.AddItem ctl.Name End If Next ctl End Sub Private
If Me![CheckBoxName]=True Then Me![TextBoxName] = Date End If
=iif(SubReportName.Report.HasData = False ; 0 ; SubReportName.Report.TotalFieldName)
Leave a comment: