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

 

 


Tema destacado: (TUTORIAL) Aprende a emular Sentinel Dongle By Yapis


  Mostrar Mensajes
Páginas: 1 2 3 4 5 6 7 8 9 10 11 12 13 [14] 15
131  Programación / Programación Visual Basic / Re: Minizar form y ponerlo al lado del reloj en: 2 Septiembre 2010, 18:28 pm
con mi code cada uno lo modifica a gusto! con lo que dices ni idea !nunca intente migrarlo para vb.net  :-X
132  Programación / Programación Visual Basic / Re: tooltiptext con formulario ! "hlp" en: 2 Septiembre 2010, 04:23 am
dale master voy a buscar como dices y veo! sino charlamos luego !
133  Programación / Programación Visual Basic / Re: tooltiptext con formulario ! "hlp" en: 1 Septiembre 2010, 21:42 pm
no lo habia pensando loco de esa manera, espero otras ideas mientras pruebo tu manera!! gracias
134  Programación / Programación Visual Basic / tooltiptext con formulario ! "hlp" en: 1 Septiembre 2010, 19:35 pm
hola a todos ! tengo una duda pero nose por donde empezar y es lo siguiente es el hacer un tooltiptext con un formulario y/o poder usarlo a la ves como un formulario comun mientras el puntero este posicionado desde donde se lo llama o sobre si mismo, espero averme explicado bn.gracias
135  Programación / Programación Visual Basic / Re: Minizar form y ponerlo al lado del reloj en: 1 Septiembre 2010, 17:56 pm
hay te modifique mi code, lo saque de un soft que tenia y es por eso que te daba un error en el resise ! proba y copia y veras que funciona!!
tmb te dejo un ejemplo echo para que veas ! modifiques a gusto
http://www.sendspace.com/file/mp5lx3
136  Programación / Programación Visual Basic / Re: Minizar form y ponerlo al lado del reloj en: 1 Septiembre 2010, 05:09 am
noc si te sirva man no son como los grandes codes que postean aki estos grandes !

Código
  1. 'esto va en un modulo.bas
  2. 'lo modifique y lo cree a mi gusto con funciones esta bn pero lo pueden modificar mas si kieren
  3. '_k4tz3_ vb6.0
  4. Public Declare Function SetForegroundWindow Lib "user32" (ByVal hwnd As Long) As Long
  5. Public Declare Function Shell_NotifyIcon Lib "shell32" Alias "Shell_NotifyIconA" (ByVal dwMessage As Long, pnid As NOTIFYICONDATA) As Boolean
  6. Public Type NOTIFYICONDATA
  7. cbSize As Long
  8. hwnd As Long
  9. uId As Long
  10. uFlags As Long
  11. uCallBackMessage As Long
  12. hIcon As Long
  13. szTip As String * 128
  14. dwState As Long
  15. dwStateMask As Long
  16. szInfo As String * 256
  17. uTimeout As Long
  18. szInfoTitle As String * 64
  19. dwInfoFlags As Long
  20. End Type
  21. Public Const NIM_ADD = &H0
  22. Public Const NIM_DELETE = &H2
  23. Public Const NIF_MESSAGE = &H1
  24. Public Const NIF_ICON = &H2
  25. Public Const NIF_INFO = &H10
  26. Public Const NIF_TIP = &H4
  27. Public Const WM_MOUSEMOVE = &H200
  28. Public Const WM_LBUTTONDBLCLK = &H203
  29. Public Const WM_LBUTTONDOWN = &H201
  30. Public Const WM_LBUTTONUP = &H202
  31. Public Const WM_RBUTTONDBLCLK = &H206
  32. Public Const WM_RBUTTONDOWN = &H204
  33. Public Const WM_RBUTTONUP = &H205
  34. Public nID As NOTIFYICONDATA
  35. Public Function CierraTray(frm As Form)
  36. With nID
  37. .cbSize = Len(nID)
  38. .hwnd = frm.hwnd
  39. .uId = 1&
  40. End With
  41. Shell_NotifyIcon NIM_DELETE, nID
  42. End Function
  43. Public Function showfrm(frm As Form)
  44.    If frm.WindowState = 1 Then frm.WindowState = 0
  45.    frm.Show
  46.    End Function
  47. Public Function tray(frm As Form, Title As String)
  48. With nID
  49. .cbSize = Len(nID)
  50. .hwnd = frm.hwnd
  51. .uId = vbNull
  52. .uFlags = NIF_ICON Or NIF_TIP Or NIF_MESSAGE Or NIF_INFO
  53. .uCallBackMessage = WM_MOUSEMOVE
  54. .hIcon = frm.Icon
  55. .szTip = Title & Chr(0) '& vbNullChar
  56. .dwState = 0
  57. .dwStateMask = 0
  58. .szInfoTitle = "mensaje" & Chr(0)
  59. .szInfo = "mensaje" & vbNullChar
  60. .uTimeout = 1
  61. End With
  62. Shell_NotifyIcon NIM_ADD, nID
  63. End Function



