Beispiel #1
0
 public void update(User_Detail given_User_Detail)
 {
     this.Text = given_User_Detail.username;
     label_Name_User_Display_Form.Text     = given_User_Detail.username;
     label_Password_User_Display_Form.Text = crypting_Object.DecryptString(given_User_Detail.encrypted_General_Password);
     label_Phone_No_User_Display_Form.Text = given_User_Detail.phone_No;
     label_Email_Id_User_Display_Form.Text = given_User_Detail.mail_Id;
     label_Type_User_Display_Form.Text     = given_User_Detail.type;
     if (given_User_Detail.image_Path != "")
     {
         pictureBox_User_Form.Load(given_User_Detail.image_Path);
     }
 }
Beispiel #2
0
        private void initialize_FTP_Settings()
        {
#if LOG
            log_Queue.Enqueue("Entering " + System.Reflection.MethodBase.GetCurrentMethod().ToString());
#endif

            Microsoft.Win32.RegistryKey temp   = Microsoft.Win32.RegistryKey.OpenBaseKey(Microsoft.Win32.RegistryHive.LocalMachine, Microsoft.Win32.RegistryView.Registry32);
            Microsoft.Win32.RegistryKey temp_0 = temp.OpenSubKey("SOFTWARE", true);
            if (!temp_0.GetSubKeyNames().Contains("Resume View"))
            {
                return;
            }

            Microsoft.Win32.RegistryKey resume_View_Key = temp_0.OpenSubKey("Resume View", true);

            ftp_Server   = (string)(resume_View_Key.GetValue("ftp_Server"));
            ftp_Server   = crypting_Object.DecryptString(ftp_Server);
            ftp_Username = (string)(resume_View_Key.GetValue("ftp_Username"));
            ftp_Username = crypting_Object.DecryptString(ftp_Username);
            ftp_Password = (string)(resume_View_Key.GetValue("ftp_Password"));
            ftp_Password = crypting_Object.DecryptString(ftp_Password);
        }
Beispiel #3
0
        public User_Form(string given_Action, User_Detail given_User_Detail)
        {
            InitializeComponent();
            crypting_Object = new Useful_Functions.SimpleAES();
            button_Add_Or_Update_User_Form.Text = given_Action;
            if (given_Action == "Update")
            {
                textBox_Name_User_Form.ReadOnly = true;
            }
            user_Detail = given_User_Detail;

            if (user_Detail != null)
            {
                textBox_Name_User_Form.Text     = user_Detail.username;
                textBox_Password_User_Form.Text = crypting_Object.DecryptString(user_Detail.encrypted_General_Password);
                textBox_Email_Id_User_Form.Text = user_Detail.mail_Id;

                textBox_Phone_No_User_Form.Text = user_Detail.phone_No;
                comboBox_Type_User_Form.Text    = user_Detail.type;
                pictureBox_User_Form.Load(user_Detail.image_Path);
                textBox_Browse_User_Form.Text = user_Detail.image_Path;
            }
        }
Beispiel #4
0
        public void load_Values_From_Registry()
        {
            Microsoft.Win32.RegistryKey temp   = Microsoft.Win32.RegistryKey.OpenBaseKey(Microsoft.Win32.RegistryHive.LocalMachine, Microsoft.Win32.RegistryView.Registry32);
            Microsoft.Win32.RegistryKey temp_0 = temp.OpenSubKey("SOFTWARE", true);
            if (!temp_0.GetSubKeyNames().Contains("Resume View"))
            {
#if Console
                Console.WriteLine("There is no reg entry for the key value \"Resume View\"");
#endif
                return;
            }

            Microsoft.Win32.RegistryKey resume_View_Key = temp_0.OpenSubKey("Resume View", true);

            database_Server   = (string)(resume_View_Key.GetValue("database_Server"));
            database_Server   = crypting_Object.DecryptString(database_Server);
            database_Name     = (string)(resume_View_Key.GetValue("database_Name"));
            database_Name     = crypting_Object.DecryptString(database_Name);
            database_Uid      = (string)(resume_View_Key.GetValue("database_Uid"));
            database_Uid      = crypting_Object.DecryptString(database_Uid);
            database_Password = (string)(resume_View_Key.GetValue("database_Password"));
            database_Password = crypting_Object.DecryptString(database_Password);

            ftp_Server   = (string)(resume_View_Key.GetValue("ftp_Server"));
            ftp_Server   = crypting_Object.DecryptString(ftp_Server);
            ftp_Username = (string)(resume_View_Key.GetValue("ftp_Username"));
            ftp_Username = crypting_Object.DecryptString(ftp_Username);
            ftp_Password = (string)(resume_View_Key.GetValue("ftp_Password"));
            ftp_Password = crypting_Object.DecryptString(ftp_Password);

            doc_To_Html_Server_Address            = (string)(resume_View_Key.GetValue("doc_To_Html_Server_Address"));
            doc_To_Html_Server_Address            = crypting_Object.DecryptString(doc_To_Html_Server_Address);
            doc_To_Html_Server_Port               = (string)(resume_View_Key.GetValue("doc_To_Html_Server_Port"));
            doc_To_Html_Server_Port               = crypting_Object.DecryptString(doc_To_Html_Server_Port);
            doc_To_Html_Server_Max_Connection     = (string)(resume_View_Key.GetValue("doc_To_Html_Server_Max_Connection"));
            doc_To_Html_Server_Max_Connection     = crypting_Object.DecryptString(doc_To_Html_Server_Max_Connection);
            doc_To_Html_Server_Max_Command_Length = (string)(resume_View_Key.GetValue("doc_To_Html_Server_Max_Command_Length"));
            doc_To_Html_Server_Max_Command_Length = crypting_Object.DecryptString(doc_To_Html_Server_Max_Command_Length);

            resume_View_Server_Address            = (string)(resume_View_Key.GetValue("resume_View_Server_Address"));
            resume_View_Server_Address            = crypting_Object.DecryptString(resume_View_Server_Address);
            resume_View_Server_Port               = (string)(resume_View_Key.GetValue("resume_View_Server_Port"));
            resume_View_Server_Port               = crypting_Object.DecryptString(resume_View_Server_Port);
            resume_View_Server_Max_Connection     = (string)(resume_View_Key.GetValue("resume_View_Server_Max_Connection"));
            resume_View_Server_Max_Connection     = crypting_Object.DecryptString(resume_View_Server_Max_Connection);
            resume_View_Server_Max_Command_Length = (string)(resume_View_Key.GetValue("resume_View_Server_Max_Command_Length"));
            resume_View_Server_Max_Command_Length = crypting_Object.DecryptString(resume_View_Server_Max_Command_Length);

            reminder_Server_Address            = (string)(resume_View_Key.GetValue("reminder_Server_Address"));
            reminder_Server_Address            = crypting_Object.DecryptString(reminder_Server_Address);
            reminder_Server_Port               = (string)(resume_View_Key.GetValue("reminder_Server_Port"));
            reminder_Server_Port               = crypting_Object.DecryptString(reminder_Server_Port);
            reminder_Server_Max_Connection     = (string)(resume_View_Key.GetValue("reminder_Server_Max_Connection"));
            reminder_Server_Max_Connection     = crypting_Object.DecryptString(reminder_Server_Max_Connection);
            reminder_Server_Max_Command_Length = (string)(resume_View_Key.GetValue("reminder_Server_Max_Command_Length"));
            reminder_Server_Max_Command_Length = crypting_Object.DecryptString(reminder_Server_Max_Command_Length);

            company_Name = (string)(resume_View_Key.GetValue("company_Name"));
            company_Name = crypting_Object.DecryptString(company_Name);
        }