Results 1 to 37 of 37

Thread: [RESOLVED] How Can I show Form2 Without Show all Project Forms !?

Threaded View

  1. #36
    VB For Fun Edgemeal's Avatar
    Join Date
    Sep 2006
    Location
    WindowFromPoint
    Posts
    4,255

    Re: [RESOLVED] How Can I show Form2 Without Show all Project Forms !?

    Quote Originally Posted by Noob13 View Post
    what if ""ShowInTaskbar = False""
    How can I keep it False ?
    When Click on Form it`s back True !

    SetWindowLong Form1.hwnd, GWL_HWNDPARENT, 0&

    Thankx
    Did you try using that 2nd part of that code instead?...
    SetWindowLong f.hwnd, GWL_HWNDPARENT, CreateWindowEx(.....

    Note, one was for compiled exe and other for testing in IDE.

    EDIT, just in case you need the API declares..

    Code:
    Private Const GWL_HWNDPARENT As Long = (-8)
    Private Const GWL_HINSTANCE As Long = (-6)
    Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
    Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
    Private Declare Function CreateWindowEx Lib "user32" Alias "CreateWindowExA" (ByVal dwExStyle As Long, ByVal lpClassName As String, ByVal lpWindowName As String, ByVal dwStyle As Long, ByVal X As Long, ByVal Y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hWndParent As Long, ByVal hMenu As Long, ByVal hInstance As Long, lpParam As Any) As Long
    
    Private Sub Example_Usage(f As Form)
        f.Show
        SetWindowLong f.hwnd, GWL_HWNDPARENT, CreateWindowEx(&H80, "ThunderRT6Main", vbNullString, &H94000000, 0&, 0&, 0&, 0&, 0&, 0&, GetWindowLong(f.hwnd, GWL_HINSTANCE), 0&)
    End Sub
    Last edited by Edgemeal; Apr 7th, 2014 at 06:53 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
  •  



Click Here to Expand Forum to Full Width