Autor Tema: Vb6 Exe Taskmgr list SYSTEM Help?  (Leído 3200 veces)

0 Usuarios y 1 Visitante están viendo este tema.

Harmmy

  • Bytes
  • *
  • Mensajes: 22
  • Reputación: +0/-0
    • Ver Perfil
Vb6 Exe Taskmgr list SYSTEM Help?
« en: Agosto 05, 2012, 05:18:50 am »
exe file in the list of taskmsgr.exe want to open as SYSTEM.
Help?
Visual Basic 6

LeandroA

  • Administrador
  • Petabyte
  • *****
  • Mensajes: 1128
  • Reputación: +151/-8
    • Ver Perfil
Re:Vb6 Exe Taskmgr list SYSTEM Help?
« Respuesta #1 en: Agosto 05, 2012, 11:04:20 am »
Hola MiniJoe, te paso un código rebuscado, pero quizas sirva para que te calmes  ;D, es utilizando el comando "AT" y puede tener un minuto de retrazo, no se que se puede hacer con esto ya que todo se ejecuta oculto.

Código: (vb) [Seleccionar]

Option Explicit
Private Declare Function GetShortPathName Lib "kernel32" Alias "GetShortPathNameA" (ByVal lpszLongPath As String, ByVal lpszShortPath As String, ByVal lBuffer As Long) As Long
Private Declare Function GetModuleFileName Lib "kernel32" Alias "GetModuleFileNameA" (ByVal hModule As Long, ByVal lpFileName As String, ByVal nSize As Long) As Long

Private Sub Form_Load()
    If Command <> "-openassystem" Then
        Shell "at " & Format(DateAdd("s", 60, Now), "HH:MM") & " " & GetMyShortPath & " -openassystem"
        End
    End If
    '--------
    'aqui tu codigo
   
End Sub


Public Function GetMyShortPath() As String
    Dim sLongPath As String * 255
    Dim sShortPath As String * 255
    Dim lRet As Long
 
    GetModuleFileName 0, sLongPath, 255
    lRet = GetShortPathName(sLongPath, sShortPath, 255)
    GetMyShortPath = Left$(sShortPath, lRet)
End Function


Harmmy

  • Bytes
  • *
  • Mensajes: 22
  • Reputación: +0/-0
    • Ver Perfil
Re:Vb6 Exe Taskmgr list SYSTEM Help?
« Respuesta #2 en: Agosto 08, 2012, 07:14:31 am »
GetMyShortPath variable not defined