Beispiel #1
0
        public RegisterContruction(ref ListClient ListClient, ref int Index)
        {
            InitializeComponent();

            this.ListClient = ListClient;
            this.Index      = Index;
        }
Beispiel #2
0
        public RegisterMaterial(ref ListClient ListClient, ref int IndexClient, ref int IndexConstruction)
        {
            InitializeComponent();

            this.ListClient        = ListClient;
            this.IndexClient       = IndexClient;
            this.IndexConstruction = IndexConstruction;
        }
        public RegisterMoney(ref ListClient ListClient, int IndexClient, int IndexConstr)
        {
            InitializeComponent();

            this.ListClient  = ListClient;
            this.IndexClient = IndexClient;
            this.IndexConstr = IndexConstr;
        }
        public ManagerClient(ref ListClient ListClient)
        {
            InitializeComponent();

            this.ListClient = ListClient;

            this.LoadListView();
        }
        public EditeClient(ref ListClient ListClient, ref int Index)
        {
            InitializeComponent();

            this.ListClient = ListClient;
            this.Index      = Index;

            this.LoadData();
        }
        public LoginForm(ref ListClient ListClient)
        {
            InitializeComponent();

            this.ListClient = ListClient;
            this.Login      = new Login();
            new Serializable().LoadUser(ref this.Login);
            this.Count = 0;
        }
        public EditeConstruction(ref ListClient ListClient, ref int IndexClient, ref int IndexConstr)
        {
            InitializeComponent();

            this.ListClient  = ListClient;
            this.IndexClient = IndexClient;
            this.IndexConstr = IndexConstr;

            this.LoadData();
        }
Beispiel #8
0
        public EditeMaterial(ref ListClient ListClient, ref int IndexClient, ref int IndexConstruction, ref int IndexMaterial)
        {
            InitializeComponent();

            this.ListClient        = ListClient;
            this.IndexClient       = IndexClient;
            this.IndexConstruction = IndexConstruction;
            this.IndexMaterial     = IndexMaterial;

            this.LoadTexBox();
        }
        public EditeMoney(ref ListClient ListClient, int IndexClient, int IndexConstr, int IndexMoney)
        {
            InitializeComponent();

            this.ListClient  = ListClient;
            this.IndexClient = IndexClient;
            this.IndexConstr = IndexConstr;
            this.IndexMoney  = IndexMoney;

            this.LoadData();
        }
        public ManagerConstruction(ref ListClient ListClient, ref int IndexClient)
        {
            InitializeComponent();

            this.ListClient  = ListClient;
            this.IndexClient = IndexClient;

            this.labelClient.Text = this.ListClient[this.IndexClient].Name.FullNameByFirstname;

            LoadListView();
        }
        public MainForm(ref ListClient ListClient)
        {
            InitializeComponent();

            this.ListClient    = ListClient;
            this.IndexClient   = -1;
            this.IndexConstr   = -1;
            this.IndexMaterial = -1;
            this.TotalCost     = 0;

            this.LoadComboBoxClient(ref this.comboBoxClient);
        }
        public ManagerMoney(ref ListClient ListClient, int IndexClient, int IndexConstr)
        {
            InitializeComponent();

            this.ListClient  = ListClient;
            this.IndexClient = IndexClient;
            this.IndexConstr = IndexConstr;
            this.IndexMoney  = -1;
            this.TotalCost   = 0;

            this.LoadListView();
        }
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            ListClient ListClient = new ListClient();

            new Serializable().LoadData(ref ListClient);    // Read Data

            new LoginForm(ref ListClient).ShowDialog();     // Show Login Form

            //new MainForm(ref ListClient).ShowDialog();     // Show MainForm

            new Serializable().SavaData(ref ListClient);    // Write Data
        }
        public void SavaData(ref ListClient ListClient)
        {
            try
            {
                using (Stream Stream = File.Open(this.FileName, FileMode.Create))
                {
                    var BinaryFormatter = new System.Runtime.Serialization.Formatters.Binary.BinaryFormatter();

                    BinaryFormatter.Serialize(Stream, ListClient);
                }
            }

            catch (Exception Exception)
            {
                MessageBox.Show("Error al Guardar los Datos. " + Exception.Message);
            }
        }
        public void LoadData(ref ListClient ListClient)
        {
            try
            {
                if (File.Exists(this.FileName))
                {
                    using (Stream Stream = File.Open(this.FileName, FileMode.Open))
                    {
                        var BinaryFormatter = new System.Runtime.Serialization.Formatters.Binary.BinaryFormatter();

                        ListClient = (ListClient)BinaryFormatter.Deserialize(Stream);
                    }
                }
            }

            catch (Exception Exception)
            {
                MessageBox.Show("Error al Leer los Datos. " + Exception.Message);
            }
        }
        public RegisterClient(ref ListClient ListClient)
        {
            InitializeComponent();

            this.ListClient = ListClient;
        }