i have a slight problem with my customers form.
if customer details have been entered, and they need to be changed or 're-chosen' for some reason, i'd like the customers form to open at the last entered info. otherwise i'd like it to open at a blank page. is this possible? right now it's opening as a blank page. obviously i'd need some kind of condition but im unsure.
so far i have...
Private Sub Form_Load()
If Forms![SALES].[customer_ID] = "0" Then
DoCmd.GoToRecord , , acNewRec
Else
DoCmd.GoToRecord , , acGoTo, Me.customer_ID = pubcusID 'Buggy
End If
im not sure what that buggy line should read but basically i need to open the record with customer_ID equal to the public variable pubcusID.
as always, your help much appreciated.
p.s. now that i look at it, should the condition be changed to...
If IsNull ([forms![sales].[customer_ID] then
(im not even sure if this is valid syntax for that function.
if customer details have been entered, and they need to be changed or 're-chosen' for some reason, i'd like the customers form to open at the last entered info. otherwise i'd like it to open at a blank page. is this possible? right now it's opening as a blank page. obviously i'd need some kind of condition but im unsure.
so far i have...
Private Sub Form_Load()
If Forms![SALES].[customer_ID] = "0" Then
DoCmd.GoToRecord , , acNewRec
Else
DoCmd.GoToRecord , , acGoTo, Me.customer_ID = pubcusID 'Buggy
End If
im not sure what that buggy line should read but basically i need to open the record with customer_ID equal to the public variable pubcusID.
as always, your help much appreciated.
p.s. now that i look at it, should the condition be changed to...
If IsNull ([forms![sales].[customer_ID] then
(im not even sure if this is valid syntax for that function.