Results 1 to 12 of 12
  1. #1
    Perceptus's Avatar
    Perceptus is offline Expert
    Windows 7 64bit Access 2007
    Join Date
    Nov 2012
    Location
    Knoxville, Tennessee
    Posts
    659

    Layout for Controls extended.

    When I am designing a form there is a Layout for items, where Labels and Text boxes are Paired together. Can I access this layout collection in vba?



    I would like to know what the associated label for any related control is.

    Thank you for your time

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,963
    Bing: vba microsoft access textbox associated label

    http://stackoverflow.com/questions/1...ontrol-in-code
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Perceptus's Avatar
    Perceptus is offline Expert
    Windows 7 64bit Access 2007
    Join Date
    Nov 2012
    Location
    Knoxville, Tennessee
    Posts
    659
    What, a useful search using Bing? Hogwash!

    Thank you June, will check right now.

  4. #4
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,819
    Perceptus; you used the words "paired together". Perhaps you meant where the label is "attached" to the control, which is the correct term. Not that I'm nit picking on your terminology - I just want to point out that the solution only works for attached labels.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,963
    No, let's nit pick - the correct term is Associated.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  6. #6
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,819
    Well, as long as you're in the mood, I quoted MVP's first, but saved the best for last...

    Allen Browne: If there is an attached label, it will be the first member of the Controls collection of our control...

    Dirk Goldgar: Normally, if a control has an attached label, hiding the control will make the label invisibile...

    Microsoft Office:
    https://support.office.com/en-za/art...479f8e6e3c35#a
    compound control
    A control and an attached label, such as a text box with an attached label.


    Perhaps we can agree that the correct term is not "paired together".
    I also concede that "associated" is widely used and is acceptable.

  7. #7
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,963
    And if you accept that Access is the horse's mouth - create a label control in Detail section and it shows the warning "New Unassociated Label" and offers the option to "Associate Label with a Control".

    Paired, Attached, Associated - a rose is still a rose - the intended meaning with all three is that the two controls are joined at the hip.

    Let's say they are all correct
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  8. #8
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,819
    I have already agreed that associated is a common term which imparts the same meaning. Since we're nit-picking according to your post #5, what about option buttons that are associated with a frame? The option chosen from the option group is passed to the associate (frame) but if you move the frame, it does not move the option buttons - because they are not attached. Maybe that was meant to be the deciding factor. I would not even attempt to understand why the terminology is mixed within the bubble help of the program as it is not important to me. If they are all the same as you state, perhaps there was no need to call me out on it?

  9. #9
    Perceptus's Avatar
    Perceptus is offline Expert
    Windows 7 64bit Access 2007
    Join Date
    Nov 2012
    Location
    Knoxville, Tennessee
    Posts
    659
    June nailed it on the head with that link. Thanks again June.

  10. #10
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,963
    Just trying some friendly banter. Sorry if you took it as harsh.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  11. #11
    Perceptus's Avatar
    Perceptus is offline Expert
    Windows 7 64bit Access 2007
    Join Date
    Nov 2012
    Location
    Knoxville, Tennessee
    Posts
    659
    No harm no foul =). I'm really bad on my terminology.

  12. #12
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,963
    Perceptus, my last post was intended for Micron. Guess I should have indicated that.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. VBA IDE SDI Layout
    By Perceptus in forum Programming
    Replies: 2
    Last Post: 10-05-2015, 09:45 AM
  2. Replies: 1
    Last Post: 11-23-2012, 10:26 PM
  3. Layout Inquiry
    By allstar45 in forum Reports
    Replies: 2
    Last Post: 03-15-2012, 11:44 AM
  4. Calculate Multiple Fields for Extended Price
    By SRessler in forum Queries
    Replies: 3
    Last Post: 11-01-2010, 03:57 PM
  5. Replies: 0
    Last Post: 05-02-2010, 10:21 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums