Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Object property values from within object?

Status
Not open for further replies.

drwunz

Programmer
Dec 17, 2001
34
US
Each component placed on a VB form gets a unique name and values for Top, Left, Width, Height, etc. How do I access those from within the activeX component? I need this (particularly the Name) to pass as a parameter to a database function.
 
just a shot in the dark but maybe you could use something like...
don't have time to make an ActiveX control to check if this would work but if you could get the Parent (container) of your control then you could loop through the controls within that container as shown below

Code:
  Dim oCtrl As Control
  
  For Each oCtrl In YourControl.Parent.Controls
    If oCtrl Is YourControl Then
      Debug.Print "found myself"
    Else
      Debug.Print oCtrl.Name
    End If
  Next oCtrl
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top