Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / May 2007

Tip: Looking for answers? Try searching our database.

Filter based on unbound text box with default value

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
jgrappy@gmail.com - 22 May 2007 14:24 GMT
I'm using the fOSUserName module to give an unbound text box a default
value of the user's network User Name.  I'm trying to filter a form
using this text box value (Text24), as this value corresponds to a
bound field (Anumber) in the form's driving query.  I cannot seem to
get it to all come together.  I used the below code, but, when run, it
throws up a dialog box which has the unbound text box's value in it.
If I enter that value in the dialog box, the form filters as I want it
too. However, I want this to happen automatically.  Hope that makes
sense....thanks for any help.

Dim strFilter As String
   strFilter = "[Anumber] = " & (Me.Text24)
   Me.Filter = strFilter
   Me.FilterOn = True
End Sub
Maurice - 22 May 2007 19:00 GMT
Have you tried it without the ( )

strFilter = "[Anumber] = " & Me.Text24

Signature

Maurice Ausum

> I'm using the fOSUserName module to give an unbound text box a default
> value of the user's network User Name.  I'm trying to filter a form
[quoted text clipped - 11 lines]
>     Me.FilterOn = True
> End Sub
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.