Process Modules Project

Full Puzzle Game source code and complete project in "Process Modules and ProcessName Collecter" e-learning section.
Coded by: Wesam Naffaa

Puzzle Game project

Full Puzzle Game source code and complete project in "Puzzle Game project" e-learning section.
NOTE: You must read "Puzzle Game - Resources" to understand how to apply the sources & codes to your side.
Coded by: Wesam Naffaa

Accounting Manager project

Full Accounting manager source code and complete project in "Universal Accounting Manager project" e-learning section.
NOTE: You must read "Universal Accounting Manager - Resources" to understand how to apply the sources & codes to your side.
Coded by: Wesam Naffaa

File encryption project

Full File encryption center source code and complete project in "File encryption center project" e-learning section.
NOTE: You must read "File encryption center - Resources" to understand how to apply the sources & codes to your side.
Coded by: Wesam Naffaa

File encryption center - Main.vb

File encryption center / Main.vb
File encryption center - Main.vb
File encryption center - Main.vb

Main.vb
  1. Public Class Main
  2.     Dim MyName As String = My.Application.Info.AssemblyName
  3.     Dim MyDir As String = System.Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\" & MyName
  4.     '16 Byte - Array :
  5.     Dim IntialCryptBytes() As Byte = {115, 63, 40, 66, 225, 205, 99, 160, 199, 185, 180, 170, 160, 39, 10, 1}
  6.     '64 Byte - Array :
  7.     Dim FinalCryptBytes() As Byte = {231, 35, 0, 63, 225, 113, 3, 160, 12, 185, 180, 170, 160, 73, 10, 1, 115, 98, 75, 66, 225, 205, 99, 160, 199, 185, 180, 170, 95, 39, 10, 68, 115, 4, 40, 211, 225, 205, 99, 160, 24, 185, 180, 170, 160, 39, 10, 1, 115, 69, 40, 66, 225, 25, 221, 160, 199, 185, 180, 170, 160, 39, 10, 253}
  8.     '64 Byte - Array :
  9.     Dim SerialNumberBytes(64) As Byte
  10.     'My Dims :
  11.     Dim Addad As Integer = 0
  12.     Dim AnimateX As Integer = 0
  13.     Dim AnimateY As Integer = 0
  14.     Dim MyOpacity As Integer = 0
  15.     Dim MyCommand As String = "Crypt"
  16.     Dim BytesAdder As Double = 0
  17.     Dim SettingsPath As String = MyDir
  18.     Dim CryptFileName As Boolean = False
  19.     Dim LocalFileName As String = ""
  20.     Dim ExitBecauseNotFound As Boolean = False
  21.     Dim AlphaArr() As String = {"ا", "أ", "إ", "ئ", "ء", "ى", "ة", "ؤ", "ب", "ت", "ث", "ج", "ح", "خ", "د", "ذ", "ر", "ز", "س", "ش", "ص", "ض", "ط", "ظ", "ع", "غ", "ف", "ق", "ك", "ل", "م", "ن", "ه", "و", "ي", "لا", "ّ", "َ", "ً", "ُ", "ٌ", "لإ", "‘", "÷", "؛", "ِ", "ٍ", "[", "]", "لأ", "أ", "ـ", "،", "~", "ْ", "{", "}", "لآ", "آ", "’", ".", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", ",", ".", ";", "'", "[", "]", "!", "@", "#", "$", "%", "^", "&", "(", ")", "-", "=", "_", "+", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", " "}
  22.     Dim CryptArr() As String = {"ỹ", "╬", "ỷ", "╫", "ỵ", "╪", "ỳ", "╩", "ự", "╨", "ữ", "╧", "ử", "╦", "ừ", "╥", "ứ", "╤", "ủ", "╣", "ụ", "╢", "ợ", "╡", "ỡ", "╠", "ở", "╟", "ờ", "╞", "ớ", "╝", "ộ", "╛", "ỗ", "╚", "ổ", "╙", "ồ", "╘", "ố", "╗", "ỏ", "╖", "ọ", "╕", "ị", "╔", "ỉ", "╓", "ệ", "╒", "ễ", "║", "ể", "═", "ề", "┼", "ế", "┴", "ẽ", "┬", "ẻ", "┤", "ẹ", "├", "ặ", "┘", "ẵ", "└", "ẳ", "┐", "ằ", "┌", "ắ", "│", "ậ", "─", "ẫ", "◦", "ẩ", "◙", "ầ", "◘", "ấ", "●", "ả", "○", "ạ", "◊", "ẅ", "◄", "ẃ", "▼", "ẁ", "►", "ə", "▲", "Ǿ", "▬", "Ǽ", "▫", "Ǻ", "▪", "Ǜ", "□", "Ǚ", "■", "Ǘ", "▓", "Ǖ", "▒", "Ǔ", "░", "Ǒ", "▐", "Ǐ", "▌", "Ǎ", "█", "Ư", "▄", "Ơ", "ƒ", "☺", "☻", "ž", "▀", "ż", "♫", "ź", "♪", "Ÿ", "♦", "Ŷ", "♥", "ŵ", "♣", "ų", "♠", "ű", "☼", "¤"}
  23.     Dim Clossing As Boolean = False
  24.     Private Sub Main_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
  25.         If Clossing = False Then
  26.             e.Cancel = True
  27.             If MsgBox("هل ترغب حقاً بإنهاء البرنامج ؟", MsgBoxStyle.YesNo, MyName) = MsgBoxResult.Yes Then
  28.                 Clossing = True
  29.                 End
  30.             End If
  31.         End If
  32.     End Sub
  33.     Private Sub Main_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  34.         On Error Resume Next
  35.         If My.Computer.FileSystem.FileExists(MyDir & "\" & MyName & ".exe") = False Then
  36.             Setup.Show()
  37.             Me.FormBorderStyle = Windows.Forms.FormBorderStyle.None
  38.             Me.ShowInTaskbar = False
  39.             Me.Width = 1
  40.             Me.Height = 1
  41.             GoTo EndPoint
  42.         End If
  43.         Me.MaximizeBox = False
  44.         Me.Text = MyName
  45.         MyInfoLBL.Text = MyName & System.Environment.NewLine & My.Application.Info.Version.ToString
  46.         If My.Computer.FileSystem.FileExists(SettingsPath & "\wrongpass.dll") = False Then
  47.             SetValues()
  48.         End If
  49.         ReadValues()
  50.         DragList.CopyNJWMGetLink()
  51.         If Microsoft.VisualBasic.Command <> "" Then
  52.             If Microsoft.VisualBasic.Command.ToLower.Contains("/list /") = True Then
  53.                 'We Have List File :
  54.                 Dim TargetName As String = Microsoft.VisualBasic.Command.Replace("/list /", "")
  55.                 Me.Top = 50
  56.                 DragList.Show()
  57.                 Main_Move(sender, e)
  58.                 DragList.LoadLISTExtention(TargetName)
  59.             Else
  60.                 'We Have Normal Files :
  61.                 Dim TargetName As String = Microsoft.VisualBasic.Command
  62.                 If My.Computer.FileSystem.DirectoryExists(TargetName) = True Then
  63.                     PathTXT.Text = My.Computer.FileSystem.GetDirectoryInfo(TargetName).FullName
  64.                 ElseIf My.Computer.FileSystem.FileExists(TargetName) = True Then
  65.                     PathTXT.Text = My.Computer.FileSystem.GetFileInfo(TargetName).FullName
  66.                 ElseIf TargetName = "/إزالة" Then
  67.                     Setting.RemoveProgram(sender, e)
  68.                 Else
  69.                     PathTXT.Text = TargetName & "  !!"
  70.                 End If
  71.                 PathTXT.ForeColor = Color.Black
  72.                 PathTXT.TextAlign = HorizontalAlignment.Left
  73.             End If
  74.         End If
  75. EndPoint:
  76.     End Sub
  77.     Public Sub GetFiles()
  78.         On Error Resume Next
  79.         InfoLBL.Text = "تحليل مسار ، إنتظر قليلاً"
  80.         AllFiles.Items.Clear()
  81.         If My.Computer.FileSystem.DirectoryExists(PathTXT.Text) = True Then
  82.             AllFiles.Items.AddRange(System.IO.Directory.GetFiles(PathTXT.Text, "*.*", IO.SearchOption.AllDirectories))
  83.         ElseIf My.Computer.FileSystem.FileExists(PathTXT.Text) = True Then
  84.             AllFiles.Items.Add(PathTXT.Text)
  85.         Else
  86.             MsgBox("عذراً ، لكن المسار المكتوب في مربع المسارات غير موجود ... تأكد من صحة المسار", MsgBoxStyle.OkOnly, MyName)
  87.             ExitBecauseNotFound = True
  88.         End If
  89.     End Sub
  90.     Private Sub Manager_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Manager.Tick
  91.         On Error Resume Next
  92.         Dim MyValueProcess As Integer = 0
  93.         If Addad > 0 Then MyValueProcess = Int((Addad * 100) / (AllFiles.Items.Count - 1))
  94.         Me.Text = MyName & "-" & MyValueProcess & " %"
  95.         BytesAdder = BytesAdder + (My.Computer.FileSystem.GetFileInfo(AllFiles.Items.Item(Addad)).Length / 1048576)
  96.         BytesAdder = BytesAdder + 0.00010000001
  97.         If BytesAdder > 1000 Then
  98.             InfoLBL.Text = "تم إنجاز : " & Str(Int(BytesAdder) / 1000).Chars(0) & Str(Int(BytesAdder) / 1000).Chars(1) & Str(Int(BytesAdder) / 1000).Chars(2) & Str(Int(BytesAdder) / 1000).Chars(3) & Str(Int(BytesAdder) / 1000).Chars(4) & " غيغابايت ."
  99.         Else
  100.             InfoLBL.Text = "تم إنجاز : " & Str(BytesAdder).Chars(0) & Str(BytesAdder).Chars(1) & Str(BytesAdder).Chars(2) & Str(BytesAdder).Chars(3) & Str(BytesAdder).Chars(4) & Str(BytesAdder).Chars(5) & Str(BytesAdder).Chars(6) & " ميغابايت ."
  101.         End If
  102.         If MyValueProcess > -1 Then Bar.Value = MyValueProcess
  103.         Dim MyArr() As Byte = My.Computer.FileSystem.ReadAllBytes(AllFiles.Items.Item(Addad))
  104.         Dim TestingByte(15) As Byte
  105.         For Indixer As Integer = 15 To 0 Step -1
  106.             TestingByte(Indixer) = MyArr(15 - Indixer)
  107.         Next
  108.         For indixer As Integer = 0 To 15
  109.             If TestingByte(indixer) <> IntialCryptBytes(indixer) Then
  110.                 GoTo CryptFile
  111.             End If
  112.             If indixer = 15 Then GoTo DesCryptFile
  113.         Next
  114. CryptFile:
  115.         If MyCommand.ToLower = "descrypt" Then GoTo EndPoint
  116.         Dim NewArr(MyArr.Length + SerialNumberBytes.Length - 1 + IntialCryptBytes.Length - 1) As Byte
  117.         Array.Copy(MyArr, NewArr, MyArr.Length)
  118.         For NewAddad As Integer = 0 To 63
  119.             NewArr(MyArr.Length + NewAddad) = SerialNumberBytes(NewAddad)
  120.         Next
  121.         For NewAddad As Integer = 0 To 15
  122.             NewArr(MyArr.Length + SerialNumberBytes.Length - 1 + NewAddad) = IntialCryptBytes(NewAddad)
  123.         Next
  124.         Array.Reverse(NewArr)
  125.         Array.Resize(NewArr, NewArr.Length + 64)
  126.         For NewAddad As Integer = 1 To 64
  127.             NewArr(MyArr.Length + SerialNumberBytes.Length - 1 + IntialCryptBytes.Length - 1 + NewAddad) = FinalCryptBytes(NewAddad - 1)
  128.         Next
  129.         LocalFileName = AllFiles.Items.Item(Addad)
  130.         If CryptFileName = True Then CryptFileNameManager(LocalFileName)
  131.         If My.Computer.FileSystem.FileExists(LocalFileName) = True Then System.IO.File.SetAttributes(LocalFileName, IO.FileAttributes.Normal)
  132.         My.Computer.FileSystem.WriteAllBytes(LocalFileName, NewArr, False)
  133.         GoTo EndPoint
  134. DesCryptFile:
  135.         If MyCommand.ToLower = "crypt" Then GoTo EndPoint
  136.         'Testing Password :
  137.         Dim MyPasswordTester(64) As Byte
  138.         Dim Counter As Integer = -1
  139.         For Indixer As Integer = 79 To 16 Step -1
  140.             Counter = Counter + 1
  141.             MyPasswordTester(Counter) = MyArr(Indixer)
  142.         Next
  143.         '...........................................................................................................................................................................................................................................................................................................................................................................................................................................................................
  144.         '...........................................................................................................................................................................................................................................................................................................................................................................................................................................................................
  145.         GoTo PassWithoutTesting
  146.         '...........................................................................................................................................................................................................................................................................................................................................................................................................................................................................
  147.         '...........................................................................................................................................................................................................................................................................................................................................................................................................................................................................
  148. TestKey:
  149.         If SerialNumber.PassTXT.Text = "free Open FiLe fOR NjWM" Then GoTo PassWithoutTesting
  150.         For indixer As Integer = 0 To 63
  151.             If MyPasswordTester(indixer) <> SerialNumberBytes(indixer) Then
  152.                 GoTo EndPoint
  153.             End If
  154.         Next
  155. PassWithoutTesting:
  156.         Array.Resize(MyArr, MyArr.Length - 64)
  157.         Array.Reverse(MyArr)
  158.         Array.Resize(MyArr, MyArr.Length - 80)
  159.         LocalFileName = AllFiles.Items.Item(Addad)
  160.         DesCryptFileNameManager(LocalFileName)
  161.         If My.Computer.FileSystem.FileExists(LocalFileName) = True Then System.IO.File.SetAttributes(LocalFileName, IO.FileAttributes.Normal)
  162.         My.Computer.FileSystem.WriteAllBytes(LocalFileName, MyArr, False)
  163.         GoTo EndPoint
  164. EndPoint:
  165.         Addad = Addad + 1
  166.         If Addad > AllFiles.Items.Count - 1 Then
  167.             FinishOperating()
  168.         End If
  169.     End Sub
  170.     Public Sub CryptFileNameManager(ByRef FileName As String)
  171.         On Error Resume Next
  172.         Dim CryptName As String = My.Computer.FileSystem.GetFileInfo(LocalFileName).Name
  173.         Dim DirName As String = My.Computer.FileSystem.GetFileInfo(LocalFileName).DirectoryName
  174.         For MyAddad As Integer = 0 To AlphaArr.Length - 1
  175.             CryptName = CryptName.Replace(AlphaArr(MyAddad), CryptArr(MyAddad))
  176.         Next
  177.         If My.Computer.FileSystem.FileExists(LocalFileName) = True Then
  178.             System.IO.File.SetAttributes(LocalFileName, IO.FileAttributes.Normal)
  179.             If My.Computer.FileSystem.FileExists(DirName & "\" & CryptName) = False Then
  180.                 My.Computer.FileSystem.RenameFile(LocalFileName, CryptName)
  181.             End If
  182.         End If
  183.         LocalFileName = DirName & "\" & CryptName
  184.     End Sub
  185.     Public Sub DesCryptFileNameManager(ByRef FileName As String)
  186.         On Error Resume Next
  187.         Dim DesCryptName As String = My.Computer.FileSystem.GetFileInfo(LocalFileName).Name
  188.         Dim DirName As String = My.Computer.FileSystem.GetFileInfo(LocalFileName).DirectoryName
  189.         For MyAddad As Integer = 0 To AlphaArr.Length - 1
  190.             DesCryptName = DesCryptName.Replace(CryptArr(MyAddad), AlphaArr(MyAddad))
  191.         Next
  192.         If My.Computer.FileSystem.FileExists(LocalFileName) = True Then
  193.             System.IO.File.SetAttributes(LocalFileName, IO.FileAttributes.Normal)
  194.             If My.Computer.FileSystem.FileExists(DirName & "\" & DesCryptName) = False Then
  195.                 My.Computer.FileSystem.RenameFile(LocalFileName, DesCryptName)
  196.             End If
  197.         End If
  198.         LocalFileName = DirName & "\" & DesCryptName
  199.     End Sub
  200.     Public Sub FinishOperating()
  201.         On Error Resume Next
  202.         Me.Text = MyName
  203.         Manager.Enabled = False
  204.         CryptBTN.Enabled = True
  205.         DesCryptBTN.Enabled = True
  206.         DragList.CryptBTN.Enabled = True
  207.         DragList.DesCryptBTN.Enabled = True
  208.         Bar.Visible = False
  209.         CloseBTN.Text = "إغلاق"
  210.         Addad = 0
  211.         Array.Clear(SerialNumberBytes, 0, SerialNumberBytes.Length - 1)
  212.         MyCommand = ""
  213.         AllFiles.Items.Clear()
  214.         BytesAdder = 0
  215.         InfoLBL.Text = ""
  216.         PathTXT.Enabled = True
  217.         Bar.Value = 0
  218.         LocalFileName = ""
  219.         MyInfoLBL.Visible = True
  220.     End Sub
  221.     Public Sub SetPassword(ByRef Pass As String)
  222.         On Error Resume Next
  223.         For NewAddad As Integer = 0 To Pass.Length - 1
  224.             SerialNumberBytes(NewAddad) = System.Convert.ToByte(Pass.Chars(NewAddad))
  225.         Next
  226.     End Sub
  227.     Public Sub SetValues()
  228.         On Error Resume Next
  229.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\prio.dll", 2, False)
  230.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\interval.dll", 0, False)
  231.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\cryptname.dll", 1, False)
  232.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\rewrpass.dll", 0, False)
  233.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\wrongpass.dll", 0, False)
  234.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\hidepro.dll", 0, False)
  235.         My.Computer.FileSystem.WriteAllText(SettingsPath & "\updateme.dll", 0, False)
  236.     End Sub
  237.     Public Sub ReadValues()
  238.         On Error Resume Next
  239.         Dim MyReader As Integer = 100
  240.         MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\prio.dll"))
  241.         Dim MyProcesses() As System.Diagnostics.Process
  242.         MyProcesses = Process.GetProcessesByName(MyName.Replace(".exe", ""))
  243.         If MyProcesses.Length > 0 Then
  244.             If MyReader = 0 Then MyProcesses(0).PriorityClass = ProcessPriorityClass.High
  245.             If MyReader = 1 Then MyProcesses(0).PriorityClass = ProcessPriorityClass.AboveNormal
  246.             If MyReader = 2 Then MyProcesses(0).PriorityClass = ProcessPriorityClass.Normal
  247.         End If
  248.         '...........................................................................................................................
  249.         MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\interval.dll"))
  250.         If MyReader = 0 Then Manager.Interval = 1
  251.         If MyReader = 1 Then Manager.Interval = 2
  252.         If MyReader = 2 Then Manager.Interval = 4
  253.         '...........................................................................................................................
  254.         MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\cryptname.dll"))
  255.         If MyReader = 0 Then CryptFileName = True
  256.         If MyReader = 1 Then CryptFileName = False
  257.         '...........................................................................................................................
  258.         'MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\updateme.dll"))
  259.         '...........................................................................................................................
  260.         MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\rewrpass.dll"))
  261.         If MyReader = 0 Then SerialNumber.RePassTXT.Visible = True
  262.         If MyReader = 1 Then SerialNumber.RePassTXT.Visible = False : SerialNumber.RePassLBL.Visible = False
  263.         '...........................................................................................................................
  264.         'MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\wrongpass.dll"))
  265.         'MyReader = Int(My.Computer.FileSystem.ReadAllText(SettingsPath & "\hidepro.dll"))
  266.     End Sub
  267.     Public Sub RemoveProgram()
  268.         On Error Resume Next
  269.         If My.Computer.FileSystem.FileExists(System.Environment.GetFolderPath(Environment.SpecialFolder.Desktop) & "\Free Crypt Center.lnk") = True Then My.Computer.FileSystem.DeleteFile(System.Environment.GetFolderPath(Environment.SpecialFolder.Desktop) & "\Free Crypt Center.lnk", FileIO.UIOption.OnlyErrorDialogs, FileIO.RecycleOption.DeletePermanently)
  270.         If My.Computer.FileSystem.DirectoryExists(System.Environment.GetFolderPath(Environment.SpecialFolder.StartMenu) & "\\uc1?لبرامج\" & MyName) = True Then System.IO.Directory.Delete(System.Environment.GetFolderPath(Environment.SpecialFolder.StartMenu) & "\\uc1?لبرامج\" & MyName, True)
  271.         If My.Computer.FileSystem.DirectoryExists(System.Environment.GetFolderPath(Environment.SpecialFolder.StartMenu) & "\Programs\" & MyName) = True Then System.IO.Directory.Delete(System.Environment.GetFolderPath(Environment.SpecialFolder.StartMenu) & "\Programs\" & MyName, True)
  272.         My.Computer.Registry.ClassesRoot.DeleteSubKeyTree("*\shell\CryptCenter")
  273.         My.Computer.Registry.ClassesRoot.DeleteSubKeyTree("Folder\shell\CryptCenter")
  274.         My.Computer.Registry.ClassesRoot.DeleteSubKeyTree(".list")
  275.         My.Computer.Registry.CurrentUser.DeleteSubKeyTree("Software\Microsoft\Windows\CurrentVersion\Uninstall\" & MyName)
  276.         Dim MyNewCommand As New TextBox
  277.         '"Del " & GetShift.Text & MyDir & "\*.*" & GetShift.Text & " /q /f" & System.Environment.NewLine & "Del " & GetShift.Text & MyDir & "\*.*" & GetShift.Text & " /q /f" & System.Environment.NewLine & "Del " & GetShift.Text & MyDir & "\*.*" & GetShift.Text & " /q /f" & System.Environment.NewLine & "Del " & GetShift.Text & MyDir & "\*.*" & GetShift.Text & " /q /f" & System.Environment.NewLine & "Del " & GetShift.Text & MyDir & "\*.*" & GetShift.Text & " /q /f" & System.Environment.NewLine &
  278.         MyNewCommand.Text = "RmDir " & GetShift.Text & MyDir & GetShift.Text & " /s /q" & System.Environment.NewLine
  279.         Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False) : Call Shell(System.Environment.SystemDirectory & "\cmd.exe /c " & MyNewCommand.Text, AppWinStyle.NormalFocus, False)
  280.         End
  281.     End Sub
  282.     Private Sub CloseBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CloseBTN.Click
  283.         On Error Resume Next
  284.         If CloseBTN.Text = "إيقاف مؤقت" Then
  285.             Manager.Enabled = False
  286.             CloseBTN.Text = "متابعة"
  287.             GoTo EndPoint
  288.         ElseIf CloseBTN.Text = "متابعة" Then
  289.             Manager.Enabled = True
  290.             CloseBTN.Text = "إيقاف مؤقت"
  291.             GoTo EndPoint
  292.         ElseIf CloseBTN.Text = "إغلاق" Then
  293.             Me.Close()
  294.         End If
  295. EndPoint:
  296.     End Sub
  297.     Private Sub PathTXT_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles PathTXT.Click
  298.         On Error Resume Next
  299.         PathTXT.ForeColor = Color.Black
  300.         PathTXT.TextAlign = HorizontalAlignment.Left
  301.         PathTXT.Text = ""
  302.     End Sub
  303.     Private Sub PathTXT_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles PathTXT.DragDrop
  304.         Me.Top = 50
  305.         Dim MyArr As String() = CType(e.Data.GetData(DataFormats.FileDrop), String())
  306.         DragList.ListDragTarget.Items.AddRange(MyArr)
  307.         DragList.Show()
  308.         DragList.LoadItems()
  309.         Main_Move(sender, e)
  310.     End Sub
  311.     Private Sub PathTXT_DragEnter(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles PathTXT.DragEnter
  312.         e.Effect = DragDropEffects.Copy
  313.     End Sub
  314.     Private Sub PathTXT_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PathTXT.MouseClick
  315.         On Error Resume Next
  316.         If e.Button = Windows.Forms.MouseButtons.Right Then
  317.             PathTXT.ForeColor = Color.Black
  318.             PathTXT.TextAlign = HorizontalAlignment.Left
  319.             PathTXT.Text = ""
  320.         End If
  321.     End Sub
  322.     Private Sub PathTXT_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles PathTXT.TextChanged
  323.         On Error Resume Next
  324.         Dim windowsroot As String = System.Environment.SystemDirectory.Replace("\system32", "")
  325.         Dim FileError() As String = {"c:\ntldr", "c:\ntdetect.com", "c:\bootmgr"}
  326.         If My.Computer.FileSystem.FileExists(PathTXT.Text) = True Then
  327.             PIC.Image = My.Resources.OK
  328.             CryptBTN.Enabled = True
  329.             DesCryptBTN.Enabled = True
  330.             DragList.CryptBTN.Enabled = True
  331.             DragList.DesCryptBTN.Enabled = True
  332.         ElseIf My.Computer.FileSystem.DirectoryExists(PathTXT.Text) = True Then
  333.             PIC.Image = My.Resources.OK
  334.             CryptBTN.Enabled = True
  335.             DesCryptBTN.Enabled = True
  336.             DragList.CryptBTN.Enabled = True
  337.             DragList.DesCryptBTN.Enabled = True
  338.         Else
  339.             'Not OK !
  340.             PIC.Image = My.Resources.NotOK
  341.             CryptBTN.Enabled = False
  342.             DesCryptBTN.Enabled = False
  343.             DragList.CryptBTN.Enabled = False
  344.             DragList.DesCryptBTN.Enabled = False
  345.         End If
  346.         'Testing Dirs :
  347.         If PathTXT.Text.ToLower.Contains(windowsroot.ToLower) = True Then MsgBox("أنت تحاول الإخلال بجذر النظام ، سيتم إغلاق البرنامج فوراً", MsgBoxStyle.OkOnly, MyName) : End
  348.         If PathTXT.Text.ToLower.Contains(FileError(0)) = True Then MsgBox("أنت تحاول الإخلال بجذر النظام ، سيتم إغلاق البرنامج فوراً", MsgBoxStyle.OkOnly, MyName) : End
  349.         If PathTXT.Text.ToLower.Contains(FileError(1)) = True Then MsgBox("أنت تحاول الإخلال بجذر النظام ، سيتم إغلاق البرنامج فوراً", MsgBoxStyle.OkOnly, MyName) : End
  350.         If PathTXT.Text.ToLower.Contains(FileError(2)) = True Then MsgBox("أنت تحاول الإخلال بجذر النظام ، سيتم إغلاق البرنامج فوراً", MsgBoxStyle.OkOnly, MyName) : End
  351.         If PathTXT.Text.ToLower.Contains(MyDir.ToLower.Replace("\" & MyName.ToLower, "")) = True Then MsgBox("أنت تحاول الإخلال بجذر النظام ، سيتم إغلاق البرنامج فوراً", MsgBoxStyle.OkOnly, MyName) : End
  352.     End Sub
  353.     Private Sub CryptBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CryptBTN.Click
  354.         On Error Resume Next
  355.         GetFiles()
  356.         If ExitBecauseNotFound = True Then GoTo EndPoint
  357.         Addad = 0
  358.         MyCommand = "Crypt"
  359.         CryptBTN.Enabled = False
  360.         DesCryptBTN.Enabled = False
  361.         DragList.CryptBTN.Enabled = False
  362.         DragList.DesCryptBTN.Enabled = False
  363.         MyInfoLBL.Visible = False
  364.         Bar.Visible = True
  365.         CloseBTN.Text = "إيقاف مؤقت"
  366.         PathTXT.Enabled = False
  367.         SerialNumber.Show()
  368. EndPoint:
  369.         ExitBecauseNotFound = False
  370.     End Sub
  371.     Private Sub DesCryptBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DesCryptBTN.Click
  372.         On Error Resume Next
  373.         GetFiles()
  374.         If ExitBecauseNotFound = True Then GoTo EndPoint
  375.         Addad = 0
  376.         MyCommand = "DesCrypt"
  377.         CryptBTN.Enabled = False
  378.         DesCryptBTN.Enabled = False
  379.         DragList.CryptBTN.Enabled = False
  380.         DragList.DesCryptBTN.Enabled = False
  381.         MyInfoLBL.Visible = False
  382.         Bar.Visible = True
  383.         CloseBTN.Text = "إيقاف مؤقت"
  384.         PathTXT.Enabled = False
  385.         SerialNumber.Show()
  386. EndPoint:
  387.         ExitBecauseNotFound = False
  388.     End Sub
  389.     Private Sub AboutBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AboutBTN.Click
  390.         On Error Resume Next
  391.         AboutHelp.Close()
  392.         AboutHelp.SetParameters("a")
  393.         AboutHelp.Show()
  394.     End Sub
  395.     Private Sub SettingBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SettingBTN.Click
  396.         On Error Resume Next
  397.         Setting.Show()
  398.     End Sub
  399.     Private Sub HelpBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles HelpBTN.Click
  400.         On Error Resume Next
  401.         AboutHelp.Close()
  402.         AboutHelp.SetParameters("h")
  403.         AboutHelp.Show()
  404.     End Sub
  405.     Private Sub Main_Move(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Move
  406.         DragList.Left = Me.Left + (Me.Width / 2) - (DragList.Width / 2)
  407.         DragList.Top = Me.Top + Me.Height + 10
  408.     End Sub
  409.     Private Sub FilesListBTN_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FilesListBTN.Click
  410.         Me.Top = 50
  411.         DragList.Show()
  412.         Main_Move(sender, e)
  413.     End Sub
  414.     Public Sub CallCryptBTN(ByVal sender As System.Object, ByVal e As System.EventArgs)
  415.         CryptBTN_Click(sender, e)
  416.     End Sub
  417.     Public Sub CallDesCryptBTN(ByVal sender As System.Object, ByVal e As System.EventArgs)
  418.         DesCryptBTN_Click(sender, e)
  419.     End Sub
  420. End Class

Valuable E-Book

Hello,
Baby first step is a friendly flashcards offering a growing collection of creative and educational ideas to help the toddler to learn the alphabet, so I put images that would be attractive to babies.

Support independent publishing: Buy this e-book on Lulu.