ByronJohnson
MIS
Hey Everyone,
I am getting back into the programming game and am stuck.
I have a form and want to into a value into a text box which goes and looks for this in a table, if found then it will display the values in the appropriate text boxes on form. If not found allows the user to enter in the appropriate data.
Here is part my code.
If DLookup("[ServiceTag]", "Computers", "[servicetag] = Forms![Setup_Form]![ServiceTag]" Then
'Not too sure how I write code to tell the program to link the field in the table to the text box on the form.
Computers.Make = Forms!Setup_Form!Make
Computers.Model = Forms!Setup_Form!Model
Computers.Partitions = Forms!Setup_Form!Partitions
Computers.CPU = Forms!Setup_Form!CPU
Computers.RAM = Forms!Setup_Form!RAM
Computers.HDSize = Forms!Setup_Form!HDSize
Computers.ServiceCode = Forms!Setup_Form!ServiceCode
Thank you for any help that you people can offer,
Byron
I am getting back into the programming game and am stuck.
I have a form and want to into a value into a text box which goes and looks for this in a table, if found then it will display the values in the appropriate text boxes on form. If not found allows the user to enter in the appropriate data.
Here is part my code.
If DLookup("[ServiceTag]", "Computers", "[servicetag] = Forms![Setup_Form]![ServiceTag]" Then
'Not too sure how I write code to tell the program to link the field in the table to the text box on the form.
Computers.Make = Forms!Setup_Form!Make
Computers.Model = Forms!Setup_Form!Model
Computers.Partitions = Forms!Setup_Form!Partitions
Computers.CPU = Forms!Setup_Form!CPU
Computers.RAM = Forms!Setup_Form!RAM
Computers.HDSize = Forms!Setup_Form!HDSize
Computers.ServiceCode = Forms!Setup_Form!ServiceCode
Thank you for any help that you people can offer,
Byron