Exemplo n.º 1
0
 public override string ToString()
 {
     return(Cedula.ToString() + "\t" + Nombre + "\t" + FechaNacimiento.ToShortDateString() + "\t" +
            Sexo.ToString() + "\t" + Telefono.ToString() + "\t" + Correo + "\t" + Direccion + "\t" +
            EstadoCivil.ToString() + "\t" + IdVendedor.ToString() + "\t" + FechaIngreso.ToShortDateString() + "\t" +
            Salario.ToString() + "\t" + Profesion + "\t" + Calificacion.ToString());
 }
Exemplo n.º 2
0
 //public string List()
 //{
 //    string todos = "";
 //    foreach (Vendedor vendedor in ListaVendedor)
 //    {
 //        todos += vendedor.ToString();
 //    }
 //    return todos;
 //}
 /// <summary>
 /// Muestra los datos de un vendedor
 /// </summary>
 public void Show()
 {
     Console.WriteLine(Cedula.ToString().PadRight(12) + Nombre.PadRight(35) + FechaNacimiento.ToShortDateString().PadLeft(12) +
                       Sexo.ToString().PadRight(12).PadLeft(15) + Telefono.ToString().PadLeft(12).PadRight(15) + Correo.PadRight(40) + Direccion.PadRight(40) +
                       EstadoCivil.ToString().PadRight(12) + IdVendedor.ToString().PadLeft(5) + FechaIngreso.ToShortDateString().PadLeft(12) +
                       Salario.ToString().PadLeft(10) + Profesion.PadLeft(20).PadRight(17) + Calificacion.ToString().PadLeft(5));
 }
Exemplo n.º 3
0
        private void Save()
        {
            System.IO.StreamWriter writer = new System.IO.StreamWriter("Files/Cliente.txt", true);

            writer.WriteLine(Cedula.ToString() + "," + Nombre + "," + FechaNacimiento.ToShortDateString() + "," +
                             Sexo.ToString() + "," + Telefono.ToString() + "," + Correo + "," + Direccion + "," +
                             EstadoCivil.ToString() + "," + IdCliente.ToString());

            writer.Close();
        }
Exemplo n.º 4
0
        public override string ToString()
        {
            string sep = "  ;  ";

            return(Codigo.ToString().PadLeft(15) + sep +
                   Nombre.PadLeft(15) + sep +
                   Apellidos.PadLeft(15) + sep +
                   FechaNacimiento.ToShortDateString().PadLeft(15) + sep +
                   SueldoAnual.ToString().PadLeft(10));
        }
Exemplo n.º 5
0
        private void Save()
        {
            System.IO.StreamWriter writer = new System.IO.StreamWriter("Files/Vendedor.txt", true);

            writer.WriteLine(Cedula.ToString() + "," + Nombre + "," + FechaNacimiento.ToShortDateString() + "," +
                             Sexo.ToString() + "," + Telefono.ToString() + "," + Correo + "," + Direccion + "," +
                             EstadoCivil.ToString() + "," + IdVendedor.ToString() + "," + FechaIngreso.ToShortDateString() + "," +
                             Salario.ToString() + "," + Profesion + "," + Calificacion.ToString());

            writer.Close();
        }
Exemplo n.º 6
0
 private string GetLine()
 {
     return($"{IdVendedor},{Cedula},{Nombre},{FechaNacimiento.ToShortDateString()},{Sexo},{Telefono},{Correo},{Direccion}," +
            $"{EstadoCivil},{FechaIngreso.ToShortDateString()},{Salario},{Profesion},{Calificacion}");
 }
Exemplo n.º 7
0
 public override string ToString()
 {
     return(Cedula.ToString() + "\t" + Nombre + "\t" + FechaNacimiento.ToShortDateString() + "\t" +
            Sexo.ToString() + "\t" + Telefono.ToString() + "\t" + Correo + "\t" + Direccion + "\t" +
            EstadoCivil.ToString() + "\t" + IdCliente.ToString());
 }
Exemplo n.º 8
0
        //public string List()
        //{
        //    string todos = "";
        //    foreach (Cliente Cliente in ListaClientes)
        //    {
        //        todos += Cliente.ToString();
        //    }
        //    return todos;
        //}

        /// <summary>
        /// Muestra los datos de un Cliente
        /// </summary>
        public void Show()
        {
            Console.WriteLine(Cedula.ToString().PadRight(12) + Nombre.PadRight(35) + FechaNacimiento.ToShortDateString().PadLeft(12) +
                              Sexo.ToString().PadRight(12).PadLeft(15) + Telefono.ToString().PadLeft(12).PadRight(15) + Correo.PadRight(40) + Direccion.PadRight(40) +
                              EstadoCivil.ToString().PadRight(12) + IdCliente.ToString().PadLeft(5));
        }
Exemplo n.º 9
0
 /// <summary>
 /// Escribe la tabla
 /// </summary>
 /// <returns></returns>
 public override string ToString()
 {
     return("|" + Id.ToString().PadLeft(6, ' ') + " | " +
            Apellidos.PadRight(30) + " | " + Nombre.PadRight(15) + " | " +
            FechaNacimiento.ToShortDateString() + " | ");
 }
Exemplo n.º 10
0
 private string GetLine()
 {
     return($"{IdCliente},{Cedula},{Nombre},{FechaNacimiento.ToShortDateString()}," +
            $"{Sexo},{Telefono},{Correo},{Direccion},{EstadoCivil}");
 }