Results 1 to 5 of 5

Thread: Activating Child Windows Only

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2000
    Posts
    230

    Question

    I want to activate only a child window from a parent without the parent being "shown". Is it programmatically possible.

    Shawn Hull
    VB6, SP3 (Professional Edition)

  2. #2
    Guest
    Make the parent Form transparent, and you can make all your child windows visible.

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Sep 2000
    Posts
    230

    Question

    I guess the obvious question is how to make the parent window transparent. I am guessing there is an api call for this, maybe ShowWindow? If you know tha api to do this please let me know.

    Shawn Hull
    VB6, SP3 (Professional Edition)

  4. #4
    Guest
    Add the following to a form with a Timer.
    Code:
    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
    Const GWL_EXSTYLE = (-20)
    Const WS_EX_TRANSPARENT = &H20&
    
    Private Sub Timer1_Timer()
        SetWindowLong hwnd, GWL_EXSTYLE, WS_EX_TRANSPARENT
    End Sub

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Sep 2000
    Posts
    230

    Wink

    Thanks Megatron, I will play around with what you have given me.

    So many useful API calls, so little knowledge of them.

    Shawn Hull
    VB6, SP3 (Professional Edition)

Posting Permissions

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



Click Here to Expand Forum to Full Width