I am using Access 2003. I have an application for a medical lab and all is working fine except when it comes to printing the test's results. The problem is with formatting and not with getting the data into it. There are two sets of groups of tests : Main tests (Mtest table) and Sub tests (Stest table). Part of the main tests are just individual tests, i.e. they have their own definitions and results, and the rest of the main tests are the head of a group of sub tests with their own similar types of definitions and results. (see pdf copy attached).
The problem is that the sub tests are printed without any empty space between records (under CBC in my example), while the main tests that have no sub tests come with one empty line ( under Chemistry). I want the main tests printed the same like the sub test without trailing empty line. I know that the empty lines represent the sub test that do not exist. I tried the code below to change the canshrink property of all the sub tests. The first part of the code to make the borders transparent is working, but the code is hanging on the canshrink part with a message that i can not assign a value to this object. Any suggestions? Help is appreciated
This is the code for the OnFormat property of the Detail section of the report:
"
If IsNull(STest) Then
Me.STest.BorderStyle = 0
Me.Result.BorderStyle = 0
Me.SUnits.BorderStyle = 0
Me.SRange.BorderStyle = 0
Me.STest.CanShrink = True
Me.Result.CanShrink = True
Me.SUnits.CanShrink = True
Me.SRange.CanShrink = True
Me.Section(acDetail).CanShrink = True
Else
End If
"
Thanks
The problem is that the sub tests are printed without any empty space between records (under CBC in my example), while the main tests that have no sub tests come with one empty line ( under Chemistry). I want the main tests printed the same like the sub test without trailing empty line. I know that the empty lines represent the sub test that do not exist. I tried the code below to change the canshrink property of all the sub tests. The first part of the code to make the borders transparent is working, but the code is hanging on the canshrink part with a message that i can not assign a value to this object. Any suggestions? Help is appreciated
This is the code for the OnFormat property of the Detail section of the report:
"
If IsNull(STest) Then
Me.STest.BorderStyle = 0
Me.Result.BorderStyle = 0
Me.SUnits.BorderStyle = 0
Me.SRange.BorderStyle = 0
Me.STest.CanShrink = True
Me.Result.CanShrink = True
Me.SUnits.CanShrink = True
Me.SRange.CanShrink = True
Me.Section(acDetail).CanShrink = True
Else
End If
"
Thanks