Only show that user info in a form

D

dcash45

I am now trying to open up a form from a switchboard that only shows that
person data based on their userID.

Here’s the thing, the user logs in which then brings them to the switchboard
and in one of the buttons on the switchboard is ManageOwnInfo (which open
that form). I want the form to only show the user information that is log in.

Another this is that Im working on 2 different database where one database
all its form are unbound and the other database is not unbound.

There is the code I’m working with to help me call the user own information….

DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= UserID " &
Forms!frmManagerMain.OpenArgs

This is the code that calls the ManageOwnInfo form from the
switchboard….this code Im using with the database that is still bound

How anyone from help with this…

Thank you,
 
R

Rob Parker

If UserID is numeric, try:
DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= " &
Forms!frmManagerMain.OpenArgs

If UserID is a string, you'll need:
DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= '" &
Forms!frmManagerMain.OpenArgs & "'"

HTH,

Rob
 
D

dcash45

Wow......I guess I was over looking things but thanks again.

Rob Parker said:
If UserID is numeric, try:
DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= " &
Forms!frmManagerMain.OpenArgs

If UserID is a string, you'll need:
DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= '" &
Forms!frmManagerMain.OpenArgs & "'"

HTH,

Rob


dcash45 said:
I am now trying to open up a form from a switchboard that only shows that
person data based on their userID.

Here's the thing, the user logs in which then brings them to the
switchboard
and in one of the buttons on the switchboard is ManageOwnInfo (which open
that form). I want the form to only show the user information that is log
in.

Another this is that Im working on 2 different database where one database
all its form are unbound and the other database is not unbound.

There is the code I'm working with to help me call the user own
information..

DoCmd.OpenForm "frmManageUsers", acNormal, , "[UserID]= UserID " &
Forms!frmManagerMain.OpenArgs

This is the code that calls the ManageOwnInfo form from the
switchboard..this code Im using with the database that is still bound

How anyone from help with this.

Thank you,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top