Subversion Repositories Code-Repo

Compare Revisions

Ignore whitespace Rev 53 → Rev 63

/SWAT Office App/trunk/SWAT Office App/Add_User_Account_Form.cs
9,19 → 9,19
 
namespace SWAT_Office_App
{
public partial class AddUserAccount_Form : Form
public partial class Add_User_Account_Form : Form
{
private static AddUserAccount_Form AddUserAccount_Instance = null;
private static Add_User_Account_Form _Add_User_Account_Instance = null;
// Modified singleton instance
public static AddUserAccount_Form Add_User_Account_Instance
public static Add_User_Account_Form Add_User_Account_Instance
{
get
{
AddUserAccount_Instance = new AddUserAccount_Form();
return AddUserAccount_Instance;
_Add_User_Account_Instance = new Add_User_Account_Form();
return _Add_User_Account_Instance;
}
}
public AddUserAccount_Form()
public Add_User_Account_Form()
{
InitializeComponent();
 
66,12 → 66,12
}
private void btn_Add_Click(object sender, EventArgs e)
{
if (ManageUserAccounts.AddUser(txt_Username.Text, txt_Password.Text))
if (Manage_User_Accounts.AddUser(txt_Username.Text, txt_Password.Text))
{
if (this.chk_Share.Checked == true)
if (!ManageUserAccounts.CreateShareFolder(txt_Username.Text))
if (!Manage_User_Accounts.CreateShareFolder(txt_Username.Text))
{
DebugText.appendText("Error occured while creating shared folder");
Debug.appendText("Error occured while creating shared folder");
MessageBox.Show("Error occured when creating shared folder", "Error");
}
this.Close();
78,7 → 78,7
}
else
{
DebugText.appendText("Error occured while creating new user account");
Debug.appendText("Error occured while creating new user account");
MessageBox.Show("Error occured when creating new user account","Error");
resetForm();
}