Hi, can someone fix this errors for me?
Here is code:
namespace Balkan_Elite_Launcher_BETA
{
public partial class Form1 : Form
}
public Form1()
{
InitializeComponent();
}
private void Start_Click(object sender, EventArgs e)
{
private void Form1_Load(object sender, EventArgs e)
{
string myRegistryKey = Registry.CurrentUser.OpenSubKey(@"Software\\SAMP").GetValue("gta_sa_exe").ToString();
myRegistryKey = myRegistryKey.Substring(0, myRegistryKey.LastIndexOf(@"\") + 1);
label1.Text = myRegistryKey + "samp.exe";
textBox1.Text = Registry.CurrentUser.OpenSubKey(@"Software\SAMP", true).GetValue("PlayerName").ToString();
if (!File.Exists(myRegistryKey + "gta_sa.exe"))
{
MessageBox.Show("Nije moguce pronaci GTA.exe u GTA folderu!\n" + myRegistryKey + "\nPorvjerite da li ste odabrali pravi folder, ako jeste pokusajte ponovno instalirati GTA SA.", "Greska", MessageBoxButtons.OK, MessageBoxIcon.Hand);
base.Close();
Application.Exit();
}
else if (!File.Exists(myRegistryKey + "samp.exe"))
{
MessageBox.Show("Nije moguce pronaci samp.exe u GTA folderu:\n" + myRegistryKey + "\nPokusajte ponovno instalirati samp ili Balkan Elite Launcher.", "Greska", MessageBoxButtons.OK, MessageBoxIcon.Hand);
base.Close();
Application.Exit();
}
}
private void Pokreni_Click(object sender, EventArgs e)
{
string ServerIP = "188.165.40.163:7777 ";
string SPHash = "NbGWjfVeFdkDzjCym67lRw==";
string GTAPath = Registry.CurrentUser.OpenSubKey(@"Software\\SAMP").GetValue("gta_sa_exe").ToString();
GTAPath = GTAPath.Substring(0, GTAPath.LastIndexOf(@"\") + 1);
else
{
Registry.CurrentUser.OpenSubKey(@"Software\SAMP", true).SetValue("PlayerName", textBox1.Text);
Process.Start(GTAPath + "samp.exe", ServerIP + SPHash);
}
}
}
If you can tell me what i need to do. Im new in scripting.
Errors:
1: { expected Line: 12
2: Expected class, delegate, enum, interface, or struct Line: 14
3. Expected class, delegate, enum, interface, or struct Line: 19
4. Expected class, delegate, enum, interface, or struct Line: 21
5. Expected class, delegate, enum, interface, or struct Line: 41
What I have tried:
I googled it and it took me an hour but i didnt find it.