G
Guest
Hi,
I am adding a record in a table from a form. The field is called LineItemID
while the form field is called LineNumber. I need to prevent duplicate from
going in the field. I am trying to calculate the record number corresponding
to the new input. If it is > 1 then it should prevent entry by giving an
error message.
However, in the code, when I am writing the following, I am getting an error
message. I would appreciate any help. Thanks
CODE:
select LineItemId from tblLineItems where LineItemID =
Forms!frmEditLineItems!LineNumber
I am adding a record in a table from a form. The field is called LineItemID
while the form field is called LineNumber. I need to prevent duplicate from
going in the field. I am trying to calculate the record number corresponding
to the new input. If it is > 1 then it should prevent entry by giving an
error message.
However, in the code, when I am writing the following, I am getting an error
message. I would appreciate any help. Thanks
CODE:
select LineItemId from tblLineItems where LineItemID =
Forms!frmEditLineItems!LineNumber