Advertisement
Charliezkie

[C#] Advance exploit code

Dec 7th, 2019
3,095
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.75 KB | None | 0 0
  1. // Execute Button
  2.  
  3. api.Execute(fastColoredTextBox1.Text);
  4.  
  5. // Clear Button
  6.  
  7. fastColoredTextBox1.Clear();
  8.  
  9. // Open Fiel Button
  10.  
  11. OpenFileDialog ofd = new OpenFileDialog();
  12.             ofd.Filter = "Txt Files (*.txt)|*.txt|Lua Files (*.lua)|*.lua";
  13.            
  14.             if (ofd.ShowDialog() == DialogResult.OK)
  15.             {
  16.                 fastColoredTextBox1.Text = File.ReadAllText(ofd.FileName);
  17.             }
  18.  
  19. // Execute File Button
  20.  
  21. OpenFileDialog ef = new OpenFileDialog();
  22.             ef.Filter = "Txt Files (*.txt)|*.txt|Lua Files (*.lua)|*.lua";
  23.  
  24.             if (ef.ShowDialog() == DialogResult.OK)
  25.             {
  26.                 api.Execute(ef.FileName);
  27.             }
  28.  
  29. // Save File Button
  30.  
  31. SaveFileDialog sfd = new SaveFileDialog();
  32.             sfd.Filter = "Txt Files (*.txt)|*.txt|Lua Files (*.lua)|*.lua";
  33.  
  34.             if (sfd.ShowDialog() == DialogResult.OK)
  35.             {
  36.                 Stream s = sfd.OpenFile();
  37.                 StreamWriter sw = new StreamWriter(s);
  38.             }
  39.  
  40. // Attach button
  41.  
  42. api.Attach();
  43.  
  44. // Form load to load listbox scripts
  45.  
  46. DirectoryInfo di = new DirectoryInfo("./Scripts");
  47.             FileInfo[] files = di.GetFiles("*.txt");
  48.             foreach (FileInfo file in files)
  49.             {
  50.                 listBox1.Items.Add(file.Name);
  51.             }
  52.  
  53.             DirectoryInfo di1 = new DirectoryInfo("./Scripts");
  54.             FileInfo[] files1 = di.GetFiles("*.lua");
  55.             foreach (FileInfo file1 in files1)
  56.             {
  57.                 listBox1.Items.Add(file1.Name);
  58.             }
  59.  
  60. // Listbox selected items
  61.  
  62. if (listBox1.SelectedIndex != -1)
  63.             {
  64.                 fastColoredTextBox1.Text = File.ReadAllText($"./Scripts/{listBox1.SelectedItem}");
  65.             }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement