Results 1 to 8 of 8

Thread: Foreground

  1. #1
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1

    Unanswered: Foreground

    How can you bring an object in foreground when it coincides on another object per Acce$$ VB

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    Eh... could you describe that a bit differently, I don't think I understand.. ?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1
    I have a textbox and I when I enter it, I put a list Box (coincide it exactly) on it to choose something from it and when you get out of this list box, it should be moved moved away and made hidden.
    I could coincide the ListBox on the TextBox but it comes underneeth. I tried with Setting the focus of the List box it functions.

    Is there another way to do that..

  4. #4
    Join Date
    Jun 2002
    Location
    Saudi Arabia / Philippines
    Posts
    126
    If this is a permanent change then in design view simply select the control and select Format/Bring to Front from the menu bar.

    If this is a instance by instance requirement then I know of no property that you can set. Messy but possible within VBA is to set Visible = false for every overlapping control. Your control will then be accessible even if it happens to be bottom of the pile.

    This is a technique I use quite a lot for controls that hold sub forms. Each control occupies exactly the same area of the main form. By setting the visible property of each control I can display the appropriate sub form for the data on the main form or according to a choice the user makes.
    Last edited by Rod; 07-20-04 at 10:21.
    Rod

    fe_rod@hotmail.com

  5. #5
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1
    Quote Originally Posted by Rod
    If this is a permanent change then in design view simply select the control and select Format/Bring to Front from the menu bar.

    If this is a instance by instance requirement then I know of no property that you can set. Messy but possible within VBA is to set Visible = false for every overlapping control. Your control will then be accessible even if it happens to be bottom of the pile.
    That is a good idea, I'll try it. Thanks man....

  6. #6
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    Beat me to it...

    I have a report where I simply toggle the visible property of the "forground" control based on a set of criteria... Will that work for you?

  7. #7
    Join Date
    Feb 2004
    Location
    Swindon, UK
    Posts
    86
    If i'm understanding correctly, could you not do the following

    Private Sub Text1_GotFocus

    List1.Visible=True
    List1.Setfocus

    End Sub

    &

    Private Sub List1_AfterUpdate

    Text1.Value=List1.Value 'If you require the value
    List1.Visible=False

    End Sub
    "Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done."

  8. #8
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1
    Thank you all for your valuable suggestions here is what I did, perhaps you can modify it.

    Thanks again
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •