Originally posted by MarkT
Someone posted this here a while back and it seems to work pretty well.
VB Code:
  1. Option Explicit
  2.  
  3. 'API Calls Used To Remove The Title Bar From Window (Make A Sizeable Borderless Form)
  4. Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" _
  5.                             (ByVal hwnd As Long, ByVal nIndex As Long, _
  6.                             ByVal dwNewLong As Long) As Long
  7. Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" _
  8.                             (ByVal hwnd As Long, ByVal nIndex As Long) As Long
  9.                            
  10. Private Const GWL_STYLE = (-16)
  11. Private Const WS_DLGFRAME = &H400000
  12.  
  13. 'API Calls Used To Move A Form With The Mouse
  14. Private Declare Function ReleaseCapture Lib "user32" () As Long
  15. Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" _
  16.                             (ByVal hwnd As Long, ByVal wMsg As Long, _
  17.                             ByVal wParam As Long, lParam As Any) As Long
  18.  
  19. Private Const HTCAPTION = 2
  20. Private Const WM_NCLBUTTONDOWN = &HA1
  21.  
  22. Private Sub Command1_Click()
  23.     Unload Me
  24. End Sub
  25.  
  26. Private Sub Form_Load()
  27.     'ERASE the Title Bar
  28.     SetWindowLong Me.hwnd, GWL_STYLE, GetWindowLong(Me.hwnd, GWL_STYLE) + WS_DLGFRAME
  29. End Sub
  30.  
  31. Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  32.     'Move the form with the Left Mouse Button
  33.     If Button = vbLeftButton Then
  34.         Me.MousePointer = vbSizeAll
  35.         Call ReleaseCapture
  36.         Call SendMessage(hwnd, WM_NCLBUTTONDOWN, HTCAPTION, 0&)
  37.         Me.MousePointer = vbArrow
  38.     End If
  39. End Sub

I've already tested this code in my application, it did not work very good.
I think the problem might be that the external application is not a VB compiled EXE.

she