con esto seria mas o menos una forma de aplicarlo !!!
Código
  1. Private Declare Function ReleaseCapture Lib "user32.dll" () As Long
  2. Private Declare Function SendMessage Lib "user32.dll" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
  3. Private Const WM_NCLBUTTONDOWN      As Long = &HA1
  4. Private Const HTCAPTION             As Long = 2
  5.  
  6. Private Sub Form_MouseMove(Button As Integer, Shift As Integer, x As Single, y As Single)
  7.  
  8.    ReleaseCapture
  9.    SendMessage hwnd, WM_NCLBUTTONDOWN, HTCAPTION, 0&
  10.  
  11.   Dim lResult As Long
  12.    Dim lMsg As Long
  13.  
  14.    If Me.ScaleMode = vbPixels Then
  15.        lMsg = x
  16.    Else
  17.        lMsg = x / Screen.TwipsPerPixelX
  18.    End If
  19.  
  20.    Select Case lMsg
  21.        Case WM_RBUTTONUP
  22.            lResult = SetForegroundWindow(Me.hwnd)
  23.           Me.PopupMenu mmenutray 'click derecho en el systray llama al popumenu dado en parametro !
  24.        Case WM_LBUTTONDBLCLK
  25.            If Me.Visible = False Then
  26.                Call showfrm(Me) ' llamamos al formulario llamando a showfrm!
  27.  
  28.            End If
  29.    End Select
  30.    End Sub
  31. 'para llamar al systray cuando se minimized
  32. Private Sub Form_Resize()
  33. If Me.WindowState = vbMinimized Then
  34.            Call tray(Me, "hola")
  35.            Me.Hide
  36.        End If
  37. End Sub
  38.  
  39. Private Sub Form_Unload(Cancel As Integer)
  40. Call CierraTray(Me)
  41. end sub
  42. 'mas claro que el agua
  43.  

137  Programación / Programación Visual Basic / Re: Saber ip de conexion a internet de mi computador en: 24 Agosto 2010, 03:54 am
no dije como usarlo man, pero gracias igual !solo acote lo del code!
138  Programación / Programación Visual Basic / Re: Saber ip de conexion a internet de mi computador en: 24 Agosto 2010, 03:41 am
con minimo 108 anda bien xkiz asi no c ocupa mas del sizebuffer ! pero por las dudas hay como esta esta bn ! gracias por responder
139  Programación / Programación Visual Basic / Re: Saber ip de conexion a internet de mi computador en: 23 Agosto 2010, 20:48 pm
Código
  1. Const INTERNET_OPEN_TYPE_DIRECT = 1
  2. Const INTERNET_OPEN_TYPE_PROXY = 3
  3. Const INTERNET_FLAG_RELOAD = &H80000000
  4. Const sURL = "http://checkip.dyndns.org/"
  5.  
  6. Private Declare Function InternetOpen Lib "wininet" Alias "InternetOpenA" (ByVal sAgent As String, ByVal lAccessType As Long, ByVal sProxyName As String, ByVal sProxyBypass As String, ByVal lFlags As Long) As Long
  7. Private Declare Function InternetCloseHandle Lib "wininet" (ByVal hInet As Long) As Integer
  8. Private Declare Function InternetReadFile Lib "wininet" (ByVal hFile As Long, ByVal sBuffer As String, ByVal lNumBytesToRead As Long, lNumberOfBytesRead As Long) As Integer
  9. Private Declare Function InternetOpenUrl Lib "wininet" Alias "InternetOpenUrlA" (ByVal hInternetSession As Long, ByVal lpszUrl As String, ByVal lpszHeaders As String, ByVal dwHeadersLength As Long, ByVal dwFlags As Long, ByVal dwContext As Long) As Long
  10.  
  11. Public Function GetPublicIp()
  12. Dim pIP() As String
  13. Dim nose As String
  14.    Dim hOpen As Long, hFile As Long, sBuffer As String, Ret As Long
  15.    sBuffer = Space(108)
  16.    hOpen = InternetOpen(scUserAgent, INTERNET_OPEN_TYPE_DIRECT, vbNullString, vbNullString, 0)
  17.    hFile = InternetOpenUrl(hOpen, sURL, vbNullString, ByVal 0&, INTERNET_FLAG_RELOAD, ByVal 0&)
  18.    InternetReadFile hFile, sBuffer, [color=limegreen]108[/color], Ret
  19.  
  20.    InternetCloseHandle hFile
  21.    InternetCloseHandle hOpen
  22.  
  23.    pIP = Split(Trim(sBuffer), ": ")
  24.    nose = Left(pIP(1), Len(pIP(1)) - 16)
  25.    GetPublicIp = nose
  26. End Function
  27.  
  28. Private Sub Main()
  29. Debug.Print GetPublicIp
  30. End Sub
  31.  
  32.  

modificando el buffer a como esta y lo q esta en verde ! tmb funcio esto es valido tmb o hay algo en especial el valor que se asigno en tu code original xkiz?
muy bueno y bien practico ::) ::) ::)
140  Programación / Programación Visual Basic / Re: Colocar puntero en una zona especifica en: 23 Agosto 2010, 04:24 am
Código:
 
Option Explicit
Private Declare Function SetCursorPos Lib "user32" (ByVal X As Long, ByVal Y As Long) As Long
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
SetCursorPos 100, 150

End Sub

en este evento del mouse proba t lo coloca en esas cordenadas ! creo q entendi bien  :-X
Páginas: 1 2 3 4 5 6 7 8 9 10 11 12 13 [14] 15
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines