Hello programmers,
When I request a report to print I get an error with this code. I have this activate in the detail section with the event procedure on format. I am sure this occurs because there is no data to be displayed. How can I stop this code from running if the data is null?
Sample of vb code that is activated:
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Const WHITE = 16777215
Const GRAY = 12632256
If (Me![LineNum] Mod 2) = 0 Then
Me![MemberID].BackColor = WHITE
Me![DateOfPlan].BackColor = WHITE
Me![Text74].BackColor = WHITE
Else
Me![MemberID].BackColor = GRAY
Me![DateOfPlan].BackColor = GRAY
Me![Text74].BackColor = GRAY
End If
End Sub
Sincerely,
Felix
When I request a report to print I get an error with this code. I have this activate in the detail section with the event procedure on format. I am sure this occurs because there is no data to be displayed. How can I stop this code from running if the data is null?
Sample of vb code that is activated:
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Const WHITE = 16777215
Const GRAY = 12632256
If (Me![LineNum] Mod 2) = 0 Then
Me![MemberID].BackColor = WHITE
Me![DateOfPlan].BackColor = WHITE
Me![Text74].BackColor = WHITE
Else
Me![MemberID].BackColor = GRAY
Me![DateOfPlan].BackColor = GRAY
Me![Text74].BackColor = GRAY
End If
End Sub
Sincerely,
Felix