Jump to content
Nytro

Hide Focus Window

Recommended Posts

Posted

Inca o porcarie pe care am descoperito in timp ce ma jcam cu API-urile :)

Vom avea nevoie de 2 APIuri :

Private Declare Function ShowWindow Lib "user32" Alias "ShowWindow" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long

Private Declare Function GetForegroundWindow Lib "user32" Alias "GetForegroundWindow" () As Long

Si de un Timer la Interval 1 .

Private Sub Timer1_Timer()

Dim x

x = GetForegroundWindow() ' x va fi handlerul ferestrei care detine focusul

ShowWindow x, 0 ' Folosim APIul ShowWindow pentru a ascunde fereastra

End Sub

Rulati si dati click pe o fereastra :)

Posted

Ms . Se pot face mai multe pornind de la asta , de exemplu in loc de hide , ar merge close ... poate in loc de foreground windows un findwindow ... Trebuie decat sa ai imaginatie :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...