DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/)
-   MS Access and FileMaker Pro (http://www.daniweb.com/forums/forum128.html)
-   -   FindRecord help (http://www.daniweb.com/forums/thread108875.html)

Jamesharks Feb 12th, 2008 7:28 pm
FindRecord help
 
I have 2 forms; one called frmLogin and another called user_info.

On frmLogin I have a text box called USERNAME and a command button. When you click the command button the following code is run:

This Code Works (Or atleast It should)
Private Sub Command29_Click()
    Dim strUSERNAME As String
    Dim strProcess As String
   
    strUSERNAME = Me.USERNAME
    strProcess = LOGIN(strUSERNAME)
End Sub

The code takes what has been typed into to the textbox USERNAME and passess it onto the module LOGIN which has the following code:

This Code Does NotWork
Public Function LOGIN(strLOGIN As String)
   
    DoCmd.OpenForm "user_info"
    DoCmd.FindRecord strLOGIN
   
End Function

I know this code does not work but I don't know what to do to get it working. I am trying to get it to open the form user_info and display records relating to what has been typed into the textbox USERNAME.

If you have any suggestions please reply.

Thankyou


All times are GMT -4. The time now is 11:14 pm.

Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC