elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Los 10 CVE más críticos (peligrosos) de 2020


  Mostrar Mensajes
Páginas: 1 2 3 4 5 6 [7] 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 ... 46
61  Programación / Programación Visual Basic / Re: Como dar un mensaje falso cada vez que se hace click con el mause en: 27 Septiembre 2010, 19:17 pm
Como dar un mensaje falso cada vez que se hace click con el mause en cual quier parte de la ventana de windows. con un mesaje falso de msgbox
Gracias Saludo

La ventana de windows... te referís solo cuando se hace click en el  escritorio de windows ?




62  Programación / Programación Visual Basic / Re: [Ayuda] Form en: 26 Septiembre 2010, 16:24 pm
Ahí va con constantes, Psyke.

Código:

Option Explicit

Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long

Private Const GWL_STYLE = (-16)
Private Const WS_CAPTION = &HC00000
Private Const WS_SIZEBOX = &H40000

Private 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

Private Const SWP_FRAMECHANGED = &H20
Private Const SWP_NOMOVE = &H2
Private Const SWP_NOZORDER = &H4
Private Const SWP_NOSIZE = &H1

Private Const SWP_REFRESH = SWP_NOSIZE Or SWP_NOMOVE Or SWP_NOZORDER Or SWP_FRAMECHANGED

Private Sub Form_Load()
  Command1.Caption = "FIXED"
  Command2.Caption = "SIZEABLE"
End Sub

Private Sub Command1_Click()
  Dim lngstylo As Long
  lngstylo = GetWindowLong(Me.hwnd, GWL_STYLE) And Not WS_SIZEBOX
  Call SetWindowLong(Me.hwnd, GWL_STYLE, lngstylo)
  Call SetWindowPos(Me.hwnd, &H0, &H0, &H0, &H0, &H0, SWP_REFRESH)
End Sub

Private Sub Command2_Click()
  Dim lngstylo As Long
  lngstylo = GetWindowLong(Me.hwnd, GWL_STYLE) Or WS_SIZEBOX
  Call SetWindowLong(Me.hwnd, GWL_STYLE, lngstylo)
  Call SetWindowPos(Me.hwnd, &H0, &H0, &H0, &H0, &H0, SWP_REFRESH)
End Sub



63  Programación / Programación Visual Basic / Re: [Ayuda] Form en: 26 Septiembre 2010, 13:38 pm
En Diseño es como te dice raul y si necesitas cambiar en ejecución se puede usar SetWindowLong (sirve tambien para formularios sin borde)

Código:
Option Explicit
Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Private 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

Private Sub Form_Load()
  Command1.Caption = "FIXED"
  Command2.Caption = "SIZEABLE"
End Sub

Private Sub Command1_Click()
  Call SetWindowLong(Me.hwnd, &HFFF0, GetWindowLong(Me.hwnd, &HFFF0) And Not &H40000)
  Call SetWindowPos(Me.hwnd, &H0, &H0, &H0, &H0, &H0, &H20 Or &H2 Or &H4 Or &H1)
End Sub

Private Sub Command2_Click()
  Call SetWindowLong(Me.hwnd, &HFFF0, GetWindowLong(Me.hwnd, &HFFF0) Or &H40000)
  Call SetWindowPos(Me.hwnd, &H0, &H0, &H0, &H0, &H0, &H20 Or &H2 Or &H4 Or &H1)
End Sub




64  Programación / Programación Visual Basic / Re: [SOLUCIONADO] Puntas Redondeadas en un form en: 22 Septiembre 2010, 12:41 pm
Particularmente uso esto en para formularios simples, sin Bordes o con borde transparente ,  vale la aclaracion de  BlackZeroX


http://www.megaupload.com/?d=819VEP1W

















65  Programación / Programación Visual Basic / Re: Ayuda Hook y ApiHooking en: 19 Septiembre 2010, 05:55 am

yo lo que necesito es hecer un hook a una aplicacion (saber cuando se ejecuta, que parametros le pasan, etc).


para saber si una aplicacion externa está corriendo o no lo podes saber por intermedio del Hwnd de la su ventana o enumerando los procesos (EnumProcesses) , fijate en este link se habla de eso.

http://www.vbforums.com/showthread.php?p=3231419





yo lo que necesito es hecer un hook a una aplicacion (saber cuando se ejecuta, que parametros le pasan, etc).


No sé si te puedo ayudar en el tema de saber que parametros se le pasan, a que parametros te referis exactamente ?












66  Programación / Programación Visual Basic / Re: [Aporte] EnvironEx en: 19 Septiembre 2010, 04:29 am
La constante pàra la carpeta de sistema seria &H25, lee la lista de Raul338 o el link de Xkis o todo el hilo   ;)








67  Programación / Programación Visual Basic / Re: [Aporte] EnvironEx en: 19 Septiembre 2010, 04:17 am
Código:


Option Explicit
Private Declare Function SHGetFolderPath Lib "shfolder" Alias "SHGetFolderPathA" (ByVal hwndOwner As Long, ByVal nFolder As Long, ByVal hToken As Long, ByVal dwFlags As Long, ByVal pszPath As String) As Long
Private Const MAX_PATH = 260

Private Sub Form_Load()
   
   Dim sRet As String * MAX_PATH
   Call SHGetFolderPath(0, &H25, 0, 0, sRet)
   MsgBox Split(sRet, Chr$(0))(0)

End Sub




68  Programación / Programación Visual Basic / Re: [Aporte] EnvironEx en: 18 Septiembre 2010, 23:47 pm
Aclarado, entonces MAX_PATH.





69  Programación / Programación Visual Basic / Re: [Aporte] EnvironEx en: 18 Septiembre 2010, 23:33 pm
Yo la tenía parecida (siempre me olvido de los  &H0 en lugar del 0, luego los cambio)

Una duda desde siempre, estária  bien sRet o igual debe usarse  MAX_PATH ?

Código:

Public Function ShEnviron(nCode As CSIDL) As String
   Dim sRet As String * 260
   Call SHGetFolderPath(0, nCode, 0, 0, sRet)
   ShEnviron = Split(sRet, Chr$(0))(0)
End Function








70  Programación / Programación Visual Basic / Re: [Aporte] EnvironEx en: 18 Septiembre 2010, 22:58 pm
Gracias BlackZeroX , eso queria saber


Si no utiliza el indicador CSIDL_FLAG_CREATE:
si la carpeta no existe, la función de SHGetFolder devuelve S_FALSE y nada se coloca en el búfer de cadena.



Páginas: 1 2 3 4 5 6 [7] 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 ... 46
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines