MSG2Server verbessert
This commit is contained in:
@@ -5,6 +5,7 @@ Imports System.Security
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
Imports System.Web
|
||||
Imports iTextSharp.text.pdf.codec
|
||||
|
||||
Public Class cExtProgramme
|
||||
|
||||
@@ -123,6 +124,28 @@ Public Class cExtProgramme
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Public Shared Function msg2server(nachricht As String, server As String)
|
||||
Dim batfile As String = "msgsend.bat"
|
||||
Dim args As String = """" & nachricht & """" & " " & server
|
||||
' MsgBox(args)
|
||||
|
||||
Dim psi As New ProcessStartInfo()
|
||||
psi.FileName = "cmd.exe"
|
||||
psi.Arguments = "/c """ & batFile & " " & args & """"
|
||||
psi.RedirectStandardOutput = True
|
||||
psi.UseShellExecute = False
|
||||
psi.CreateNoWindow = True
|
||||
|
||||
Try
|
||||
Dim process As Process = Process.Start(psi)
|
||||
Dim output As String = process.StandardOutput.ReadToEnd()
|
||||
process.WaitForExit()
|
||||
Console.WriteLine(output)
|
||||
Catch ex As Exception
|
||||
Console.WriteLine("Fehler beim Starten der Batch-Datei: " & ex.Message)
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Public Shared Function StartTeamviewer(ID As String, Optional Passwort As String = "BmWr501956")
|
||||
Dim p As String = ""
|
||||
If Passwort.Length < 1 Then
|
||||
|
||||
Reference in New Issue
Block a user