Post: [Vb.Net] Remove Window Titlebar
05-09-2011, 11:36 PM #1
(adsbygoogle = window.adsbygoogle || []).push({});
Originally posted by kingdeath360 View Post
Using this function you can remove a window's titlebar, you first need to find the HWND of the window( using FindWindow or FindWindowEx API), then you just call this function and it will remove the titlebar.

    
Public Shared Function RemoveTitleBar(ByVal hwnd As IntPtr) As Boolean
Dim style As Long = GetWindowLong(hwnd, (-16))
style += &H800000 Or &HC00000
Return SetWindowLong(hwnd, (-16), style)
End Function

'APIS
<Awesome facellImport("user32.dll")> _
Public Shared Function SetWindowLong(ByVal hWnd As IntPtr, ByVal nIndex As Integer, ByVal dwNewLong As IntPtr) As Integer
End Function
<Awesome facellImport("user32.dll", SetLastError:=True)> _
Public Shared Function GetWindowLong(ByVal hWnd As IntPtr, ByVal nIndex As Integer) As Integer
End Function

its a c&p///////////////////////////////

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo