Hey guys,

I just cannot get this code to work. I am trying to make another programs window fullscreen so i have been trying to double click its window (which makes it fullscreen normally)

Here is what I am using. I wonder is there a simpler way to tell the program, run in fullscreen mode. If there was a better way than below I would love to see it.

Thx
KT

VB Code:
  1. Private Sub Command314_Click()
  2. Dim abc As Long
  3.  
  4. param = MakeLong(200, 200)
  5.  
  6. Call SendMessage(whwnd, WM_LBUTTONDBLCLK, 0, param)
  7.  
  8. End Sub
  9.  
  10. Public Function PadString(ByVal sIn As String, ByVal Length As Long, ByVal PadChar As String)
  11.  
  12. If Len(sIn) < Length Then
  13.    PadString = String$(Length - Len(sIn), PadChar) & sIn
  14. Else
  15.     PadString = Left$(sIn, Length)
  16. End If
  17.  
  18. End Function
  19.  
  20. Public Function MakeLong(ByVal LoWord As Integer, ByVal HiWord As Integer) As Long
  21.  
  22. MakeLong = Val("&H" & PadString(Hex(HiWord), 4, "0") & PadString(Hex(LoWord), 4, "0"))
  23.  
  24. End Function