E
evilcowstare via AccessMonster.com
Hi I have a record lock function in my form which works fine until I click
New Entry, which would normally start a new blank record. I keep getting the
error message...
Run-Time error '94':
Invalid use of Null
If I click Debug it highlights the line...
If recordlock Then
in yellow. This is the bit that is in the Form_Current area.
Does anyone know what I need to do to get rid of it?
The code looks like this but with 99% of all of the fields inserted into it
inc its autonumber.
Private Sub Form_Current()
operativebutton.Enabled = Not IsNull(operativecombo)
sitebutton.Enabled = Not IsNull(AddressCombo)
If recordlock Then
Me.jobnumber.Locked = True
Me.datereceived.Locked = True
Else
Me.jobnumber.Locked = False
Me.datereceived.Locked = False
End If
If Me.recordlock = True Then
Me.recordlabel.Visible = True
Else
Me.recordlabel.Visible = False
End If
End Sub
Can anybody help me sort this out? Its the last thing I have to fix and then
my whole db is complete ! )
Thank You to anybody that gives it a go!
New Entry, which would normally start a new blank record. I keep getting the
error message...
Run-Time error '94':
Invalid use of Null
If I click Debug it highlights the line...
If recordlock Then
in yellow. This is the bit that is in the Form_Current area.
Does anyone know what I need to do to get rid of it?
The code looks like this but with 99% of all of the fields inserted into it
inc its autonumber.
Private Sub Form_Current()
operativebutton.Enabled = Not IsNull(operativecombo)
sitebutton.Enabled = Not IsNull(AddressCombo)
If recordlock Then
Me.jobnumber.Locked = True
Me.datereceived.Locked = True
Else
Me.jobnumber.Locked = False
Me.datereceived.Locked = False
End If
If Me.recordlock = True Then
Me.recordlabel.Visible = True
Else
Me.recordlabel.Visible = False
End If
End Sub
Can anybody help me sort this out? Its the last thing I have to fix and then
my whole db is complete ! )
Thank You to anybody that gives it a go!