Changing 1 text box after updating another...

  • Thread starter Thread starter Jinsem
  • Start date Start date
J

Jinsem

Hi all,

I'm relatively new to the Access world, and had a question
I just can't seem to find an answer too...

I'm trying to make a "pseudo" Inv Control DB. What I need
is for the worker to be able to input his part number and
for the next text box to show what part number description
it is. This will be done on a form of course. I've tried
to many things, and even the MS Access help function.
Just can't seem to find it.

Any help would be great. Also, if any wouldn't mind...
Is there a way to set a group password on start up ? That
way I can keep access to all the DB, limit the supervisors
a bit, and make it so that the workers can only access 1
form.

My email is LomaBuyer{at}hotmail.com

I'll try to find the replies here, hopefully someone
replies ;)

Jinsem
 
There are a coupla ways u can do this. If your part numbers are relatively
few, then instead of a text box for entry, have the user select the
partnumber from the list... The Form would have as a record source the
table. The list box would have as a record source a SQL statement, like
this:
SELECT [tblParts].TableID, [tblParts].[PartNo]
FROM [tblParts];

In the after update event of the listbox, put:

Dim rs As Object
Set rs = Me.RecordsetClone
rs.FindFirst "[TableID] = " & Str(Nz(Me![ListboxName], 0))
If Not rs.EOF Then Me.Bookmark = rs.Bookmark

When user selects the partnumber from the listbox, the form fills in with
info for that partnumber...

If your parts list is big, (I have one that is over 3000) then put a text
box above the listbox, and use that as a search box, which will populate the
listbox with similar numbers, which the user can then click on (as above)
and fill in the info.
The SQL statement for the Listbox will have to be altered a bit, using the
word "Like":
SELECT [tblParts].TableID, [tblParts].[Serial No]
FROM [tblParts]
WHERE ((([tblParts].[Serial No]) Like [txtFind]));

The textbox (txtFind) would need this in the afterupdate event:
DoCmd.Requery "ListBoxName"
The user can be instructed to use the "*" in the text box if they don't have
the full part number. As in Part Number XYZ123, user could type XYZ1* and
listbox would populate all parts with those beginning characters.

HTH
Damon
 
Thanks for helping out. I'm a bit unsure of a few things
so I emailed you directly. I'f you don't get it, or it's
a spam drop just let me know. This is assuming you still
wanna walk me through just a tad more questions. Sucks to
start out and know very little...

Thanks,
Jinsem
-----Original Message-----
There are a coupla ways u can do this. If your part numbers are relatively
few, then instead of a text box for entry, have the user select the
partnumber from the list... The Form would have as a record source the
table. The list box would have as a record source a SQL statement, like
this:
SELECT [tblParts].TableID, [tblParts].[PartNo]
FROM [tblParts];

In the after update event of the listbox, put:

Dim rs As Object
Set rs = Me.RecordsetClone
rs.FindFirst "[TableID] = " & Str(Nz(Me! [ListboxName], 0))
If Not rs.EOF Then Me.Bookmark = rs.Bookmark

When user selects the partnumber from the listbox, the form fills in with
info for that partnumber...

If your parts list is big, (I have one that is over 3000) then put a text
box above the listbox, and use that as a search box, which will populate the
listbox with similar numbers, which the user can then click on (as above)
and fill in the info.
The SQL statement for the Listbox will have to be altered a bit, using the
word "Like":
SELECT [tblParts].TableID, [tblParts].[Serial No]
FROM [tblParts]
WHERE ((([tblParts].[Serial No]) Like [txtFind]));

The textbox (txtFind) would need this in the afterupdate event:
DoCmd.Requery "ListBoxName"
The user can be instructed to use the "*" in the text box if they don't have
the full part number. As in Part Number XYZ123, user could type XYZ1* and
listbox would populate all parts with those beginning characters.

HTH
Damon


Hi all,

I'm relatively new to the Access world, and had a question
I just can't seem to find an answer too...

I'm trying to make a "pseudo" Inv Control DB. What I need
is for the worker to be able to input his part number and
for the next text box to show what part number description
it is. This will be done on a form of course. I've tried
to many things, and even the MS Access help function.
Just can't seem to find it.

Any help would be great. Also, if any wouldn't mind...
Is there a way to set a group password on start up ? That
way I can keep access to all the DB, limit the supervisors
a bit, and make it so that the workers can only access 1
form.

My email is LomaBuyer{at}hotmail.com

I'll try to find the replies here, hopefully someone
replies ;)

Jinsem


.
 
Back
Top