I had previously posted this in the forms forum but to no avail.
I have the following code:
Private Sub ctrtxtChequeNo_GotFocus()
Dim dblCount As Double
Dim dblHeight As Integer
dblCount = DCount("[txtChequeNo]", "DuplicateChqNumUnmatched", "[txtChequeNo] = ctrtxtChequeNo"
dblHeight = dblCount * 0.8
'Me.Text11 = dblHeight
Forms![DuplicateCheqBal]![DuplicateChqNumUnmatched].InsideHeight = dblHeight
End Sub
What I am trying to do is change the height of the entire subform based on the number of rows to be returned.
I have been looking in the Access help but without too much success, it appears you can only manipulate the height of sections of a form but I thought maybe the forms height is the same as the insideheight.
Anyway my code attempt does not work.
Any help appreciated.
N.b. Text11 is just totest the value is being returned.
I have the following code:
Private Sub ctrtxtChequeNo_GotFocus()
Dim dblCount As Double
Dim dblHeight As Integer
dblCount = DCount("[txtChequeNo]", "DuplicateChqNumUnmatched", "[txtChequeNo] = ctrtxtChequeNo"
dblHeight = dblCount * 0.8
'Me.Text11 = dblHeight
Forms![DuplicateCheqBal]![DuplicateChqNumUnmatched].InsideHeight = dblHeight
End Sub
What I am trying to do is change the height of the entire subform based on the number of rows to be returned.
I have been looking in the Access help but without too much success, it appears you can only manipulate the height of sections of a form but I thought maybe the forms height is the same as the insideheight.
Anyway my code attempt does not work.
Any help appreciated.
N.b. Text11 is just totest the value is being returned.