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 / August 2006

Tip: Looking for answers? Try searching our database.

View active control property with unbound text box

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
ipresler@gmail.com - 06 Aug 2006 07:57 GMT
Hi,
I am looking how to view tag property of active control with help of
unbound text box.
My idea was to bound Control Source of text box to
Form.ActiveControl.Tag or something like this.
But doesn't work. Any suggestions?

Thanks.
strive4peace - 06 Aug 2006 08:28 GMT
How about something like this:

make an unbound control on your form:
Name --> TagContents

put this code behind your form:
'~~~~~~~~~~~~~~
Private Function ShowMyTag()
   ShowTag Me.TagContents
End Function
'~~~~~~~~~~~~~~

put this function in a general module:
'~~~~~~~~~~~~~~
Sub ShowTag(pCtrl As Control)
   Dim mTag As String
   mTag = Nz(Screen.ActiveControl.Tag, "")
   pCtrl = mTag
End Sub
'~~~~~~~~~~~~~~

on the double-click event of each control that you want to show the tag
for -->
=ShowMyTag()

I am sure there are probably ways to streamline this further, this was
just a quick idea...ideally, you could trap an event when the
ActiveControl changes, but I do not know how to do this or if it is even
possible

Function

Warm Regards,
Crystal
 *
     (:  have an awesome day  :)
  *
MVP Access
Remote programming and Training
strive4peace2006 at yahoo.com
  *

> Hi,
> I am looking how to view tag property of active control with help of
[quoted text clipped - 4 lines]
>
> Thanks.
 
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.