blanco, con 2 labels, le pongo al label 1, la ip, y al label 2 el username. Vale hasta aquí funciona,
pero que pasa, que hago llamada a la notificación que es un módulo, y al hacer llamada a esta
el form5, pierde el contenido, y hace la notificación pero en blanco, si no hago la notificación
el form5 se cambia perfectamente, y si la hago en la notificación sale en blanco, he intentado
hacer un SLEEP después de cambiar los datos del form5, pero no funciona.. y ni idea del porqué.
Pongo el code de la notificación:
Código: Seleccionar todo
'Modulo ModNotifyMsn parte del troyano mFucker
' Liberado por: Xa0s
' En: professional-hacker.org
' Y en: indetectables.net
'===========================================
'Modificado por Satyr90 ==
'Para Poder usar con cualquier aplicacion ==
'===========================================
Declare Function SetTimer Lib "user32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long
Declare Function KillTimer Lib "user32" (ByVal hwnd As Long, ByVal nIDEvent As Long) As Long
Declare Function SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal X As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Declare Function GetWindowRect Lib "user32" (ByVal hwnd As Long, lpRect As RECT) As Long
Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long
Declare Function waveOutGetNumDevs Lib "winmm.dll" () As Long
Const SND_ASYNC = &H1
Const SND_NODEFAULT = &H2
Const SWP_NOACTIVATE = &H10
Const SWP_SHOWWINDOW = &H40
Const HWND_TOPMOST = -1
Const SWP_NOMOVE = &H2
Const SWP_NOSIZE = &H1
Dim TimerFrm As Form
Dim TimerID As Long
Dim Posicion As Integer
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Function playSound(soundpath As String)
Dim ret As Long
ret& = waveOutGetNumDevs
If ret& > 0 Then
sndPlaySound soundpath, SND_ASYNC Or SND_NODEFAULT
End If
End Function
Function nMsn(Frm As Form, Optional Tiempo As Long = 3)
Dim buffRECT As RECT
Dim Tamaño As Integer
Dim hgt As Integer
Dim hwnd As Long
Dim res As Long
Unload Frm
hwnd = FindWindow("Shell_TrayWnd", "")
res = GetWindowRect(hwnd, buffRECT)
If res > 0 Then
Tamaño = CStr(buffRECT.Bottom - buffRECT.Top) * 15
hgt = Frm.Height
Frm.Height = 1
If buffRECT.Left <= 0 And buffRECT.Top > 0 Then
Posicion = 1 'abajo
End If
If buffRECT.Left > 0 And buffRECT.Top <= 0 Then
Posicion = 2 'derecha
Tamaño = (buffRECT.Right - buffRECT.Left) * 15
End If
If buffRECT.Left <= 0 And buffRECT.Top <= 0 And buffRECT.Right < 600 Then
Posicion = 3 'izquierda
Tamaño = buffRECT.Right * 15
End If
If buffRECT.Left <= 0 And buffRECT.Top <= 0 And buffRECT.Right > 600 Then
Posicion = 4 'arriba
End If
End If
Select Case Posicion
Case 1: Frm.Move Screen.Width - Frm.Width, Screen.Height - Frm.Height - Tamaño
Case 2: Frm.Move Screen.Width - Frm.Width - Tamaño, Screen.Height - Frm.Height
Case 3: Frm.Move Tamaño, Screen.Height - Frm.Height
Case 4: Frm.Move Screen.Width - Frm.Width, Tamaño
End Select
res = SetWindowPos(Frm.hwnd, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE Or SWP_NOSIZE Or SWP_NOACTIVATE Or SWP_SHOWWINDOW)
Do While Frm.Height <= hgt
DoEvents
Frm.Height = Frm.Height + 1
If Not Posicion = 4 Then
Frm.Top = Frm.Top - 1
End If
Loop
Set TimerFrm = Frm
TimerID = SetTimer(Frm.hwnd, 0, Tiempo * 1000, AddressOf CierraMsn)
End Function
Public Sub CierraMsn()
KillTimer TimerFrm.hwnd, TimerID
Do While TimerFrm.Height >= 520
DoEvents
TimerFrm.Height = TimerFrm.Height - 1
If Not Posicion = 4 Then
TimerFrm.Top = TimerFrm.Top + 1
End If
Loop
Unload TimerFrm
End Sub