Version OScar

This commit is contained in:
Jorge Luis caudillo esparza
2026-04-24 07:54:31 -07:00
parent 8e3df951b3
commit 83acc6b4f1
3780 changed files with 7042960 additions and 0 deletions

View File

@@ -0,0 +1,285 @@

namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
partial class Checadores
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
this.PnlGridchecadores = new System.Windows.Forms.Panel();
this.DGVchecadores = new System.Windows.Forms.DataGridView();
this.Movimiento = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Nombre = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.IPCHECADOR = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.PUERTO = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.GrpNewChecadores = new System.Windows.Forms.GroupBox();
this.TxtPuerto = new System.Windows.Forms.TextBox();
this.TxtIP = new System.Windows.Forms.TextBox();
this.LblNombre = new System.Windows.Forms.Label();
this.LblPuerto = new System.Windows.Forms.Label();
this.LblIP = new System.Windows.Forms.Label();
this.TxtNombre = new System.Windows.Forms.TextBox();
this.BtnActualizar = new FontAwesome.Sharp.IconButton();
this.BtnAgragar = new FontAwesome.Sharp.IconButton();
this.PnlGridchecadores.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.DGVchecadores)).BeginInit();
this.GrpNewChecadores.SuspendLayout();
this.SuspendLayout();
//
// PnlGridchecadores
//
this.PnlGridchecadores.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.PnlGridchecadores.Controls.Add(this.DGVchecadores);
this.PnlGridchecadores.Location = new System.Drawing.Point(12, 142);
this.PnlGridchecadores.Name = "PnlGridchecadores";
this.PnlGridchecadores.Size = new System.Drawing.Size(639, 239);
this.PnlGridchecadores.TabIndex = 7;
//
// DGVchecadores
//
this.DGVchecadores.AllowUserToAddRows = false;
this.DGVchecadores.AllowUserToDeleteRows = false;
this.DGVchecadores.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DGVchecadores.BackgroundColor = System.Drawing.SystemColors.GradientInactiveCaption;
this.DGVchecadores.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.DGVchecadores.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Movimiento,
this.Nombre,
this.IPCHECADOR,
this.PUERTO});
this.DGVchecadores.Dock = System.Windows.Forms.DockStyle.Fill;
this.DGVchecadores.Location = new System.Drawing.Point(0, 0);
this.DGVchecadores.Name = "DGVchecadores";
this.DGVchecadores.ReadOnly = true;
this.DGVchecadores.RowHeadersVisible = false;
this.DGVchecadores.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
this.DGVchecadores.Size = new System.Drawing.Size(639, 239);
this.DGVchecadores.TabIndex = 1;
//
// Movimiento
//
this.Movimiento.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
this.Movimiento.DataPropertyName = "IDCHECADOR";
this.Movimiento.FillWeight = 177.6649F;
this.Movimiento.HeaderText = "#";
this.Movimiento.Name = "Movimiento";
this.Movimiento.ReadOnly = true;
this.Movimiento.Visible = false;
this.Movimiento.Width = 40;
//
// Nombre
//
this.Nombre.DataPropertyName = "NOMBRE";
this.Nombre.FillWeight = 90.35698F;
this.Nombre.HeaderText = "Nombre";
this.Nombre.Name = "Nombre";
this.Nombre.ReadOnly = true;
//
// IPCHECADOR
//
this.IPCHECADOR.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
this.IPCHECADOR.DataPropertyName = "IPCHECADOR";
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
dataGridViewCellStyle1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
dataGridViewCellStyle1.Format = "C";
this.IPCHECADOR.DefaultCellStyle = dataGridViewCellStyle1;
this.IPCHECADOR.FillWeight = 90.35698F;
this.IPCHECADOR.HeaderText = "IP";
this.IPCHECADOR.Name = "IPCHECADOR";
this.IPCHECADOR.ReadOnly = true;
this.IPCHECADOR.Width = 150;
//
// PUERTO
//
this.PUERTO.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
this.PUERTO.DataPropertyName = "PUERTO";
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
dataGridViewCellStyle2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point);
dataGridViewCellStyle2.Format = "C";
this.PUERTO.DefaultCellStyle = dataGridViewCellStyle2;
this.PUERTO.FillWeight = 90.35698F;
this.PUERTO.HeaderText = "Puerto";
this.PUERTO.Name = "PUERTO";
this.PUERTO.ReadOnly = true;
this.PUERTO.Width = 90;
//
// GrpNewChecadores
//
this.GrpNewChecadores.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.GrpNewChecadores.Controls.Add(this.TxtPuerto);
this.GrpNewChecadores.Controls.Add(this.TxtIP);
this.GrpNewChecadores.Controls.Add(this.LblNombre);
this.GrpNewChecadores.Controls.Add(this.LblPuerto);
this.GrpNewChecadores.Controls.Add(this.LblIP);
this.GrpNewChecadores.Controls.Add(this.TxtNombre);
this.GrpNewChecadores.Controls.Add(this.BtnActualizar);
this.GrpNewChecadores.Controls.Add(this.BtnAgragar);
this.GrpNewChecadores.Location = new System.Drawing.Point(12, 12);
this.GrpNewChecadores.Name = "GrpNewChecadores";
this.GrpNewChecadores.Size = new System.Drawing.Size(639, 124);
this.GrpNewChecadores.TabIndex = 6;
this.GrpNewChecadores.TabStop = false;
this.GrpNewChecadores.Text = "Nuevo";
//
// TxtPuerto
//
this.TxtPuerto.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.TxtPuerto.Location = new System.Drawing.Point(509, 40);
this.TxtPuerto.Name = "TxtPuerto";
this.TxtPuerto.Size = new System.Drawing.Size(100, 23);
this.TxtPuerto.TabIndex = 12;
this.TxtPuerto.Text = "4370";
//
// TxtIP
//
this.TxtIP.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.TxtIP.Location = new System.Drawing.Point(289, 40);
this.TxtIP.Name = "TxtIP";
this.TxtIP.Size = new System.Drawing.Size(202, 23);
this.TxtIP.TabIndex = 11;
this.TxtIP.Text = "192.168.100.62";
//
// LblNombre
//
this.LblNombre.AutoSize = true;
this.LblNombre.Location = new System.Drawing.Point(6, 19);
this.LblNombre.Name = "LblNombre";
this.LblNombre.Size = new System.Drawing.Size(51, 15);
this.LblNombre.TabIndex = 10;
this.LblNombre.Text = "Nombre";
//
// LblPuerto
//
this.LblPuerto.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.LblPuerto.AutoSize = true;
this.LblPuerto.Location = new System.Drawing.Point(509, 19);
this.LblPuerto.Name = "LblPuerto";
this.LblPuerto.Size = new System.Drawing.Size(42, 15);
this.LblPuerto.TabIndex = 9;
this.LblPuerto.Text = "Puerto";
//
// LblIP
//
this.LblIP.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.LblIP.AutoSize = true;
this.LblIP.Location = new System.Drawing.Point(289, 19);
this.LblIP.Name = "LblIP";
this.LblIP.Size = new System.Drawing.Size(17, 15);
this.LblIP.TabIndex = 8;
this.LblIP.Text = "IP";
//
// TxtNombre
//
this.TxtNombre.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.TxtNombre.Location = new System.Drawing.Point(6, 40);
this.TxtNombre.Name = "TxtNombre";
this.TxtNombre.Size = new System.Drawing.Size(263, 23);
this.TxtNombre.TabIndex = 7;
//
// BtnActualizar
//
this.BtnActualizar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnActualizar.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.BtnActualizar.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnActualizar.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnActualizar.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnActualizar.IconChar = FontAwesome.Sharp.IconChar.Retweet;
this.BtnActualizar.IconColor = System.Drawing.Color.White;
this.BtnActualizar.IconSize = 32;
this.BtnActualizar.Location = new System.Drawing.Point(492, 69);
this.BtnActualizar.Name = "BtnActualizar";
this.BtnActualizar.Rotation = 0D;
this.BtnActualizar.Size = new System.Drawing.Size(118, 50);
this.BtnActualizar.TabIndex = 6;
this.BtnActualizar.Text = "Actualizar";
this.BtnActualizar.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnActualizar.UseVisualStyleBackColor = false;
this.BtnActualizar.Click += new System.EventHandler(this.BtnActualizar_Click);
//
// BtnAgragar
//
this.BtnAgragar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnAgragar.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.BtnAgragar.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnAgragar.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnAgragar.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnAgragar.IconChar = FontAwesome.Sharp.IconChar.Plus;
this.BtnAgragar.IconColor = System.Drawing.Color.White;
this.BtnAgragar.IconSize = 32;
this.BtnAgragar.Location = new System.Drawing.Point(358, 69);
this.BtnAgragar.Name = "BtnAgragar";
this.BtnAgragar.Rotation = 0D;
this.BtnAgragar.Size = new System.Drawing.Size(118, 50);
this.BtnAgragar.TabIndex = 5;
this.BtnAgragar.Text = "Agregar";
this.BtnAgragar.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnAgragar.UseVisualStyleBackColor = false;
this.BtnAgragar.Click += new System.EventHandler(this.BtnAgragar_Click);
//
// Checadores
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(657, 389);
this.Controls.Add(this.PnlGridchecadores);
this.Controls.Add(this.GrpNewChecadores);
this.Name = "Checadores";
this.Text = "Checadores";
this.Load += new System.EventHandler(this.Checadores_Load);
this.PnlGridchecadores.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.DGVchecadores)).EndInit();
this.GrpNewChecadores.ResumeLayout(false);
this.GrpNewChecadores.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private FontAwesome.Sharp.IconButton BtnAgragar;
private System.Windows.Forms.GroupBox GrpNewChecadores;
private FontAwesome.Sharp.IconButton BtnActualizar;
private System.Windows.Forms.TextBox TxtPuerto;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.Label LblNombre;
private System.Windows.Forms.Label LblPuerto;
private System.Windows.Forms.Label LblIP;
private System.Windows.Forms.TextBox TxtNombre;
private System.Windows.Forms.TextBox TxtIP;
private System.Windows.Forms.TextBox textBox3;
private System.Windows.Forms.Panel PnlGridchecadores;
private System.Windows.Forms.DataGridView DGVchecadores;
private System.Windows.Forms.DataGridViewTextBoxColumn Movimiento;
private System.Windows.Forms.DataGridViewTextBoxColumn Nombre;
private System.Windows.Forms.DataGridViewTextBoxColumn IPCHECADOR;
private System.Windows.Forms.DataGridViewTextBoxColumn PUERTO;
}
}

View File

@@ -0,0 +1,126 @@
using ADSUtileriasWF.Helpers;
using System.Data.SQLite;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
public partial class Checadores : Form
{
private void Checadores_Load(object sender, EventArgs e)
{
loadchecadores();
}
public Checadores()
{
InitializeComponent();
}
public void loadchecadores()
{
DataTable dtChecadores = new DataTable();
ClsBD chk = new ClsBD();
string sqlEjecuta = "SELECT * FROM CHECADORES;";
dtChecadores = chk.EjecutaSqlDT(sqlEjecuta);
DGVchecadores.DataSource = dtChecadores;
DGVchecadores.Refresh();
}
private void BtnAgragar_Click(object sender, EventArgs e)
{
try
{
DataTable dt = new DataTable();
ClsBD chk = new ClsBD();
string sChechador = TxtNombre.Text;
string sIP = TxtIP.Text;
string sPuerto = TxtPuerto.Text;
string sqlEjecuta = "INSERT INTO CHECADORES (NOMBRE,IPCHECADOR,PUERTO) VALUES('" + sChechador + "','" + sIP + "','" + sPuerto + "');";
chk.EjecutaSQL(sqlEjecuta);
TxtNombre.Text = "";
TxtIP.Text = "";
TxtPuerto.Text = "";
chk.Desconectar();
loadchecadores();
}
catch (Exception ex)
{
ModExtensiones.Alert("Error al guardar el checador: " + ex.Message.ToString(), "Información", MessageBoxButtons.OK);
}
}
private void BtnActualizar_Click(object sender, EventArgs e)
{
loadchecadores();
}
}
public class ClsBD
{
private SQLiteConnection sqlconn = new SQLiteConnection();
private SQLiteCommand sqlite_cmd;
public ClsBD()
{
string dirBD = $"Data Source={System.IO.Directory.GetCurrentDirectory()}\\BD\\bdChekadores.db;;Version=3;";
sqlconn.ConnectionString = dirBD;
sqlconn.Open();
// execute queries, etc
//try
//{
// sqlconn.Open();
//}
//catch (Exception ex)
//{
//}
}
public void EjecutaSQL(string sqlQuery)
{
sqlite_cmd = sqlconn.CreateCommand();
sqlite_cmd.CommandText = sqlQuery;
sqlite_cmd.ExecuteNonQuery();
sqlconn.Close();
}
public void Desconectar()
{
sqlconn.Close();
}
public DataTable EjecutaSqlDT(string sqlQuery)
{
DataTable dt = new DataTable();
sqlite_cmd = sqlconn.CreateCommand();
sqlite_cmd.CommandText = sqlQuery;
var sqlite_datareader = sqlite_cmd.ExecuteReader();
try
{
dt.Load(sqlite_datareader);
}
catch (Exception ex)
{
}
return dt;
}
private class SQLiteDataReader
{
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,556 @@
namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
partial class FrmInicio
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.PnlMenu = new System.Windows.Forms.Panel();
this.byadsistemas = new System.Windows.Forms.Label();
this.BtnConfiguracion = new FontAwesome.Sharp.IconButton();
this.BtnReporte = new FontAwesome.Sharp.IconButton();
this.ChecadoresGluyas = new FontAwesome.Sharp.IconButton();
this.BtnNomina = new FontAwesome.Sharp.IconButton();
this.BtnAsistencia = new FontAwesome.Sharp.IconButton();
this.BtnPersonal = new FontAwesome.Sharp.IconButton();
this.BtnChecador = new FontAwesome.Sharp.IconButton();
this.PnlLogo = new System.Windows.Forms.Panel();
this.PnlTitle = new System.Windows.Forms.Panel();
this.PnlmenuXD = new System.Windows.Forms.Panel();
this.btnmenuXD = new FontAwesome.Sharp.IconButton();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.PnlTitulo = new System.Windows.Forms.Panel();
this.BtnMinimize = new FontAwesome.Sharp.IconButton();
this.LblEmpresa = new System.Windows.Forms.Label();
this.BtnMaximizeRestore = new FontAwesome.Sharp.IconButton();
this.BtnClose = new FontAwesome.Sharp.IconButton();
this.PnlBody = new System.Windows.Forms.Panel();
this.PnlBodyForms = new System.Windows.Forms.Panel();
this.PnlTopMenu = new System.Windows.Forms.Panel();
this.LblUsuario = new System.Windows.Forms.Label();
this.IboxUsuario = new FontAwesome.Sharp.IconPictureBox();
this.iconButton2 = new FontAwesome.Sharp.IconButton();
this.LblSubProyecto = new System.Windows.Forms.Label();
this.PnlMenu.SuspendLayout();
this.PnlLogo.SuspendLayout();
this.PnlTitle.SuspendLayout();
this.PnlmenuXD.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.PnlTitulo.SuspendLayout();
this.PnlBody.SuspendLayout();
this.PnlTopMenu.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.IboxUsuario)).BeginInit();
this.SuspendLayout();
//
// PnlMenu
//
this.PnlMenu.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.PnlMenu.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.PnlMenu.Controls.Add(this.byadsistemas);
this.PnlMenu.Controls.Add(this.BtnConfiguracion);
this.PnlMenu.Controls.Add(this.BtnReporte);
this.PnlMenu.Controls.Add(this.ChecadoresGluyas);
this.PnlMenu.Controls.Add(this.BtnNomina);
this.PnlMenu.Controls.Add(this.BtnAsistencia);
this.PnlMenu.Controls.Add(this.BtnPersonal);
this.PnlMenu.Controls.Add(this.BtnChecador);
this.PnlMenu.Controls.Add(this.PnlLogo);
this.PnlMenu.Location = new System.Drawing.Point(0, 0);
this.PnlMenu.Name = "PnlMenu";
this.PnlMenu.Size = new System.Drawing.Size(220, 584);
this.PnlMenu.TabIndex = 0;
//
// byadsistemas
//
this.byadsistemas.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.byadsistemas.AutoSize = true;
this.byadsistemas.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.byadsistemas.Location = new System.Drawing.Point(65, 560);
this.byadsistemas.Name = "byadsistemas";
this.byadsistemas.Size = new System.Drawing.Size(91, 15);
this.byadsistemas.TabIndex = 1;
this.byadsistemas.Text = "by ADSISTEMAS";
//
// BtnConfiguracion
//
this.BtnConfiguracion.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnConfiguracion.FlatAppearance.BorderSize = 0;
this.BtnConfiguracion.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnConfiguracion.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnConfiguracion.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnConfiguracion.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnConfiguracion.IconChar = FontAwesome.Sharp.IconChar.Tools;
this.BtnConfiguracion.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnConfiguracion.IconSize = 28;
this.BtnConfiguracion.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnConfiguracion.Location = new System.Drawing.Point(0, 269);
this.BtnConfiguracion.Name = "BtnConfiguracion";
this.BtnConfiguracion.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnConfiguracion.Rotation = 0D;
this.BtnConfiguracion.Size = new System.Drawing.Size(220, 40);
this.BtnConfiguracion.TabIndex = 0;
this.BtnConfiguracion.Text = "Configuración";
this.BtnConfiguracion.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnConfiguracion.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnConfiguracion.UseVisualStyleBackColor = true;
this.BtnConfiguracion.Click += new System.EventHandler(this.ActivateButton);
//
// BtnReporte
//
this.BtnReporte.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnReporte.FlatAppearance.BorderSize = 0;
this.BtnReporte.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnReporte.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnReporte.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnReporte.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnReporte.IconChar = FontAwesome.Sharp.IconChar.FilePdf;
this.BtnReporte.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnReporte.IconSize = 28;
this.BtnReporte.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnReporte.Location = new System.Drawing.Point(0, 229);
this.BtnReporte.Name = "BtnReporte";
this.BtnReporte.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnReporte.Rotation = 0D;
this.BtnReporte.Size = new System.Drawing.Size(220, 40);
this.BtnReporte.TabIndex = 3;
this.BtnReporte.Text = "Reportes";
this.BtnReporte.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnReporte.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnReporte.UseVisualStyleBackColor = true;
this.BtnReporte.Click += new System.EventHandler(this.ActivateButton);
//
// ChecadoresGluyas
//
this.ChecadoresGluyas.Dock = System.Windows.Forms.DockStyle.Top;
this.ChecadoresGluyas.FlatAppearance.BorderSize = 0;
this.ChecadoresGluyas.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.ChecadoresGluyas.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.ChecadoresGluyas.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.ChecadoresGluyas.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.ChecadoresGluyas.IconChar = FontAwesome.Sharp.IconChar.Algolia;
this.ChecadoresGluyas.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.ChecadoresGluyas.IconSize = 28;
this.ChecadoresGluyas.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.ChecadoresGluyas.Location = new System.Drawing.Point(0, 189);
this.ChecadoresGluyas.Name = "ChecadoresGluyas";
this.ChecadoresGluyas.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.ChecadoresGluyas.Rotation = 0D;
this.ChecadoresGluyas.Size = new System.Drawing.Size(220, 40);
this.ChecadoresGluyas.TabIndex = 2;
this.ChecadoresGluyas.Text = "Checadores";
this.ChecadoresGluyas.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.ChecadoresGluyas.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.ChecadoresGluyas.UseVisualStyleBackColor = true;
this.ChecadoresGluyas.Click += new System.EventHandler(this.ActivateButton);
//
// BtnNomina
//
this.BtnNomina.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnNomina.FlatAppearance.BorderSize = 0;
this.BtnNomina.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnNomina.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnNomina.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnNomina.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnNomina.IconChar = FontAwesome.Sharp.IconChar.Bell;
this.BtnNomina.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnNomina.IconSize = 28;
this.BtnNomina.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnNomina.Location = new System.Drawing.Point(0, 149);
this.BtnNomina.Name = "BtnNomina";
this.BtnNomina.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnNomina.Rotation = 0D;
this.BtnNomina.Size = new System.Drawing.Size(220, 40);
this.BtnNomina.TabIndex = 0;
this.BtnNomina.Text = "Nomina";
this.BtnNomina.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnNomina.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnNomina.UseVisualStyleBackColor = true;
this.BtnNomina.Visible = false;
this.BtnNomina.Click += new System.EventHandler(this.ActivateButton);
//
// BtnAsistencia
//
this.BtnAsistencia.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnAsistencia.FlatAppearance.BorderSize = 0;
this.BtnAsistencia.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnAsistencia.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnAsistencia.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnAsistencia.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnAsistencia.IconChar = FontAwesome.Sharp.IconChar.Check;
this.BtnAsistencia.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnAsistencia.IconSize = 28;
this.BtnAsistencia.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnAsistencia.Location = new System.Drawing.Point(0, 109);
this.BtnAsistencia.Name = "BtnAsistencia";
this.BtnAsistencia.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnAsistencia.Rotation = 0D;
this.BtnAsistencia.Size = new System.Drawing.Size(220, 40);
this.BtnAsistencia.TabIndex = 0;
this.BtnAsistencia.Text = "Asistencia";
this.BtnAsistencia.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnAsistencia.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnAsistencia.UseVisualStyleBackColor = true;
this.BtnAsistencia.Visible = false;
this.BtnAsistencia.Click += new System.EventHandler(this.ActivateButton);
//
// BtnPersonal
//
this.BtnPersonal.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnPersonal.FlatAppearance.BorderSize = 0;
this.BtnPersonal.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnPersonal.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnPersonal.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnPersonal.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnPersonal.IconChar = FontAwesome.Sharp.IconChar.IdCard;
this.BtnPersonal.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnPersonal.IconSize = 28;
this.BtnPersonal.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnPersonal.Location = new System.Drawing.Point(0, 69);
this.BtnPersonal.Name = "BtnPersonal";
this.BtnPersonal.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnPersonal.Rotation = 0D;
this.BtnPersonal.Size = new System.Drawing.Size(220, 40);
this.BtnPersonal.TabIndex = 0;
this.BtnPersonal.Text = "Personal";
this.BtnPersonal.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnPersonal.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnPersonal.UseVisualStyleBackColor = true;
this.BtnPersonal.Visible = false;
this.BtnPersonal.Click += new System.EventHandler(this.ActivateButton);
//
// BtnChecador
//
this.BtnChecador.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnChecador.FlatAppearance.BorderSize = 0;
this.BtnChecador.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnChecador.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnChecador.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnChecador.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnChecador.IconChar = FontAwesome.Sharp.IconChar.Algolia;
this.BtnChecador.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnChecador.IconSize = 28;
this.BtnChecador.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnChecador.Location = new System.Drawing.Point(0, 29);
this.BtnChecador.Name = "BtnChecador";
this.BtnChecador.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnChecador.Rotation = 0D;
this.BtnChecador.Size = new System.Drawing.Size(220, 40);
this.BtnChecador.TabIndex = 0;
this.BtnChecador.Text = "Checadores";
this.BtnChecador.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnChecador.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnChecador.UseVisualStyleBackColor = true;
this.BtnChecador.Visible = false;
this.BtnChecador.Click += new System.EventHandler(this.ActivateButton);
//
// PnlLogo
//
this.PnlLogo.Controls.Add(this.PnlTitle);
this.PnlLogo.Dock = System.Windows.Forms.DockStyle.Top;
this.PnlLogo.Location = new System.Drawing.Point(0, 0);
this.PnlLogo.Name = "PnlLogo";
this.PnlLogo.Size = new System.Drawing.Size(220, 29);
this.PnlLogo.TabIndex = 0;
//
// PnlTitle
//
this.PnlTitle.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.PnlTitle.Controls.Add(this.PnlmenuXD);
this.PnlTitle.Dock = System.Windows.Forms.DockStyle.Top;
this.PnlTitle.Location = new System.Drawing.Point(0, 0);
this.PnlTitle.Name = "PnlTitle";
this.PnlTitle.Size = new System.Drawing.Size(220, 30);
this.PnlTitle.TabIndex = 0;
this.PnlTitle.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// PnlmenuXD
//
this.PnlmenuXD.Controls.Add(this.btnmenuXD);
this.PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Right;
this.PnlmenuXD.Location = new System.Drawing.Point(180, 0);
this.PnlmenuXD.Name = "PnlmenuXD";
this.PnlmenuXD.Size = new System.Drawing.Size(40, 30);
this.PnlmenuXD.TabIndex = 0;
//
// btnmenuXD
//
this.btnmenuXD.FlatAppearance.BorderSize = 0;
this.btnmenuXD.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnmenuXD.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnmenuXD.Font = new System.Drawing.Font("Segoe UI", 16F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.btnmenuXD.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnmenuXD.IconChar = FontAwesome.Sharp.IconChar.Bars;
this.btnmenuXD.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnmenuXD.IconSize = 24;
this.btnmenuXD.ImageAlign = System.Drawing.ContentAlignment.TopLeft;
this.btnmenuXD.Location = new System.Drawing.Point(0, 1);
this.btnmenuXD.Name = "btnmenuXD";
this.btnmenuXD.Rotation = 0D;
this.btnmenuXD.Size = new System.Drawing.Size(40, 30);
this.btnmenuXD.TabIndex = 0;
this.btnmenuXD.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
this.btnmenuXD.UseVisualStyleBackColor = true;
this.btnmenuXD.Click += new System.EventHandler(this.BtnMenuShowHide_Click);
//
// pictureBox1
//
this.pictureBox1.Location = new System.Drawing.Point(9, 7);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(51, 46);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox1.TabIndex = 2;
this.pictureBox1.TabStop = false;
this.pictureBox1.Click += new System.EventHandler(this.LblEmpresa_Click);
//
// PnlTitulo
//
this.PnlTitulo.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.PnlTitulo.Controls.Add(this.LblSubProyecto);
this.PnlTitulo.Controls.Add(this.BtnMinimize);
this.PnlTitulo.Controls.Add(this.LblEmpresa);
this.PnlTitulo.Controls.Add(this.BtnMaximizeRestore);
this.PnlTitulo.Controls.Add(this.BtnClose);
this.PnlTitulo.Dock = System.Windows.Forms.DockStyle.Fill;
this.PnlTitulo.Location = new System.Drawing.Point(0, 0);
this.PnlTitulo.Name = "PnlTitulo";
this.PnlTitulo.Size = new System.Drawing.Size(1238, 584);
this.PnlTitulo.TabIndex = 1;
this.PnlTitulo.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// BtnMinimize
//
this.BtnMinimize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMinimize.FlatAppearance.BorderSize = 0;
this.BtnMinimize.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMinimize.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMinimize.IconChar = FontAwesome.Sharp.IconChar.WindowMinimize;
this.BtnMinimize.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMinimize.IconSize = 20;
this.BtnMinimize.Location = new System.Drawing.Point(1147, 1);
this.BtnMinimize.Name = "BtnMinimize";
this.BtnMinimize.Rotation = 0D;
this.BtnMinimize.Size = new System.Drawing.Size(30, 28);
this.BtnMinimize.TabIndex = 0;
this.BtnMinimize.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMinimize.UseVisualStyleBackColor = true;
this.BtnMinimize.Click += new System.EventHandler(this.BtnMinimize_Click);
//
// LblEmpresa
//
this.LblEmpresa.AutoSize = true;
this.LblEmpresa.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblEmpresa.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblEmpresa.Location = new System.Drawing.Point(226, 7);
this.LblEmpresa.Name = "LblEmpresa";
this.LblEmpresa.Size = new System.Drawing.Size(82, 17);
this.LblEmpresa.TabIndex = 2;
this.LblEmpresa.Text = "ADSISTEMAS";
this.LblEmpresa.Click += new System.EventHandler(this.LblEmpresa_Click);
//
// BtnMaximizeRestore
//
this.BtnMaximizeRestore.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMaximizeRestore.FlatAppearance.BorderSize = 0;
this.BtnMaximizeRestore.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMaximizeRestore.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMaximizeRestore.IconChar = FontAwesome.Sharp.IconChar.WindowMaximize;
this.BtnMaximizeRestore.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMaximizeRestore.IconSize = 20;
this.BtnMaximizeRestore.Location = new System.Drawing.Point(1177, 1);
this.BtnMaximizeRestore.Name = "BtnMaximizeRestore";
this.BtnMaximizeRestore.Rotation = 0D;
this.BtnMaximizeRestore.Size = new System.Drawing.Size(30, 28);
this.BtnMaximizeRestore.TabIndex = 0;
this.BtnMaximizeRestore.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMaximizeRestore.UseVisualStyleBackColor = true;
this.BtnMaximizeRestore.Click += new System.EventHandler(this.BtnMaximizeRestore_Click);
//
// BtnClose
//
this.BtnClose.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnClose.FlatAppearance.BorderSize = 0;
this.BtnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnClose.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnClose.IconChar = FontAwesome.Sharp.IconChar.Times;
this.BtnClose.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnClose.IconSize = 20;
this.BtnClose.Location = new System.Drawing.Point(1207, 1);
this.BtnClose.Name = "BtnClose";
this.BtnClose.Rotation = 0D;
this.BtnClose.Size = new System.Drawing.Size(30, 28);
this.BtnClose.TabIndex = 0;
this.BtnClose.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnClose.UseVisualStyleBackColor = true;
this.BtnClose.Click += new System.EventHandler(this.BtnClose_Click);
//
// PnlBody
//
this.PnlBody.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.PnlBody.AutoScroll = true;
this.PnlBody.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.PnlBody.Controls.Add(this.PnlBodyForms);
this.PnlBody.Location = new System.Drawing.Point(220, 100);
this.PnlBody.Name = "PnlBody";
this.PnlBody.Size = new System.Drawing.Size(1014, 480);
this.PnlBody.TabIndex = 2;
this.PnlBody.SizeChanged += new System.EventHandler(this.PnlBody_SizeChanged);
this.PnlBody.Paint += new System.Windows.Forms.PaintEventHandler(this.PnlBody_Paint);
//
// PnlBodyForms
//
this.PnlBodyForms.Location = new System.Drawing.Point(0, 0);
this.PnlBodyForms.Name = "PnlBodyForms";
this.PnlBodyForms.Size = new System.Drawing.Size(219, 215);
this.PnlBodyForms.TabIndex = 0;
//
// PnlTopMenu
//
this.PnlTopMenu.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.PnlTopMenu.Controls.Add(this.pictureBox1);
this.PnlTopMenu.Controls.Add(this.LblUsuario);
this.PnlTopMenu.Controls.Add(this.IboxUsuario);
this.PnlTopMenu.Location = new System.Drawing.Point(220, 30);
this.PnlTopMenu.Name = "PnlTopMenu";
this.PnlTopMenu.Size = new System.Drawing.Size(1024, 70);
this.PnlTopMenu.TabIndex = 3;
//
// LblUsuario
//
this.LblUsuario.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.LblUsuario.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblUsuario.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblUsuario.Location = new System.Drawing.Point(870, 30);
this.LblUsuario.Name = "LblUsuario";
this.LblUsuario.Size = new System.Drawing.Size(140, 40);
this.LblUsuario.TabIndex = 1;
this.LblUsuario.Text = "Usuario este es un texto muy largo que se brincara la lines para no";
this.LblUsuario.TextAlign = System.Drawing.ContentAlignment.TopCenter;
//
// IboxUsuario
//
this.IboxUsuario.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.IboxUsuario.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.IboxUsuario.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.IboxUsuario.IconChar = FontAwesome.Sharp.IconChar.Portrait;
this.IboxUsuario.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.IboxUsuario.IconSize = 26;
this.IboxUsuario.Location = new System.Drawing.Point(930, 5);
this.IboxUsuario.Name = "IboxUsuario";
this.IboxUsuario.Size = new System.Drawing.Size(32, 26);
this.IboxUsuario.TabIndex = 0;
this.IboxUsuario.TabStop = false;
//
// iconButton2
//
this.iconButton2.Dock = System.Windows.Forms.DockStyle.Top;
this.iconButton2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.iconButton2.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.iconButton2.Font = new System.Drawing.Font("Segoe UI", 16F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.iconButton2.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.iconButton2.IconChar = FontAwesome.Sharp.IconChar.Bars;
this.iconButton2.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.iconButton2.IconSize = 24;
this.iconButton2.ImageAlign = System.Drawing.ContentAlignment.TopLeft;
this.iconButton2.Location = new System.Drawing.Point(0, 0);
this.iconButton2.Name = "iconButton2";
this.iconButton2.Rotation = 0D;
this.iconButton2.Size = new System.Drawing.Size(40, 30);
this.iconButton2.TabIndex = 0;
this.iconButton2.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
this.iconButton2.UseVisualStyleBackColor = true;
//
// LblSubProyecto
//
this.LblSubProyecto.AutoSize = true;
this.LblSubProyecto.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblSubProyecto.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblSubProyecto.Location = new System.Drawing.Point(546, 7);
this.LblSubProyecto.Name = "LblSubProyecto";
this.LblSubProyecto.Size = new System.Drawing.Size(0, 17);
this.LblSubProyecto.TabIndex = 3;
//
// FrmInicio
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(1238, 584);
this.ControlBox = false;
this.Controls.Add(this.PnlTopMenu);
this.Controls.Add(this.PnlBody);
this.Controls.Add(this.PnlMenu);
this.Controls.Add(this.PnlTitulo);
this.MinimumSize = new System.Drawing.Size(650, 400);
this.Name = "FrmInicio";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.PnlMenu.ResumeLayout(false);
this.PnlMenu.PerformLayout();
this.PnlLogo.ResumeLayout(false);
this.PnlTitle.ResumeLayout(false);
this.PnlmenuXD.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.PnlTitulo.ResumeLayout(false);
this.PnlTitulo.PerformLayout();
this.PnlBody.ResumeLayout(false);
this.PnlTopMenu.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.IboxUsuario)).EndInit();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Panel PnlMenu;
private System.Windows.Forms.Panel PnlLogo;
private FontAwesome.Sharp.IconButton BtnChecador;
private FontAwesome.Sharp.IconButton BtnConfiguracion;
private FontAwesome.Sharp.IconButton ChecadoresGluyas;
private FontAwesome.Sharp.IconButton BtnAsistencia;
private FontAwesome.Sharp.IconButton BtnPersonal;
private System.Windows.Forms.Panel PnlTitle;
private System.Windows.Forms.Panel PnlmenuXD;
private FontAwesome.Sharp.IconButton btnmenuXD;
private System.Windows.Forms.Panel PnlTitulo;
private FontAwesome.Sharp.IconButton BtnClose;
private FontAwesome.Sharp.IconButton BtnMaximizeRestore;
private FontAwesome.Sharp.IconButton BtnMinimize;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Label byadsistemas;
private System.Windows.Forms.Panel PnlBody;
private System.Windows.Forms.Panel PnlTopMenu;
private System.Windows.Forms.Panel PnlBodyForms;
private FontAwesome.Sharp.IconPictureBox IboxUsuario;
private System.Windows.Forms.Label LblUsuario;
private System.Windows.Forms.Label LblEmpresa;
private FontAwesome.Sharp.IconButton BtnNomina;
private FontAwesome.Sharp.IconButton iconButton2;
private FontAwesome.Sharp.IconButton BtnReporte;
public System.Windows.Forms.Label LblSubProyecto;
}
}

View File

@@ -0,0 +1,292 @@
using ADSUtileriasWF.Helpers;
using ADSUtileriasWF.Views.RelojChecador.Views;
using ADSUtileriasWF.Views.Timbrado.Views;
using FontAwesome.Sharp;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
public partial class FrmInicio : FormBase
{
const int PnlMenuWidthOpen = 220;
const int PnlMenuWidthClose = 68;
private IconButton currentBtn;
private Form currentForm;
private Panel leftBorderBtn;
private FrmConfiguracion frmConfiguracion;
private FrmAsistencia frmAsistencia;
//private FrmPersonal frmPersonal;
private FrmTimbradoNomina frmTimbradoNomina;
private FrmNewPersonalChecador frmnewPersonal ;
private FrmChecadores frmChecadores;
List<string[]> btnestexto;
public FrmInicio()
{
InitializeComponent();
this.SetStyle(ControlStyles.ResizeRedraw, true);
leftBorderBtn = new Panel();
PnlMenu.Controls.Add(leftBorderBtn);
LblUsuario.Text = "";//"brenda.martinez@agrojam.com.mx";//UsuarioActual.Nombre;
LblEmpresa.Text = "";//"Agroquimicos JAM";//UsuarioActual.Empresa.empresa1Field;
btnestexto = new List<string[]>();
//PnlMenu.Controls.OfType<Control>().SelectMany(x => x is Button))
foreach (Control item in PnlMenu.Controls)
{
if(item is Button){ btnestexto.Add(new string[] { item.Name, item.Text }); }
}
if (ModVarsPV.CveTipoTerminal > 1)
{
activeMenu("BtnComedor");
BtnMenuShowHide_Click(null, null);
this.PnlBody.Width = PnlBody.Width + this.PnlMenu.Width;
this.PnlTopMenu.Width = PnlTopMenu.Width + this.PnlMenu.Width;
this.PnlMenu.Width = 0;
PnlMenu.Visible = false;
PnlTopMenu.Location = new System.Drawing.Point(0, PnlTopMenu.Location.Y);
PnlBody.Location = new System.Drawing.Point(0, PnlBody.Location.Y);
}
}
#region viewchanges
private void BtnMenuShowHide_Click(object sender, EventArgs e)
{
int restante = PnlMenuWidthOpen - PnlMenuWidthClose;
if (PnlMenu.Size.Width == PnlMenuWidthOpen)
{
this.PnlMenu.Width = PnlMenuWidthClose;
//LblEmpresa.Location = new System.Drawing.Point(10, LblEmpresa.Location.Y);
PnlTopMenu.Width = PnlTopMenu.Width + restante;
PnlTopMenu.Location = new System.Drawing.Point(PnlMenuWidthClose, PnlTopMenu.Location.Y);
LblEmpresa.Location=new System.Drawing.Point(LblEmpresa.Location.X - restante, LblEmpresa.Location.Y);
this.PnlBody.Width = PnlBody.Width + restante;
PnlBody.Location = new System.Drawing.Point(PnlMenuWidthClose, PnlBody.Location.Y);
foreach (Control item in PnlMenu.Controls)
{
if (item is Button) { item.Text = ""; }
}
/*
BtnConfiguracion.Text = "";
BtnAsistencia.Text = "";
BtnPersonal.Text = "";
BtnChecador.Text = "";
BtnNomina.Text = "";*/
PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Left;
PnlmenuXD.Size = new System.Drawing.Size(PnlMenuWidthClose, 30);
btnmenuXD.Size = new System.Drawing.Size(PnlMenuWidthClose, 30);
btnmenuXD.Padding = new System.Windows.Forms.Padding(0, 0, 20, 0);
btnmenuXD.Text = " ";
}
else
{
PnlMenu.Width = PnlMenuWidthOpen;
//LblEmpresa.Location = new System.Drawing.Point(160, LblEmpresa.Location.Y);
LblEmpresa.Location=new System.Drawing.Point(LblEmpresa.Location.X + restante, LblEmpresa.Location.Y);
PnlTopMenu.Width = PnlTopMenu.Width - restante;
PnlTopMenu.Location = new System.Drawing.Point(PnlMenuWidthOpen, PnlTopMenu.Location.Y);
PnlBody.Location = new System.Drawing.Point(PnlMenuWidthOpen, PnlBody.Location.Y);
this.PnlBody.Width = PnlBody.Width - restante;
foreach (Control item in PnlMenu.Controls)
{
if (item is Button) {
string texto = btnestexto.FirstOrDefault(x => x[0] == item.Name)[1];
item.Text = texto == null ? "" : texto;
}
}/*
BtnConfiguracion.Text = "Configuración";
BtnAsistencia.Text = "Asistencia";
BtnPersonal.Text = "Personal";
BtnChecador.Text = "Checadores";
BtnNomina.Text = "Nómina";*/
PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Right;
PnlmenuXD.Size = new System.Drawing.Size(40, 30);
btnmenuXD.Size = new System.Drawing.Size(40, 30);
btnmenuXD.Padding = new System.Windows.Forms.Padding(0, 0, 0, 0);
btnmenuXD.Text = "";
}
}
private void setActivateButton(object sender, EventArgs e)
{
if (currentBtn != sender)
{
if (currentBtn != null)
{
currentBtn.BackColor = System.Drawing.Color.FromArgb(54, 65, 80);
currentBtn.ForeColor = btnmenuXD.ForeColor;
currentBtn.TextAlign = ContentAlignment.MiddleLeft;
currentBtn.IconColor = Color.Gainsboro;
currentBtn.TextImageRelation = TextImageRelation.ImageBeforeText;
currentBtn.ImageAlign = ContentAlignment.MiddleLeft;
}
if (sender != null)
{
Color color = Color.FromArgb(53, 152, 220);
//Button
currentBtn = (IconButton)sender;
currentBtn.BackColor = Color.FromArgb(43, 54, 67);
//currentBtn.ForeColor = color;
currentBtn.TextAlign = ContentAlignment.MiddleCenter;
currentBtn.IconColor = color;
currentBtn.TextImageRelation = TextImageRelation.TextBeforeImage;
currentBtn.ImageAlign = ContentAlignment.MiddleRight;
//Left border button
leftBorderBtn.BackColor = color;
leftBorderBtn.Size = new Size(7, currentBtn.Size.Height);
leftBorderBtn.Location = new Point(0, currentBtn.Location.Y);
leftBorderBtn.Visible = true;
leftBorderBtn.BringToFront();
activeMenu(currentBtn.Name.ToString());
}
}
PnlBody_SizeChanged(PnlBody, null);
}
private void ActivateButton(object sender, EventArgs e)
{
setActivateButton(sender, e);
}
private void PnlBody_SizeChanged(object sender, EventArgs e)
{
int width = PnlBody.Width - 5;
int height = PnlBody.Height - 5;
if (currentForm != null)
{
if (width < currentForm.MinimumSize.Width)
{
width = currentForm.MinimumSize.Width;
}
if (height < currentForm.MinimumSize.Height)
{
height = currentForm.MinimumSize.Height;
}
currentForm.Size = new System.Drawing.Size(width, height);
}
PnlBodyForms.Size = new System.Drawing.Size(width, height);
}
#endregion
private void activeMenu(string buttonname)
{
bool isnewform = false;
if (currentForm != null)
{
currentForm.Hide();
currentForm = null;
}
switch (buttonname)
{
/*
private ;
private ;
.Text = "";
.Text = "";*/
case "BtnConfiguracion":
if (frmConfiguracion == null)
{
frmConfiguracion = new FrmConfiguracion();
isnewform = true;
}
currentForm = frmConfiguracion;
break;
case "BtnPersonal":
//if (frmPersonal == null)
//{
// frmPersonal = new FrmPersonal();
// isnewform = true;
//}
//currentForm = frmPersonal;
if (frmnewPersonal == null)
{
frmnewPersonal = new FrmNewPersonalChecador();
isnewform = true;
}
currentForm = frmnewPersonal;
break;
case "BtnAsistencia":
if (frmAsistencia == null)
{
frmAsistencia = new FrmAsistencia();
isnewform = true;
}
currentForm = frmAsistencia;
break;
case "BtnChecador":
if (frmChecadores == null)
{
frmChecadores = new FrmChecadores();
isnewform = true;
}
currentForm = frmChecadores;
break;
case "BtnNomina":
if (frmTimbradoNomina == null)
{
frmTimbradoNomina = new FrmTimbradoNomina();
isnewform = true;
}
currentForm = frmTimbradoNomina;
break;
case "ChecadoresGluyas":
isnewform = true;
currentForm = new ADSUtileriasWF.Views.RelojChecador.Gluyas.Checadores();
break;
case "BtnReporte":
isnewform = true;
currentForm = new ADSUtileriasWF.Views.RelojChecador.Gluyas.ReporteChecadores();
break;
default:
break;
}
if (currentForm != null)
{
if (isnewform)
{
currentForm.TopLevel = false;
currentForm.AutoScroll = true;
this.PnlBodyForms.Controls.Add(currentForm);
currentForm.FormBorderStyle = FormBorderStyle.None;
currentForm.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
}
PnlBodyForms.MinimumSize = currentForm.MinimumSize;
currentForm.BringToFront();
currentForm.Show();
}
else
{
PnlBodyForms.MinimumSize = new System.Drawing.Size(0, 0);
}
}
private void LblEmpresa_Click(object sender, EventArgs e)
{
activeMenu("");
}
private void PnlBody_Paint(object sender, PaintEventArgs e)
{
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,320 @@

namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
partial class ReporteChecadores
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
this.PnlReporte = new System.Windows.Forms.Panel();
this.DTGVReporte = new System.Windows.Forms.DataGridView();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.BtnDescargar = new FontAwesome.Sharp.IconButton();
this.BtnGenerar = new FontAwesome.Sharp.IconButton();
this.TxtSelecPuerto = new System.Windows.Forms.TextBox();
this.TxtSelectIP = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.LblReporte = new System.Windows.Forms.Label();
this.DdlReporte = new System.Windows.Forms.ComboBox();
this.label3 = new System.Windows.Forms.Label();
this.DdlChecadores = new System.Windows.Forms.ComboBox();
this.txtFechaFin = new System.Windows.Forms.DateTimePicker();
this.label2 = new System.Windows.Forms.Label();
this.txtFechaInicio = new System.Windows.Forms.DateTimePicker();
this.label1 = new System.Windows.Forms.Label();
this.PnlReporte.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.DTGVReporte)).BeginInit();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// PnlReporte
//
this.PnlReporte.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.PnlReporte.BackColor = System.Drawing.SystemColors.GradientInactiveCaption;
this.PnlReporte.Controls.Add(this.DTGVReporte);
this.PnlReporte.Location = new System.Drawing.Point(3, 183);
this.PnlReporte.Name = "PnlReporte";
this.PnlReporte.Size = new System.Drawing.Size(585, 191);
this.PnlReporte.TabIndex = 3;
//
// DTGVReporte
//
this.DTGVReporte.AllowUserToAddRows = false;
this.DTGVReporte.AllowUserToDeleteRows = false;
this.DTGVReporte.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DTGVReporte.BackgroundColor = System.Drawing.SystemColors.GradientInactiveCaption;
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.DTGVReporte.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
this.DTGVReporte.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.TopLeft;
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.DTGVReporte.DefaultCellStyle = dataGridViewCellStyle2;
this.DTGVReporte.Dock = System.Windows.Forms.DockStyle.Fill;
this.DTGVReporte.Location = new System.Drawing.Point(0, 0);
this.DTGVReporte.Name = "DTGVReporte";
this.DTGVReporte.RowTemplate.Height = 25;
this.DTGVReporte.Size = new System.Drawing.Size(585, 191);
this.DTGVReporte.TabIndex = 0;
//
// groupBox1
//
this.groupBox1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.groupBox1.Controls.Add(this.BtnDescargar);
this.groupBox1.Controls.Add(this.BtnGenerar);
this.groupBox1.Controls.Add(this.TxtSelecPuerto);
this.groupBox1.Controls.Add(this.TxtSelectIP);
this.groupBox1.Controls.Add(this.label5);
this.groupBox1.Controls.Add(this.label4);
this.groupBox1.Controls.Add(this.LblReporte);
this.groupBox1.Controls.Add(this.DdlReporte);
this.groupBox1.Controls.Add(this.label3);
this.groupBox1.Controls.Add(this.DdlChecadores);
this.groupBox1.Controls.Add(this.txtFechaFin);
this.groupBox1.Controls.Add(this.label2);
this.groupBox1.Controls.Add(this.txtFechaInicio);
this.groupBox1.Controls.Add(this.label1);
this.groupBox1.Location = new System.Drawing.Point(3, 3);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(585, 173);
this.groupBox1.TabIndex = 2;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "Filtro";
//
// BtnDescargar
//
this.BtnDescargar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnDescargar.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.BtnDescargar.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnDescargar.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnDescargar.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnDescargar.IconChar = FontAwesome.Sharp.IconChar.FileExcel;
this.BtnDescargar.IconColor = System.Drawing.Color.White;
this.BtnDescargar.IconSize = 32;
this.BtnDescargar.Location = new System.Drawing.Point(455, 113);
this.BtnDescargar.Name = "BtnDescargar";
this.BtnDescargar.Rotation = 0D;
this.BtnDescargar.Size = new System.Drawing.Size(118, 50);
this.BtnDescargar.TabIndex = 13;
this.BtnDescargar.Text = "Descargar";
this.BtnDescargar.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnDescargar.UseVisualStyleBackColor = false;
this.BtnDescargar.Click += new System.EventHandler(this.BtnDescargar_Click);
//
// BtnGenerar
//
this.BtnGenerar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnGenerar.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.BtnGenerar.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnGenerar.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnGenerar.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnGenerar.IconChar = FontAwesome.Sharp.IconChar.FileExport;
this.BtnGenerar.IconColor = System.Drawing.Color.White;
this.BtnGenerar.IconSize = 32;
this.BtnGenerar.Location = new System.Drawing.Point(331, 113);
this.BtnGenerar.Name = "BtnGenerar";
this.BtnGenerar.Rotation = 0D;
this.BtnGenerar.Size = new System.Drawing.Size(118, 50);
this.BtnGenerar.TabIndex = 12;
this.BtnGenerar.Text = "Generar";
this.BtnGenerar.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnGenerar.UseVisualStyleBackColor = false;
this.BtnGenerar.Click += new System.EventHandler(this.BtnGenerar_Click);
//
// TxtSelecPuerto
//
this.TxtSelecPuerto.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.TxtSelecPuerto.Enabled = false;
this.TxtSelecPuerto.Location = new System.Drawing.Point(217, 84);
this.TxtSelecPuerto.Name = "TxtSelecPuerto";
this.TxtSelecPuerto.Size = new System.Drawing.Size(59, 23);
this.TxtSelecPuerto.TabIndex = 11;
//
// TxtSelectIP
//
this.TxtSelectIP.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.TxtSelectIP.Enabled = false;
this.TxtSelectIP.Location = new System.Drawing.Point(21, 83);
this.TxtSelectIP.Name = "TxtSelectIP";
this.TxtSelectIP.Size = new System.Drawing.Size(174, 23);
this.TxtSelectIP.TabIndex = 10;
//
// label5
//
this.label5.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(217, 64);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(42, 15);
this.label5.TabIndex = 9;
this.label5.Text = "Puerto";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(21, 66);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(17, 15);
this.label4.TabIndex = 8;
this.label4.Text = "IP";
//
// LblReporte
//
this.LblReporte.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.LblReporte.AutoSize = true;
this.LblReporte.Location = new System.Drawing.Point(300, 17);
this.LblReporte.Name = "LblReporte";
this.LblReporte.Size = new System.Drawing.Size(48, 15);
this.LblReporte.TabIndex = 7;
this.LblReporte.Text = "Reporte";
//
// DdlReporte
//
this.DdlReporte.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.DdlReporte.FormattingEnabled = true;
this.DdlReporte.Location = new System.Drawing.Point(300, 38);
this.DdlReporte.Name = "DdlReporte";
this.DdlReporte.Size = new System.Drawing.Size(273, 23);
this.DdlReporte.TabIndex = 6;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(21, 17);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(58, 15);
this.label3.TabIndex = 5;
this.label3.Text = "Checador";
//
// DdlChecadores
//
this.DdlChecadores.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DdlChecadores.FormattingEnabled = true;
this.DdlChecadores.Location = new System.Drawing.Point(21, 38);
this.DdlChecadores.Name = "DdlChecadores";
this.DdlChecadores.Size = new System.Drawing.Size(255, 23);
this.DdlChecadores.TabIndex = 4;
this.DdlChecadores.SelectedIndexChanged += new System.EventHandler(this.DdlChecadores_SelectedIndexChanged);
//
// txtFechaFin
//
this.txtFechaFin.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.txtFechaFin.CustomFormat = "dd/MM/yyyy HH:mm";
this.txtFechaFin.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.txtFechaFin.Location = new System.Drawing.Point(445, 84);
this.txtFechaFin.Name = "txtFechaFin";
this.txtFechaFin.Size = new System.Drawing.Size(128, 23);
this.txtFechaFin.TabIndex = 3;
//
// label2
//
this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(445, 66);
this.label2.Name = "label2";
this.label2.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
this.label2.Size = new System.Drawing.Size(55, 15);
this.label2.TabIndex = 2;
this.label2.Text = "Fecha fin";
//
// txtFechaInicio
//
this.txtFechaInicio.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.txtFechaInicio.CustomFormat = "dd/MM/yyyy HH:mm";
this.txtFechaInicio.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.txtFechaInicio.Location = new System.Drawing.Point(300, 84);
this.txtFechaInicio.Name = "txtFechaInicio";
this.txtFechaInicio.Size = new System.Drawing.Size(128, 23);
this.txtFechaInicio.TabIndex = 1;
//
// label1
//
this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(300, 66);
this.label1.Name = "label1";
this.label1.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
this.label1.Size = new System.Drawing.Size(70, 15);
this.label1.TabIndex = 0;
this.label1.Text = "Fecha inicio";
//
// ReporteChecadores
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(595, 381);
this.Controls.Add(this.PnlReporte);
this.Controls.Add(this.groupBox1);
this.Name = "ReporteChecadores";
this.Text = "ReporteChecadores";
this.Load += new System.EventHandler(this.ReporteChecadores_Load);
this.PnlReporte.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.DTGVReporte)).EndInit();
this.groupBox1.ResumeLayout(false);
this.groupBox1.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Panel PnlReporte;
private System.Windows.Forms.DataGridView DTGVReporte;
private System.Windows.Forms.GroupBox groupBox1;
private FontAwesome.Sharp.IconButton BtnDescargar;
private FontAwesome.Sharp.IconButton BtnGenerar;
private System.Windows.Forms.TextBox TxtSelecPuerto;
private System.Windows.Forms.TextBox TxtSelectIP;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label LblReporte;
private System.Windows.Forms.ComboBox DdlReporte;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.ComboBox DdlChecadores;
private System.Windows.Forms.DateTimePicker txtFechaFin;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.DateTimePicker txtFechaInicio;
private System.Windows.Forms.Label label1;
}
}

View File

@@ -0,0 +1,317 @@
using ADSUtileriasWF.Helpers;
using DocumentFormat.OpenXml.Wordprocessing;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Gluyas
{
public partial class ReporteChecadores : Form
{
DataTable DtAsistencia;
private void ReporteChecadores_Load(object sender, EventArgs e)
{
loadchecadores(); LoadReportes();
}
public void loadchecadores()
{
DataTable dtChecadores = new DataTable();
ClsBD chk = new ClsBD();
string sqlEjecuta = "SELECT * FROM CHECADORES;";
dtChecadores = chk.EjecutaSqlDT(sqlEjecuta);
DataTable dt = new DataTable();
sqlEjecuta = "SELECT IDCHECADOR,NOMBRE FROM CHECADORES UNION SELECT 0 AS IDCHECADOR, 'Seleccione checador...' AS NOMBRE ORDER BY IDCHECADOR,NOMBRE;";
dt = chk.EjecutaSqlDT(sqlEjecuta);
DdlChecadores.DataSource = dt;
DdlChecadores.DisplayMember = "nombre";
DdlChecadores.ValueMember = "IDCHECADOR";
DdlChecadores.Refresh();
chk.Desconectar();
}
public void LoadReportes()
{
DataTable dt = new DataTable();
ClsBD chk = new ClsBD();
string sqlEjecuta = "SELECT 0 AS IdReporte, 'Asistencia' AS Nombre ORDER BY IdReporte;";
dt = chk.EjecutaSqlDT(sqlEjecuta);
DdlReporte.DataSource = dt;
DdlReporte.DisplayMember = "Nombre";
DdlReporte.ValueMember = "IdReporte";
DdlReporte.Refresh();
chk.Desconectar();
}
public ReporteChecadores()
{
InitializeComponent();
}
private void BtnGenerar_Click(object sender, EventArgs e)
{
DataTable dt_periodLog = new DataTable("dt_periodLog");
DtAsistencia = new DataTable("Asistencia");
const string formatfecha = "yyyy/MM/dd HH:mm:ss";
DateTime dfechai = txtFechaInicio.Text.ToDateTime();
DateTime dfechaf = txtFechaFin.Text.ToDateTime();
if (dfechai <= dfechaf)
{
DateTime datei = dfechai.ToString("yyyy/MM/dd").ToDateTime();
DateTime datef = dfechaf.ToString("yyyy/MM/dd").ToDateTime();
DateTime date = datei.AddDays(-1);
string fechai = dfechai.ToString(formatfecha);
string fechaf = dfechaf.ToString(formatfecha);
List<string> listafecha = new List<string>();
List<string[]> ListEmpleados = new List<string[]>();
while ((date = date.AddDays(1)) <= datef)
{
string fecha = $"{date.ToString("dddd", new System.Globalization.CultureInfo("es-MX"))}\r\n{date:dd-MM-yyyy}";
listafecha.Add(fecha);
}
this.DTGVReporte.AutoSizeColumnsMode = listafecha.Count <= 7 ? System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill : System.Windows.Forms.DataGridViewAutoSizeColumnsMode.None;
DTGVReporte.AutoGenerateColumns = true;
DTGVReporte.Columns.Clear();
dt_periodLog.Columns.Add("NOEMPLEADO", System.Type.GetType("System.String"));
dt_periodLog.Columns.Add("FECHA", System.Type.GetType("System.String"));
dt_periodLog.Columns.Add("HORA", System.Type.GetType("System.String"));
//clsFuncionesChk clsFunciones = new clsFuncionesChk();
//clsGlobales extras = new clsGlobales();
//extras.ShowStatusBar("Generando informe...espere por favor", true, lblBarra);
//lblBarra.Refresh();
string sdwEnrollNumber = "";
int idwMachin = 1;
int idwVerifyMode = 0;
int idwInOutMode = 0;
int idwYear = 0;
int idwMonth = 0;
int idwDay = 0;
int idwHour = 0;
int idwMinute = 0;
int idwSecond = 0;
int idwWorkcode = 0;
zkemkeeper.CZKEM conectarse = new zkemkeeper.CZKEM();
bool conectado = false;
try
{
conectado = conectarse.Connect_Net(TxtSelectIP.Text, TxtSelecPuerto.Text.ToEntero());
bool isenabledevice = conectarse.EnableDevice(idwMachin, false);
DataTable dtEmpleados = GetEmpleados(conectarse, idwMachin);
bool lectura = conectarse.ReadTimeGLogData(idwMachin, fechai, fechaf);
while (conectarse.SSR_GetGeneralLogData(idwMachin, out sdwEnrollNumber, out idwVerifyMode, out idwInOutMode, out idwYear, out idwMonth, out idwDay, out idwHour, out idwMinute, out idwSecond, idwWorkcode))
{
DataRow dr = dt_periodLog.NewRow();
dr["NOEMPLEADO"] = sdwEnrollNumber;
DateTime dfecha = $"{idwYear}-{(idwMonth < 10 ? "0" : "")}{idwMonth}-{(idwDay < 10 ? "0" : "")}{ idwDay} {(idwHour < 10 ? "0" : "")}{idwHour}:{(idwMinute < 10 ? "0" : "")}{idwMinute}".ToDateTime();
if (dfecha >= dfechai && dfecha <= dfechaf)
{
if (ListEmpleados.FindAll(x => x[0] == sdwEnrollNumber).Count == 0)
{
string nombre = "";
foreach (DataRow item in dtEmpleados.Select($"NOEMPLEADO = {sdwEnrollNumber}"))
{
nombre = item["NOMBRE"].ToString();
}
ListEmpleados.Add(new string[] { sdwEnrollNumber, nombre });
}
string fecha = $"{dfecha.ToString("dddd", new System.Globalization.CultureInfo("es-MX"))}\r\n{dfecha:dd-MM-yyyy}";
//if (listafecha.FindAll(x => x == fecha).Count == 0) { listafecha.Add(fecha); }
dr["FECHA"] = fecha;// + " " + idwHour.ToString() + ":" + idwMinute.ToString() + ":" + idwSecond.ToString();
dr["HORA"] = $"{(idwHour < 10 ? "0" : "")}{idwHour}:{(idwMinute < 10 ? "0" : "")}{idwMinute}";// + ":" + idwSecond.ToString();
dt_periodLog.Rows.Add(dr);
}
}
DtAsistencia.Columns.Add("Código", System.Type.GetType("System.String"));
DtAsistencia.Columns.Add("Nombre", System.Type.GetType("System.String"));
foreach (var item in listafecha)
{
DtAsistencia.Columns.Add(item, System.Type.GetType("System.String"));
}
dt_periodLog = dt_periodLog.DefaultView.ToTable(true, "NOEMPLEADO", "FECHA", "HORA");
foreach (var user in ListEmpleados)
{
DataRow dr = DtAsistencia.NewRow();
dr["Código"] = user[0];
dr["Nombre"] = user[1];
double numero = 0;
string colname, oldcolname;
oldcolname = "";
foreach (DataRow item in dt_periodLog.Select($"NOEMPLEADO = {user[0]}"))
{
colname = item["FECHA"].ToString();
if (colname != oldcolname) { numero = 0; }
dr[colname] = $"{dr[colname]}{(numero == 0 ? "" : ((numero % 2) == 0) ? "\r\n" : " - ")}{item["HORA"]}";
numero = numero + 1;
oldcolname = colname;
}
DtAsistencia.Rows.Add(dr);
}
}
catch (Exception ex)
{
MessageBox.Show("Error al conectarse al checador " + ex.Message.ToString());
}
finally
{
if (conectado) { conectarse.EnableDevice(idwMachin, true); conectarse.Disconnect(); }
}
}
else
{
MessageBox.Show("la fecha inicio no puede ser mayor a la fecha fin ");
}
DTGVReporte.DataSource = DtAsistencia;
DTGVReporte.Refresh();
}
private DataTable GetEmpleados(zkemkeeper.CZKEM conectarse, int iMachineNumber = 1)
{
DataTable dtEmpleados = new DataTable();
int idwErrorCode = 0;
try
{
dtEmpleados.Columns.Add("NOEMPLEADO");
dtEmpleados.Columns.Add("NOMBRE");
dtEmpleados.Columns.Add("ACTIVO");
string sEnrollNumber = "";
string sName = "";
string sPassword = "";
string sCardnumber = "";
int iPrivilege = 0;
bool bEnabled = false;
int num = 0;
int index = 0;
bool readallinfo = conectarse.ReadAllUserID(iMachineNumber); // ;//read all the user information To the memory
if (readallinfo)
{
while (conectarse.SSR_GetAllUserInfo(iMachineNumber, out sEnrollNumber, out sName, out sPassword, out iPrivilege, out bEnabled))
{
conectarse.GetStrCardNumber(out sCardnumber);
// If conectarse.GetUserFaceStr(1, sEnrollNumber, iFaceIndex, sTmpData, iLength) Then
//personal.CvePersonal = sCardnumber;
DataRow Renglon = dtEmpleados.NewRow();
Renglon["NOEMPLEADO"] = sEnrollNumber;
Renglon["NOMBRE"] = sName;
Renglon["ACTIVO"] = (bEnabled ? 1 : 0);
dtEmpleados.Rows.Add(Renglon);
// While conectarse.GetUserTmp(iMachineNumber, sEnrollNumber, dwFingerIndex, TmpData, TmpLength)
// entre = True
// End While
// lvUserInfo.Items(index).SubItems.Add(sName)
// lvUserInfo.Items(index).SubItems.Add(sPassword)
// lvUserInfo.Items(index).SubItems.Add(iPrivilege.ToString())
// lvUserInfo.Items(index).SubItems.Add(iLength.ToString())
// lvUserInfo.Items(index).SubItems.Add(sTmpData)
index += 1;
num += 1;
}
}
else { conectarse.GetLastError(idwErrorCode); }
}
catch (Exception ex)
{
MessageBox.Show("Error al conectarse al checador " + ex.Message.ToString());
}
return dtEmpleados;
}
private void DdlChecadores_SelectedIndexChanged(object sender, EventArgs e)
{
int IDCHECADOR = DdlChecadores.SelectedValue.ToString().ToEntero();
DataTable dt = new DataTable();
ClsBD chk = new ClsBD();
string sqlEjecuta = $"SELECT IPCHECADOR,PUERTO FROM CHECADORES WHERE IDCHECADOR={IDCHECADOR};";
dt = chk.EjecutaSqlDT(sqlEjecuta);
chk.Desconectar();
TxtSelectIP.Text = "";
TxtSelecPuerto.Text = "";
if (dt.Rows.Count > 0)
{
TxtSelectIP.Text = dt.Rows[0]["IPCHECADOR"].ToString();
TxtSelecPuerto.Text = dt.Rows[0]["PUERTO"].ToString();
}
}
private void BtnDescargar_Click(object sender, EventArgs e)
{
var wb = new ClosedXML.Excel.XLWorkbook();
// Add a DataTable as a worksheet
var wsDep = wb.Worksheets.Add(DtAsistencia);
wsDep.Columns().AdjustToContents();
//System.IO.Stream myStream = null;
//wb.SaveAs(myStream);
//wb.SaveAs("AddingDataTableAsWorksheet.xlsx");
SaveFileDialog SaveFileDialog1 = new SaveFileDialog();
savefileAs(wb, "Asistencia.xlsx", SaveFileDialog1);
}
private void savefileAs(ClosedXML.Excel.XLWorkbook wb,string FileName, SaveFileDialog SaveFileDialog1)
{
// Set the properties on SaveFileDialog1 so the user is
// prompted to create the file if it doesn't exist
// or overwrite the file if it does exist.
SaveFileDialog1.CreatePrompt = true;
SaveFileDialog1.OverwritePrompt = true;
// Set the file name to myText.txt, set the type filter
// to text files, and set the initial directory to the
// MyDocuments folder.
SaveFileDialog1.FileName = FileName;
// DefaultExt is only used when "All files" is selected from
// the filter box and no extension is specified by the user.
SaveFileDialog1.DefaultExt = "xlsx";
SaveFileDialog1.Filter =
"Excel (*.xlsx)|*.txt|All files (*.*)|*.*";
SaveFileDialog1.InitialDirectory =
Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
// Call ShowDialog and check for a return value of DialogResult.OK,
// which indicates that the file was saved.
DialogResult result = SaveFileDialog1.ShowDialog();
System.IO.Stream fileStream;
if (result == DialogResult.OK)
{
// Open the file, copy the contents of memoryStream to fileStream,
// and close fileStream. Set the memoryStream.Position value to 0
// to copy the entire stream.
fileStream = SaveFileDialog1.OpenFile();
wb.SaveAs(fileStream);
/*myStream.Position = 0;
myStream.WriteTo(fileStream);*/
fileStream.Close();
}
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,239 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class Form1
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows 窗体设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.bnInit = new System.Windows.Forms.Button();
this.bnOpen = new System.Windows.Forms.Button();
this.bnEnroll = new System.Windows.Forms.Button();
this.bnFree = new System.Windows.Forms.Button();
this.bnClose = new System.Windows.Forms.Button();
this.bnIdentify = new System.Windows.Forms.Button();
this.textRes = new System.Windows.Forms.TextBox();
this.picFPImg = new System.Windows.Forms.PictureBox();
this.label1 = new System.Windows.Forms.Label();
this.cmbIdx = new System.Windows.Forms.ComboBox();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.BtnCancel = new System.Windows.Forms.Button();
this.BtnAceptar = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.picFPImg)).BeginInit();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// bnInit
//
this.bnInit.Location = new System.Drawing.Point(24, 37);
this.bnInit.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnInit.Name = "bnInit";
this.bnInit.Size = new System.Drawing.Size(88, 29);
this.bnInit.TabIndex = 0;
this.bnInit.Text = "Initialize";
this.bnInit.UseVisualStyleBackColor = true;
this.bnInit.Click += new System.EventHandler(this.bnInit_Click);
//
// bnOpen
//
this.bnOpen.Enabled = false;
this.bnOpen.Location = new System.Drawing.Point(24, 93);
this.bnOpen.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnOpen.Name = "bnOpen";
this.bnOpen.Size = new System.Drawing.Size(88, 29);
this.bnOpen.TabIndex = 1;
this.bnOpen.Text = "Open";
this.bnOpen.UseVisualStyleBackColor = true;
this.bnOpen.Click += new System.EventHandler(this.bnOpen_Click);
//
// bnEnroll
//
this.bnEnroll.Enabled = false;
this.bnEnroll.Location = new System.Drawing.Point(24, 144);
this.bnEnroll.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnEnroll.Name = "bnEnroll";
this.bnEnroll.Size = new System.Drawing.Size(88, 29);
this.bnEnroll.TabIndex = 2;
this.bnEnroll.Text = "Enroll";
this.bnEnroll.UseVisualStyleBackColor = true;
this.bnEnroll.Click += new System.EventHandler(this.bnEnroll_Click);
//
// bnFree
//
this.bnFree.Enabled = false;
this.bnFree.Location = new System.Drawing.Point(145, 37);
this.bnFree.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnFree.Name = "bnFree";
this.bnFree.Size = new System.Drawing.Size(88, 29);
this.bnFree.TabIndex = 4;
this.bnFree.Text = "Finalize";
this.bnFree.UseVisualStyleBackColor = true;
this.bnFree.Click += new System.EventHandler(this.bnFree_Click);
//
// bnClose
//
this.bnClose.Enabled = false;
this.bnClose.Location = new System.Drawing.Point(145, 93);
this.bnClose.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnClose.Name = "bnClose";
this.bnClose.Size = new System.Drawing.Size(88, 29);
this.bnClose.TabIndex = 5;
this.bnClose.Text = "Close";
this.bnClose.UseVisualStyleBackColor = true;
this.bnClose.Click += new System.EventHandler(this.bnClose_Click);
//
// bnIdentify
//
this.bnIdentify.Enabled = false;
this.bnIdentify.Location = new System.Drawing.Point(145, 144);
this.bnIdentify.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.bnIdentify.Name = "bnIdentify";
this.bnIdentify.Size = new System.Drawing.Size(88, 29);
this.bnIdentify.TabIndex = 6;
this.bnIdentify.Text = "Identiy";
this.bnIdentify.UseVisualStyleBackColor = true;
this.bnIdentify.Click += new System.EventHandler(this.bnIdentify_Click);
//
// textRes
//
this.textRes.Location = new System.Drawing.Point(31, 231);
this.textRes.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.textRes.Multiline = true;
this.textRes.Name = "textRes";
this.textRes.ReadOnly = true;
this.textRes.Size = new System.Drawing.Size(357, 62);
this.textRes.TabIndex = 7;
//
// picFPImg
//
this.picFPImg.Location = new System.Drawing.Point(133, 12);
this.picFPImg.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.picFPImg.Name = "picFPImg";
this.picFPImg.Size = new System.Drawing.Size(153, 201);
this.picFPImg.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.picFPImg.TabIndex = 8;
this.picFPImg.TabStop = false;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(238, 44);
this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(39, 15);
this.label1.TabIndex = 9;
this.label1.Text = "Index:";
//
// cmbIdx
//
this.cmbIdx.FormattingEnabled = true;
this.cmbIdx.Location = new System.Drawing.Point(282, 40);
this.cmbIdx.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.cmbIdx.Name = "cmbIdx";
this.cmbIdx.Size = new System.Drawing.Size(46, 23);
this.cmbIdx.TabIndex = 10;
//
// groupBox1
//
this.groupBox1.Controls.Add(this.bnInit);
this.groupBox1.Controls.Add(this.cmbIdx);
this.groupBox1.Controls.Add(this.bnOpen);
this.groupBox1.Controls.Add(this.label1);
this.groupBox1.Controls.Add(this.bnEnroll);
this.groupBox1.Controls.Add(this.bnFree);
this.groupBox1.Controls.Add(this.bnClose);
this.groupBox1.Controls.Add(this.bnIdentify);
this.groupBox1.Location = new System.Drawing.Point(31, 410);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(339, 243);
this.groupBox1.TabIndex = 11;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "groupBox1";
//
// BtnCancel
//
this.BtnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.BtnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.BtnCancel.Location = new System.Drawing.Point(292, 307);
this.BtnCancel.Name = "BtnCancel";
this.BtnCancel.Size = new System.Drawing.Size(94, 35);
this.BtnCancel.TabIndex = 7;
this.BtnCancel.Text = "Cancel";
this.BtnCancel.UseVisualStyleBackColor = true;
this.BtnCancel.Click += new System.EventHandler(this.BtnCancel_Click);
//
// BtnAceptar
//
this.BtnAceptar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.BtnAceptar.Location = new System.Drawing.Point(192, 309);
this.BtnAceptar.Name = "BtnAceptar";
this.BtnAceptar.Size = new System.Drawing.Size(94, 35);
this.BtnAceptar.TabIndex = 6;
this.BtnAceptar.Text = "Aceptar";
this.BtnAceptar.UseVisualStyleBackColor = true;
this.BtnAceptar.Click += new System.EventHandler(this.BtnOK_Click);
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(409, 365);
this.ControlBox = false;
this.Controls.Add(this.BtnAceptar);
this.Controls.Add(this.BtnCancel);
this.Controls.Add(this.groupBox1);
this.Controls.Add(this.picFPImg);
this.Controls.Add(this.textRes);
this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.Name = "Form1";
this.ShowIcon = false;
this.ShowInTaskbar = false;
this.Load += new System.EventHandler(this.Form1_Load);
((System.ComponentModel.ISupportInitialize)(this.picFPImg)).EndInit();
this.groupBox1.ResumeLayout(false);
this.groupBox1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Button bnInit;
private System.Windows.Forms.Button bnOpen;
private System.Windows.Forms.Button bnEnroll;
private System.Windows.Forms.Button bnFree;
private System.Windows.Forms.Button bnClose;
private System.Windows.Forms.Button bnIdentify;
private System.Windows.Forms.TextBox textRes;
private System.Windows.Forms.PictureBox picFPImg;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.ComboBox cmbIdx;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.Button BtnCancel;
private System.Windows.Forms.Button BtnAceptar;
}
}

View File

@@ -0,0 +1,604 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using libzkfpcsharp;
using System.Runtime.InteropServices;
using System.Threading;
using System.IO;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class Form1 : Form
{
IntPtr mDevHandle = IntPtr.Zero;
IntPtr mDBHandle = IntPtr.Zero;
IntPtr FormHandle = IntPtr.Zero;
bool bIsTimeToDie = false;
bool IsRegister = false;
bool bIdentify = true;
byte[] FPBuffer;
int RegisterCount = 0;
const int REGISTER_FINGER_COUNT = 3;
byte[][] RegTmps = new byte[3][];
byte[] RegTmp = new byte[2048];
byte[] CapTmp = new byte[2048];
int cbCapTmp = 2048;
int cbRegTmp = 0;
int iFid = 1;
private int mfpWidth = 0;
private int mfpHeight = 0;
const int MESSAGE_CAPTURED_OK = 0x0400 + 6;
[DllImport("user32.dll", EntryPoint = "SendMessageA")]
public static extern int SendMessage(IntPtr hwnd, int wMsg, IntPtr wParam, IntPtr lParam);
public Form1()
{
InitializeComponent();
bnInit_Click(null, null);
bnOpen_Click(null, null);
//bnEnroll_Click(null, null);
}
private void bnInit_Click(object sender, EventArgs e)
{
cmbIdx.Items.Clear();
int ret = zkfperrdef.ZKFP_ERR_OK;
if ((ret = zkfp2.Init()) == zkfperrdef.ZKFP_ERR_OK)
{
int nCount = zkfp2.GetDeviceCount();
if (nCount > 0)
{
for (int i = 0; i < nCount; i++)
{
cmbIdx.Items.Add(i.ToString());
}
cmbIdx.SelectedIndex = 0;
bnInit.Enabled = false;
bnFree.Enabled = true;
bnOpen.Enabled = true;
}
else
{
zkfp2.Terminate();
MessageBox.Show("No device connected!");
}
}
else
{
MessageBox.Show("Initialize fail, ret=" + ret + " !");
}
}
private void bnFree_Click(object sender, EventArgs e)
{
zkfp2.Terminate();
cbRegTmp = 0;
bnInit.Enabled = true;
bnFree.Enabled = false;
bnOpen.Enabled = false;
bnClose.Enabled = false;
bnEnroll.Enabled = false;
//bnVerify.Enabled = false;
bnIdentify.Enabled = false;
}
private void bnOpen_Click(object sender, EventArgs e)
{
int ret = zkfp.ZKFP_ERR_OK;
if (IntPtr.Zero == (mDevHandle = zkfp2.OpenDevice(cmbIdx.SelectedIndex)))
{
MessageBox.Show("OpenDevice fail");
return;
}
if (IntPtr.Zero == (mDBHandle = zkfp2.DBInit()))
{
MessageBox.Show("Init DB fail");
zkfp2.CloseDevice(mDevHandle);
mDevHandle = IntPtr.Zero;
return;
}
bnInit.Enabled = false;
bnFree.Enabled = true;
bnOpen.Enabled = false;
bnClose.Enabled = true;
bnEnroll.Enabled = true;
//bnVerify.Enabled = true;
bnIdentify.Enabled = true;
RegisterCount = 0;
cbRegTmp = 0;
iFid = 1;
for (int i = 0; i < 3; i++)
{
RegTmps[i] = new byte[2048];
}
byte[] paramValue = new byte[4];
int size = 4;
zkfp2.GetParameters(mDevHandle, 1, paramValue, ref size);
zkfp2.ByteArray2Int(paramValue, ref mfpWidth);
size = 4;
zkfp2.GetParameters(mDevHandle, 2, paramValue, ref size);
zkfp2.ByteArray2Int(paramValue, ref mfpHeight);
FPBuffer = new byte[mfpWidth*mfpHeight];
Thread captureThread = new Thread(new ThreadStart(DoCapture));
captureThread.IsBackground = true;
captureThread.Start();
bIsTimeToDie = false;
textRes.Text = "Open succ";
}
private void DoCapture()
{
while (!bIsTimeToDie)
{
cbCapTmp = 2048;
int ret = zkfp2.AcquireFingerprint(mDevHandle, FPBuffer, CapTmp, ref cbCapTmp);
if (ret == zkfp.ZKFP_ERR_OK)
{
SendMessage(FormHandle, MESSAGE_CAPTURED_OK, IntPtr.Zero, IntPtr.Zero);
}
Thread.Sleep(200);
}
}
protected override void DefWndProc(ref Message m)
{
switch (m.Msg)
{
case MESSAGE_CAPTURED_OK:
{
MemoryStream ms = new MemoryStream();
BitmapFormat.GetBitmap(FPBuffer, mfpWidth, mfpHeight, ref ms);
Bitmap bmp = new Bitmap(ms);
this.picFPImg.Image = bmp;
if (IsRegister)
{
int ret = zkfp.ZKFP_ERR_OK;
int fid = 0, score = 0;
ret = zkfp2.DBIdentify(mDBHandle, CapTmp, ref fid, ref score);
if (zkfp.ZKFP_ERR_OK == ret)
{
textRes.Text = "Huella registrada (" + fid + ")!";
return;
}
if (RegisterCount > 0 && zkfp2.DBMatch(mDBHandle, CapTmp, RegTmps[RegisterCount - 1]) <= 0)
{
textRes.Text = "Favor de ingresar 3 veces la huella";
return;
}
Array.Copy(CapTmp, RegTmps[RegisterCount], cbCapTmp);
String strBase64 = zkfp2.BlobToBase64(CapTmp, cbCapTmp);
byte[] blob = zkfp2.Base64ToBlob(strBase64);
RegisterCount++;
if (RegisterCount >= REGISTER_FINGER_COUNT)
{
RegisterCount = 0;
if (zkfp.ZKFP_ERR_OK == (ret = zkfp2.DBMerge(mDBHandle, RegTmps[0], RegTmps[1], RegTmps[2], RegTmp, ref cbRegTmp)) &&
zkfp.ZKFP_ERR_OK == (ret = zkfp2.DBAdd(mDBHandle, iFid, RegTmp)))
{
iFid++;
textRes.Text = "Su huella ha sido capturada";
}
else
{
textRes.Text = "Ocurrio un error al ingresar la huella (Codigo " + ret + ").";
}
IsRegister = false;
return;
}
else
{
textRes.Text = "favor de ingresar su huella " + (REGISTER_FINGER_COUNT - RegisterCount) + " veces mas en el lector.";
}
}
else
{
if (cbRegTmp <= 0)
{
textRes.Text = "favor de registrar su huella primero!";
return;
}
if (bIdentify)
{
int ret = zkfp.ZKFP_ERR_OK;
int fid = 0, score = 0;
ret = zkfp2.DBIdentify(mDBHandle, CapTmp, ref fid, ref score);
if (zkfp.ZKFP_ERR_OK == ret)
{
textRes.Text = "Identify succ, fid= " + fid + ",score=" + score + "!";
return;
}
else
{
textRes.Text = "Identify fail, ret= " + ret;
return;
}
}
/* else
{
int ret = zkfp2.DBMatch(mDBHandle, CapTmp, RegTmp);
if (0 < ret)
{
textRes.Text = "Match finger succ, score=" + ret + "!";
return;
}
else
{
textRes.Text = "Match finger fail, ret= " + ret;
return;
}
}*/
}
}
break;
default:
base.DefWndProc(ref m);
break;
}
}
private void Form1_Load(object sender, EventArgs e)
{
FormHandle = this.Handle;
}
private void bnClose_Click(object sender, EventArgs e)
{
bIsTimeToDie = true;
RegisterCount = 0;
Thread.Sleep(1000);
zkfp2.CloseDevice(mDevHandle);
bnInit.Enabled = false;
bnFree.Enabled = true;
bnOpen.Enabled = true;
bnClose.Enabled = false;
bnEnroll.Enabled = false;
//bnVerify.Enabled = false;
bnIdentify.Enabled = false;
}
public void bnEnroll_Click(object sender, EventArgs e)
{
//if (!IsRegister)
//{
this.picFPImg.Image = null;
IsRegister = true;
RegisterCount = 0;
cbRegTmp = 0;
textRes.Text = "Favor de ingresar su huella 3 veces!";
//}
}
private void bnIdentify_Click(object sender, EventArgs e)
{
if (!bIdentify)
{
bIdentify = true;
textRes.Text = "Please press your finger!";
}
}
private void bnVerify_Click(object sender, EventArgs e)
{
if (bIdentify)
{
bIdentify = false;
textRes.Text = "Please press your finger!";
}
}
private void BtnOK_Click(object sender, EventArgs e)
{
this.Hide();
}
private void BtnCancel_Click(object sender, EventArgs e)
{
this.Hide();
}
}
public class BitmapFormat
{
public struct BITMAPFILEHEADER
{
public ushort bfType;
public int bfSize;
public ushort bfReserved1;
public ushort bfReserved2;
public int bfOffBits;
}
public struct MASK
{
public byte redmask;
public byte greenmask;
public byte bluemask;
public byte rgbReserved;
}
public struct BITMAPINFOHEADER
{
public int biSize;
public int biWidth;
public int biHeight;
public ushort biPlanes;
public ushort biBitCount;
public int biCompression;
public int biSizeImage;
public int biXPelsPerMeter;
public int biYPelsPerMeter;
public int biClrUsed;
public int biClrImportant;
}
/*******************************************
* º¯ÊýÃû³Æ£ºRotatePic
* º¯Êý¹¦ÄÜ£ºÐýתͼƬ£¬Ä¿µÄÊDZ£´æºÍÏÔʾµÄͼƬÓë°´µÄÖ¸ÎÆ·½Ïò²»Í¬
* º¯ÊýÈë²Î£ºBmpBuf---ÐýתǰµÄÖ¸ÎÆ×Ö·û´®
* º¯Êý³ö²Î£ºResBuf---ÐýתºóµÄÖ¸ÎÆ×Ö·û´®
* º¯Êý·µ»Ø£ºÎÞ
*********************************************/
public static void RotatePic(byte[] BmpBuf, int width, int height, ref byte[] ResBuf)
{
int RowLoop = 0;
int ColLoop = 0;
int BmpBuflen = width * height;
try
{
for (RowLoop = 0; RowLoop < BmpBuflen;)
{
for (ColLoop = 0; ColLoop < width; ColLoop++)
{
ResBuf[RowLoop + ColLoop] = BmpBuf[BmpBuflen - RowLoop - width + ColLoop];
}
RowLoop = RowLoop + width;
}
}
catch (Exception ex)
{
//ZKCE.SysException.ZKCELogger logger = new ZKCE.SysException.ZKCELogger(ex);
//logger.Append();
}
}
/*******************************************
* º¯ÊýÃû³Æ£ºStructToBytes
* º¯Êý¹¦ÄÜ£º½«½á¹¹Ìåת»¯³ÉÎÞ·ûºÅ×Ö·û´®Êý×é
* º¯ÊýÈë²Î£ºStructObj---±»×ª»¯µÄ½á¹¹Ìå
* Size---±»×ª»¯µÄ½á¹¹ÌåµÄ´óС
* º¯Êý³ö²Î£ºÎÞ
* º¯Êý·µ»Ø£º½á¹¹Ìåת»¯ºóµÄÊý×é
*********************************************/
public static byte[] StructToBytes(object StructObj, int Size)
{
int StructSize = Marshal.SizeOf(StructObj);
byte[] GetBytes = new byte[StructSize];
try
{
IntPtr StructPtr = Marshal.AllocHGlobal(StructSize);
Marshal.StructureToPtr(StructObj, StructPtr, false);
Marshal.Copy(StructPtr, GetBytes, 0, StructSize);
Marshal.FreeHGlobal(StructPtr);
if (Size == 14)
{
byte[] NewBytes = new byte[Size];
int Count = 0;
int Loop = 0;
for (Loop = 0; Loop < StructSize; Loop++)
{
if (Loop != 2 && Loop != 3)
{
NewBytes[Count] = GetBytes[Loop];
Count++;
}
}
return NewBytes;
}
else
{
return GetBytes;
}
}
catch (Exception ex)
{
//ZKCE.SysException.ZKCELogger logger = new ZKCE.SysException.ZKCELogger(ex);
//logger.Append();
return GetBytes;
}
}
/*******************************************
* º¯ÊýÃû³Æ£ºGetBitmap
* º¯Êý¹¦ÄÜ£º½«´«½øÀ´µÄÊý¾Ý±£´æÎªÍ¼Æ¬
* º¯ÊýÈë²Î£ºbuffer---ͼƬÊý¾Ý
* nWidth---ͼƬµÄ¿í¶È
* nHeight---ͼƬµÄ¸ß¶È
* º¯Êý³ö²Î£ºÎÞ
* º¯Êý·µ»Ø£ºÎÞ
*********************************************/
public static void GetBitmap(byte[] buffer, int nWidth, int nHeight, ref MemoryStream ms)
{
int ColorIndex = 0;
ushort m_nBitCount = 8;
int m_nColorTableEntries = 256;
byte[] ResBuf = new byte[nWidth * nHeight * 2];
try
{
BITMAPFILEHEADER BmpHeader = new BITMAPFILEHEADER();
BITMAPINFOHEADER BmpInfoHeader = new BITMAPINFOHEADER();
MASK[] ColorMask = new MASK[m_nColorTableEntries];
int w = (((nWidth + 3) / 4) * 4);
//ͼƬͷÐÅÏ¢
BmpInfoHeader.biSize = Marshal.SizeOf(BmpInfoHeader);
BmpInfoHeader.biWidth = nWidth;
BmpInfoHeader.biHeight = nHeight;
BmpInfoHeader.biPlanes = 1;
BmpInfoHeader.biBitCount = m_nBitCount;
BmpInfoHeader.biCompression = 0;
BmpInfoHeader.biSizeImage = 0;
BmpInfoHeader.biXPelsPerMeter = 0;
BmpInfoHeader.biYPelsPerMeter = 0;
BmpInfoHeader.biClrUsed = m_nColorTableEntries;
BmpInfoHeader.biClrImportant = m_nColorTableEntries;
//ÎļþÍ·ÐÅÏ¢
BmpHeader.bfType = 0x4D42;
BmpHeader.bfOffBits = 14 + Marshal.SizeOf(BmpInfoHeader) + BmpInfoHeader.biClrUsed * 4;
BmpHeader.bfSize = BmpHeader.bfOffBits + ((((w * BmpInfoHeader.biBitCount + 31) / 32) * 4) * BmpInfoHeader.biHeight);
BmpHeader.bfReserved1 = 0;
BmpHeader.bfReserved2 = 0;
ms.Write(StructToBytes(BmpHeader, 14), 0, 14);
ms.Write(StructToBytes(BmpInfoHeader, Marshal.SizeOf(BmpInfoHeader)), 0, Marshal.SizeOf(BmpInfoHeader));
//µ÷ÊÔ°åÐÅÏ¢
for (ColorIndex = 0; ColorIndex < m_nColorTableEntries; ColorIndex++)
{
ColorMask[ColorIndex].redmask = (byte)ColorIndex;
ColorMask[ColorIndex].greenmask = (byte)ColorIndex;
ColorMask[ColorIndex].bluemask = (byte)ColorIndex;
ColorMask[ColorIndex].rgbReserved = 0;
ms.Write(StructToBytes(ColorMask[ColorIndex], Marshal.SizeOf(ColorMask[ColorIndex])), 0, Marshal.SizeOf(ColorMask[ColorIndex]));
}
//ͼƬÐýת£¬½â¾öÖ¸ÎÆÍ¼Æ¬µ¹Á¢µÄÎÊÌâ
RotatePic(buffer, nWidth, nHeight, ref ResBuf);
byte[] filter = null;
if (w - nWidth > 0)
{
filter = new byte[w - nWidth];
}
for (int i = 0; i < nHeight; i++)
{
ms.Write(ResBuf, i * nWidth, nWidth);
if (w - nWidth > 0)
{
ms.Write(ResBuf, 0, w - nWidth);
}
}
}
catch (Exception ex)
{
// ZKCE.SysException.ZKCELogger logger = new ZKCE.SysException.ZKCELogger(ex);
// logger.Append();
}
}
/*******************************************
* º¯ÊýÃû³Æ£ºWriteBitmap
* º¯Êý¹¦ÄÜ£º½«´«½øÀ´µÄÊý¾Ý±£´æÎªÍ¼Æ¬
* º¯ÊýÈë²Î£ºbuffer---ͼƬÊý¾Ý
* nWidth---ͼƬµÄ¿í¶È
* nHeight---ͼƬµÄ¸ß¶È
* º¯Êý³ö²Î£ºÎÞ
* º¯Êý·µ»Ø£ºÎÞ
*********************************************/
public static void WriteBitmap(byte[] buffer, int nWidth, int nHeight)
{
int ColorIndex = 0;
ushort m_nBitCount = 8;
int m_nColorTableEntries = 256;
byte[] ResBuf = new byte[nWidth * nHeight];
try
{
BITMAPFILEHEADER BmpHeader = new BITMAPFILEHEADER();
BITMAPINFOHEADER BmpInfoHeader = new BITMAPINFOHEADER();
MASK[] ColorMask = new MASK[m_nColorTableEntries];
int w = (((nWidth + 3) / 4) * 4);
//ͼƬͷÐÅÏ¢
BmpInfoHeader.biSize = Marshal.SizeOf(BmpInfoHeader);
BmpInfoHeader.biWidth = nWidth;
BmpInfoHeader.biHeight = nHeight;
BmpInfoHeader.biPlanes = 1;
BmpInfoHeader.biBitCount = m_nBitCount;
BmpInfoHeader.biCompression = 0;
BmpInfoHeader.biSizeImage = 0;
BmpInfoHeader.biXPelsPerMeter = 0;
BmpInfoHeader.biYPelsPerMeter = 0;
BmpInfoHeader.biClrUsed = m_nColorTableEntries;
BmpInfoHeader.biClrImportant = m_nColorTableEntries;
//ÎļþÍ·ÐÅÏ¢
BmpHeader.bfType = 0x4D42;
BmpHeader.bfOffBits = 14 + Marshal.SizeOf(BmpInfoHeader) + BmpInfoHeader.biClrUsed * 4;
BmpHeader.bfSize = BmpHeader.bfOffBits + ((((w * BmpInfoHeader.biBitCount + 31) / 32) * 4) * BmpInfoHeader.biHeight);
BmpHeader.bfReserved1 = 0;
BmpHeader.bfReserved2 = 0;
Stream FileStream = File.Open("finger.bmp", FileMode.Create, FileAccess.Write);
BinaryWriter TmpBinaryWriter = new BinaryWriter(FileStream);
TmpBinaryWriter.Write(StructToBytes(BmpHeader, 14));
TmpBinaryWriter.Write(StructToBytes(BmpInfoHeader, Marshal.SizeOf(BmpInfoHeader)));
//µ÷ÊÔ°åÐÅÏ¢
for (ColorIndex = 0; ColorIndex < m_nColorTableEntries; ColorIndex++)
{
ColorMask[ColorIndex].redmask = (byte)ColorIndex;
ColorMask[ColorIndex].greenmask = (byte)ColorIndex;
ColorMask[ColorIndex].bluemask = (byte)ColorIndex;
ColorMask[ColorIndex].rgbReserved = 0;
TmpBinaryWriter.Write(StructToBytes(ColorMask[ColorIndex], Marshal.SizeOf(ColorMask[ColorIndex])));
}
//ͼƬÐýת£¬½â¾öÖ¸ÎÆÍ¼Æ¬µ¹Á¢µÄÎÊÌâ
RotatePic(buffer, nWidth, nHeight, ref ResBuf);
//дͼƬ
//TmpBinaryWriter.Write(ResBuf);
byte[] filter = null;
if (w - nWidth > 0)
{
filter = new byte[w - nWidth];
}
for (int i = 0; i < nHeight; i++)
{
TmpBinaryWriter.Write(ResBuf, i * nWidth, nWidth);
if (w - nWidth > 0)
{
TmpBinaryWriter.Write(ResBuf, 0, w - nWidth);
}
}
FileStream.Close();
TmpBinaryWriter.Close();
}
catch (Exception ex)
{
//ZKCE.SysException.ZKCELogger logger = new ZKCE.SysException.ZKCELogger(ex);
//logger.Append();
}
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,147 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmAddToCheckador
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.Huella1 = new System.Windows.Forms.PictureBox();
this.DdlEmpleados = new System.Windows.Forms.ComboBox();
this.Huella2 = new System.Windows.Forms.PictureBox();
this.Huella3 = new System.Windows.Forms.PictureBox();
this.LblEmpleados = new System.Windows.Forms.Label();
this.Btncapturar = new System.Windows.Forms.Button();
this.textRes = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)(this.Huella1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.Huella2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.Huella3)).BeginInit();
this.SuspendLayout();
//
// Huella1
//
this.Huella1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.Huella1.Location = new System.Drawing.Point(454, 174);
this.Huella1.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.Huella1.Name = "Huella1";
this.Huella1.Size = new System.Drawing.Size(153, 201);
this.Huella1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.Huella1.TabIndex = 8;
this.Huella1.TabStop = false;
//
// DdlEmpleados
//
this.DdlEmpleados.DisplayMember = "CodigoNombreCompleto";
this.DdlEmpleados.FormattingEnabled = true;
this.DdlEmpleados.Location = new System.Drawing.Point(302, 58);
this.DdlEmpleados.Name = "DdlEmpleados";
this.DdlEmpleados.Size = new System.Drawing.Size(446, 23);
this.DdlEmpleados.TabIndex = 9;
this.DdlEmpleados.ValueMember = "CvePersonal";
//
// Huella2
//
this.Huella2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.Huella2.Location = new System.Drawing.Point(615, 174);
this.Huella2.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.Huella2.Name = "Huella2";
this.Huella2.Size = new System.Drawing.Size(153, 201);
this.Huella2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.Huella2.TabIndex = 8;
this.Huella2.TabStop = false;
//
// Huella3
//
this.Huella3.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
this.Huella3.Location = new System.Drawing.Point(776, 174);
this.Huella3.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
this.Huella3.Name = "Huella3";
this.Huella3.Size = new System.Drawing.Size(153, 201);
this.Huella3.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.Huella3.TabIndex = 8;
this.Huella3.TabStop = false;
//
// LblEmpleados
//
this.LblEmpleados.AutoSize = true;
this.LblEmpleados.Location = new System.Drawing.Point(22, 58);
this.LblEmpleados.Name = "LblEmpleados";
this.LblEmpleados.Size = new System.Drawing.Size(142, 15);
this.LblEmpleados.TabIndex = 10;
this.LblEmpleados.Text = "Seleeccione un empleado";
//
// Btncapturar
//
this.Btncapturar.Location = new System.Drawing.Point(475, 475);
this.Btncapturar.Name = "Btncapturar";
this.Btncapturar.Size = new System.Drawing.Size(75, 23);
this.Btncapturar.TabIndex = 11;
this.Btncapturar.Text = "Aceptar";
this.Btncapturar.UseVisualStyleBackColor = true;
this.Btncapturar.Click += new System.EventHandler(this.Btncapturar_Click);
//
// textRes
//
this.textRes.Location = new System.Drawing.Point(454, 382);
this.textRes.Name = "textRes";
this.textRes.Size = new System.Drawing.Size(475, 74);
this.textRes.TabIndex = 12;
this.textRes.Text = "label1";
//
// FrmAddToCheckador
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(962, 618);
this.Controls.Add(this.textRes);
this.Controls.Add(this.Btncapturar);
this.Controls.Add(this.LblEmpleados);
this.Controls.Add(this.Huella3);
this.Controls.Add(this.Huella2);
this.Controls.Add(this.DdlEmpleados);
this.Controls.Add(this.Huella1);
this.Name = "FrmAddToCheckador";
this.Text = "FrmAddToCheckador";
this.Load += new System.EventHandler(this.FrmAddToCheckador_Load);
((System.ComponentModel.ISupportInitialize)(this.Huella1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.Huella2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.Huella3)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.ComboBox DdlEmpleados;
private System.Windows.Forms.PictureBox Huella2;
private System.Windows.Forms.PictureBox Huella3;
private System.Windows.Forms.Label LblEmpleados;
private System.Windows.Forms.Button Btncapturar;
private System.Windows.Forms.PictureBox Huella1;
private System.Windows.Forms.Label textRes;
}
}

View File

@@ -0,0 +1,298 @@
using libzkfpcsharp;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmAddToCheckador : Form
{
public FrmAddToCheckador()
{
InitializeComponent();
}
private void FrmAddToCheckador_Load(object sender, EventArgs e)
{
FormHandle = this.Handle;
//CargaChecadores();
//CargaPersonal();
initconexion();
OpenConexion();
}
private void CargaChecadores()
{
var proxi = new WCF_Checador.ChecadorServiceClient();
var checklist = proxi.GetChecadores(-1);
proxi.CloseAsync();
if (checklist != null)
{
//DGVChecadores.AutoGenerateColumns = false;
//DGVChecadores.DataSource = checklist;
}
}
private void CargaPersonal()
{
var proxi = new WCF_Checador.ChecadorServiceClient();
var checklist = proxi.GETPersonal(-1);
proxi.CloseAsync();
if (checklist != null)
{
DdlEmpleados.DataSource = checklist;
}
}
#region ADSFinger
IntPtr mDevHandle = IntPtr.Zero;
IntPtr mDBHandle = IntPtr.Zero;
IntPtr FormHandle = IntPtr.Zero;
bool bIsTimeToDie = false;
bool IsRegister = false;
bool bIdentify = true;
byte[] FPBuffer;
int RegisterCount = 0;
const int REGISTER_FINGER_COUNT = 3;
byte[][] RegTmps = new byte[3][];
byte[] RegTmp = new byte[2048];
byte[] CapTmp = new byte[2048];
int cbCapTmp = 2048;
int cbRegTmp = 0;
int iFid = 1;
private int mfpWidth = 0;
private int mfpHeight = 0;
const int MESSAGE_CAPTURED_OK = 0x0400 + 6;
[DllImport("user32.dll", EntryPoint = "SendMessageA")]
public static extern int SendMessage(IntPtr hwnd, int wMsg, IntPtr wParam, IntPtr lParam);
private void initconexion()
{
//cmbIdx.Items.Clear();
int ret = zkfperrdef.ZKFP_ERR_OK;
if ((ret = zkfp2.Init()) == zkfperrdef.ZKFP_ERR_OK)
{
int nCount = zkfp2.GetDeviceCount();
if (nCount > 0)
{
//for (int i = 0; i < nCount; i++)
//{
// cmbIdx.Items.Add(i.ToString());
//}
//cmbIdx.SelectedIndex = 0;
//bnInit.Enabled = false;
//bnFree.Enabled = true;
//bnOpen.Enabled = true;
}
else
{
zkfp2.Terminate();
MessageBox.Show("No device connected!");
}
}
else
{
MessageBox.Show("Initialize fail, ret=" + ret + " !");
}
}
DataGridView DGVChecadores;
private void OpenConexion()
{
int ret = zkfp.ZKFP_ERR_OK;
if (IntPtr.Zero == (mDevHandle = zkfp2.OpenDevice(0)))
{
MessageBox.Show("OpenDevice fail");
return;
}
if (IntPtr.Zero == (mDBHandle = zkfp2.DBInit()))
{
MessageBox.Show("Init DB fail");
zkfp2.CloseDevice(mDevHandle);
mDevHandle = IntPtr.Zero;
return;
}
RegisterCount = 0;
cbRegTmp = 0;
iFid = 1;
for (int i = 0; i < 3; i++)
{
RegTmps[i] = new byte[2048];
}
byte[] paramValue = new byte[4];
int size = 4;
zkfp2.GetParameters(mDevHandle, 1, paramValue, ref size);
zkfp2.ByteArray2Int(paramValue, ref mfpWidth);
size = 4;
zkfp2.GetParameters(mDevHandle, 2, paramValue, ref size);
zkfp2.ByteArray2Int(paramValue, ref mfpHeight);
FPBuffer = new byte[mfpWidth * mfpHeight];
Thread captureThread = new Thread(new ThreadStart(DoCapture));
captureThread.IsBackground = true;
captureThread.Start();
bIsTimeToDie = false;
textRes.Text = "Open succ";
}
private void DoCapture()
{
while (!bIsTimeToDie)
{
cbCapTmp = 2048;
int ret = zkfp2.AcquireFingerprint(mDevHandle, FPBuffer, CapTmp, ref cbCapTmp);
if (ret == zkfp.ZKFP_ERR_OK)
{
SendMessage(FormHandle, MESSAGE_CAPTURED_OK, IntPtr.Zero, IntPtr.Zero);
}
Thread.Sleep(200);
}
}
protected override void DefWndProc(ref Message m)
{
switch (m.Msg)
{
case MESSAGE_CAPTURED_OK:
{
MemoryStream ms = new MemoryStream();
BitmapFormat.GetBitmap(FPBuffer, mfpWidth, mfpHeight, ref ms);
Bitmap bmp = new Bitmap(ms);
//this.picFPImg.Image = bmp;
if (IsRegister)
{
int ret = zkfp.ZKFP_ERR_OK;
int fid = 0, score = 0;
ret = zkfp2.DBIdentify(mDBHandle, CapTmp, ref fid, ref score);
if (zkfp.ZKFP_ERR_OK == ret)
{
textRes.Text = "Huella registrada (" + fid + ")!";
return;
}
if (RegisterCount > 0 && zkfp2.DBMatch(mDBHandle, CapTmp, RegTmps[RegisterCount - 1]) <= 0)
{
textRes.Text = "Favor de ingresar 3 veces la huella";
return;
}
switch (RegisterCount)
{
case 0:
this.Huella1.Image = bmp;
break;
case 1:
this.Huella2.Image = bmp;
break;
case 2:
this.Huella3.Image = bmp;
break;
}
Array.Copy(CapTmp, RegTmps[RegisterCount], cbCapTmp);
String strBase64 = zkfp2.BlobToBase64(CapTmp, cbCapTmp);
byte[] blob = zkfp2.Base64ToBlob(strBase64);
RegisterCount++;
if (RegisterCount >= REGISTER_FINGER_COUNT)
{
RegisterCount = 0;
if (zkfp.ZKFP_ERR_OK == (ret = zkfp2.DBMerge(mDBHandle, RegTmps[0], RegTmps[1], RegTmps[2], RegTmp, ref cbRegTmp)) &&
zkfp.ZKFP_ERR_OK == (ret = zkfp2.DBAdd(mDBHandle, iFid, RegTmp)))
{
iFid++;
textRes.Text = "Su huella ha sido capturada";
}
else
{
textRes.Text = "Ocurrio un error al ingresar la huella (Codigo " + ret + ").";
}
IsRegister = false;
return;
}
else
{
textRes.Text = "favor de ingresar su huella " + (REGISTER_FINGER_COUNT - RegisterCount) + " veces mas en el lector.";
}
}
else
{
//if (cbRegTmp <= 0)
//{
// textRes.Text = "favor de registrar su huella primero!";
// return;
//}
//if (bIdentify)
//{
// int ret = zkfp.ZKFP_ERR_OK;
// int fid = 0, score = 0;
// ret = zkfp2.DBIdentify(mDBHandle, CapTmp, ref fid, ref score);
// if (zkfp.ZKFP_ERR_OK == ret)
// {
// textRes.Text = "Identify succ, fid= " + fid + ",score=" + score + "!";
// return;
// }
// else
// {
// textRes.Text = "Identify fail, ret= " + ret;
// return;
// }
//}
/* else
{
int ret = zkfp2.DBMatch(mDBHandle, CapTmp, RegTmp);
if (0 < ret)
{
textRes.Text = "Match finger succ, score=" + ret + "!";
return;
}
else
{
textRes.Text = "Match finger fail, ret= " + ret;
return;
}
}*/
}
}
break;
default:
base.DefWndProc(ref m);
break;
}
}
#endregion
private void Btncapturar_Click(object sender, EventArgs e)
{
this.Huella1.Image = null;
this.Huella2.Image = null;
this.Huella3.Image = null;
IsRegister = true;
RegisterCount = 0;
cbRegTmp = 0;
textRes.Text = "Favor de ingresar su huella 3 veces!";
}
private void FrmNewPersonalChecador_FormClosing(object sender, FormClosingEventArgs e)
{
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,144 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmAsistencia
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.dateTimePicker1 = new System.Windows.Forms.DateTimePicker();
this.dateTimePicker2 = new System.Windows.Forms.DateTimePicker();
this.button1 = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.Fecha = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Codigo = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Personal = new System.Windows.Forms.DataGridViewTextBoxColumn();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// dateTimePicker1
//
this.dateTimePicker1.Location = new System.Drawing.Point(25, 33);
this.dateTimePicker1.Name = "dateTimePicker1";
this.dateTimePicker1.Size = new System.Drawing.Size(200, 23);
this.dateTimePicker1.TabIndex = 0;
//
// dateTimePicker2
//
this.dateTimePicker2.Location = new System.Drawing.Point(257, 31);
this.dateTimePicker2.Name = "dateTimePicker2";
this.dateTimePicker2.Size = new System.Drawing.Size(200, 23);
this.dateTimePicker2.TabIndex = 1;
//
// button1
//
this.button1.Location = new System.Drawing.Point(542, 33);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 23);
this.button1.TabIndex = 2;
this.button1.Text = "Mostar";
this.button1.UseVisualStyleBackColor = true;
//
// groupBox1
//
//
// dataGridView1
//
this.dataGridView1.AllowUserToAddRows = false;
this.dataGridView1.AllowUserToDeleteRows = false;
this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Fecha,
this.Codigo,
this.Personal});
this.dataGridView1.Location = new System.Drawing.Point(0, 22);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.Size = new System.Drawing.Size(592, 237);
this.dataGridView1.TabIndex = 0;
this.dataGridView1.Text = "dataGridView1";
this.groupBox1.Controls.Add(this.dataGridView1);
this.groupBox1.Location = new System.Drawing.Point(25, 74);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(592, 265);
this.groupBox1.TabIndex = 3;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "Asistencia Pendiente de sincronizar";
//
// Fecha
//
this.Fecha.HeaderText = "Checo el";
this.Fecha.Name = "Fecha";
this.Fecha.ReadOnly = true;
this.Fecha.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// Codigo
//
this.Codigo.FillWeight = 60F;
this.Codigo.HeaderText = "codigo";
this.Codigo.Name = "Codigo";
this.Codigo.ReadOnly = true;
this.Codigo.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.Codigo.Width = 60;
//
// Personal
//
this.Personal.FillWeight = 300F;
this.Personal.HeaderText = "Personal";
this.Personal.Name = "Personal";
this.Personal.ReadOnly = true;
this.Personal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.Personal.Width = 300;
//
// FrmAsistencia
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(629, 351);
this.Controls.Add(this.groupBox1);
this.Controls.Add(this.button1);
this.Controls.Add(this.dateTimePicker2);
this.Controls.Add(this.dateTimePicker1);
this.Name = "FrmAsistencia";
this.Text = "FrmAsistencia";
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
this.groupBox1.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.DateTimePicker dateTimePicker1;
private System.Windows.Forms.DateTimePicker dateTimePicker2;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.DataGridViewTextBoxColumn Fecha;
private System.Windows.Forms.DataGridViewTextBoxColumn Codigo;
private System.Windows.Forms.DataGridViewTextBoxColumn Personal;
}
}

View File

@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmAsistencia : Form
{
public FrmAsistencia()
{
InitializeComponent();
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,219 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmBuscarPersonal
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
button1 = new System.Windows.Forms.Button();
TxtPersonal = new System.Windows.Forms.TextBox();
TxtCodigo = new System.Windows.Forms.TextBox();
gvpersonal = new System.Windows.Forms.DataGridView();
upPersonal = new System.Windows.Forms.DataGridViewCheckBoxColumn();
Codigo = new System.Windows.Forms.DataGridViewTextBoxColumn();
Personal = new System.Windows.Forms.DataGridViewTextBoxColumn();
CvePersonal = new System.Windows.Forms.DataGridViewTextBoxColumn();
btnCancelar = new System.Windows.Forms.Button();
BtnVincular = new System.Windows.Forms.Button();
ImgLoader = new System.Windows.Forms.PictureBox();
lblCodigo = new System.Windows.Forms.Label();
lblpersonal = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)gvpersonal).BeginInit();
((System.ComponentModel.ISupportInitialize)ImgLoader).BeginInit();
SuspendLayout();
//
// button1
//
button1.BackColor = System.Drawing.Color.CornflowerBlue;
button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
button1.ForeColor = System.Drawing.SystemColors.ButtonFace;
button1.Location = new System.Drawing.Point(675, 40);
button1.Name = "button1";
button1.Size = new System.Drawing.Size(36, 23);
button1.TabIndex = 26;
button1.Text = "🔎";
button1.UseVisualStyleBackColor = false;
button1.Click += button1_Click;
//
// TxtPersonal
//
TxtPersonal.Location = new System.Drawing.Point(153, 40);
TxtPersonal.Name = "TxtPersonal";
TxtPersonal.PlaceholderText = "Nombre";
TxtPersonal.Size = new System.Drawing.Size(516, 23);
TxtPersonal.TabIndex = 25;
TxtPersonal.KeyUp += TxtPersonal_KeyUp;
//
// TxtCodigo
//
TxtCodigo.Location = new System.Drawing.Point(27, 40);
TxtCodigo.Name = "TxtCodigo";
TxtCodigo.PlaceholderText = "Código";
TxtCodigo.Size = new System.Drawing.Size(100, 23);
TxtCodigo.TabIndex = 24;
TxtCodigo.KeyUp += TxtCodigo_KeyUp;
//
// gvpersonal
//
gvpersonal.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
gvpersonal.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { upPersonal, Codigo, Personal, CvePersonal });
gvpersonal.Location = new System.Drawing.Point(27, 69);
gvpersonal.Name = "gvpersonal";
gvpersonal.Size = new System.Drawing.Size(724, 313);
gvpersonal.TabIndex = 27;
gvpersonal.Text = "dataGridView1";
//
// upPersonal
//
upPersonal.FillWeight = 40F;
upPersonal.HeaderText = "";
upPersonal.Name = "upPersonal";
upPersonal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
upPersonal.Width = 40;
//
// Codigo
//
Codigo.DataPropertyName = "Codigo";
Codigo.FillWeight = 50F;
Codigo.HeaderText = "Codigo";
Codigo.Name = "Codigo";
Codigo.ReadOnly = true;
Codigo.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// Personal
//
Personal.DataPropertyName = "NombreCompleto";
Personal.FillWeight = 250F;
Personal.HeaderText = "Personal";
Personal.Name = "Personal";
Personal.ReadOnly = true;
Personal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
Personal.Width = 500;
//
// CvePersonal
//
CvePersonal.DataPropertyName = "CvePersonal";
CvePersonal.HeaderText = "CvePersonal";
CvePersonal.Name = "CvePersonal";
CvePersonal.Visible = false;
//
// btnCancelar
//
btnCancelar.BackColor = System.Drawing.Color.DimGray;
btnCancelar.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
btnCancelar.ForeColor = System.Drawing.SystemColors.Window;
btnCancelar.Location = new System.Drawing.Point(676, 388);
btnCancelar.Name = "btnCancelar";
btnCancelar.Size = new System.Drawing.Size(75, 32);
btnCancelar.TabIndex = 29;
btnCancelar.Text = "Cerrar";
btnCancelar.UseVisualStyleBackColor = false;
btnCancelar.Click += btnCancelar_Click;
//
// BtnVincular
//
BtnVincular.BackColor = System.Drawing.Color.FromArgb(43, 54, 67);
BtnVincular.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
BtnVincular.ForeColor = System.Drawing.SystemColors.ControlLightLight;
BtnVincular.Location = new System.Drawing.Point(537, 388);
BtnVincular.Name = "BtnVincular";
BtnVincular.Size = new System.Drawing.Size(108, 32);
BtnVincular.TabIndex = 28;
BtnVincular.Text = "Aceptar";
BtnVincular.UseVisualStyleBackColor = false;
BtnVincular.Click += BtnVincular_Click;
//
// ImgLoader
//
ImgLoader.Image = Properties.Resources.Loader;
ImgLoader.Location = new System.Drawing.Point(717, 40);
ImgLoader.Name = "ImgLoader";
ImgLoader.Size = new System.Drawing.Size(34, 23);
ImgLoader.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
ImgLoader.TabIndex = 30;
ImgLoader.TabStop = false;
ImgLoader.Visible = false;
//
// lblCodigo
//
lblCodigo.AutoSize = true;
lblCodigo.Location = new System.Drawing.Point(27, 9);
lblCodigo.Name = "lblCodigo";
lblCodigo.Size = new System.Drawing.Size(46, 15);
lblCodigo.TabIndex = 31;
lblCodigo.Text = "Código";
lblCodigo.Visible = false;
//
// lblpersonal
//
lblpersonal.AutoSize = true;
lblpersonal.Location = new System.Drawing.Point(153, 9);
lblpersonal.Name = "lblpersonal";
lblpersonal.Size = new System.Drawing.Size(54, 15);
lblpersonal.TabIndex = 32;
lblpersonal.Text = "Nombre ";
lblpersonal.Visible = false;
//
// FrmBuscarPersonal
//
AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
ClientSize = new System.Drawing.Size(800, 450);
Controls.Add(lblpersonal);
Controls.Add(lblCodigo);
Controls.Add(ImgLoader);
Controls.Add(btnCancelar);
Controls.Add(BtnVincular);
Controls.Add(gvpersonal);
Controls.Add(button1);
Controls.Add(TxtPersonal);
Controls.Add(TxtCodigo);
Name = "FrmBuscarPersonal";
Text = "Buscar Personal";
Load += FrmBuscarPersonal_Load;
((System.ComponentModel.ISupportInitialize)gvpersonal).EndInit();
((System.ComponentModel.ISupportInitialize)ImgLoader).EndInit();
ResumeLayout(false);
PerformLayout();
}
#endregion
private System.Windows.Forms.Button button1;
private System.Windows.Forms.TextBox TxtPersonal;
private System.Windows.Forms.TextBox TxtCodigo;
private System.Windows.Forms.DataGridView gvpersonal;
private System.Windows.Forms.Button btnCancelar;
private System.Windows.Forms.Button BtnVincular;
private System.Windows.Forms.DataGridViewCheckBoxColumn upPersonal;
private System.Windows.Forms.DataGridViewTextBoxColumn Codigo;
private System.Windows.Forms.DataGridViewTextBoxColumn Personal;
private System.Windows.Forms.DataGridViewTextBoxColumn CvePersonal;
private System.Windows.Forms.PictureBox ImgLoader;
private System.Windows.Forms.Label lblCodigo;
private System.Windows.Forms.Label lblpersonal;
}
}

View File

@@ -0,0 +1,181 @@
using ADSNetLibrary.Helpers.Conexiones.ZkTeckoLib;
using ADSUtileriasWF.Helpers;
using ADSUtileriasWF.Views.RelojChecador.Gluyas;
using DocumentFormat.OpenXml.Wordprocessing;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Windows.Interop;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmBuscarPersonal : Form
{
List<UtileriasServiceWCF.PersonalsqliteModel> empleados;
public FrmNewPersonalChecador frmNewPersonalChecador;
public FrmBuscarPersonal()
{
InitializeComponent();
gvpersonal.AllowUserToAddRows = false;
gvpersonal.RowHeadersVisible = false;
gvpersonal.AutoGenerateColumns = false;
}
private void FrmBuscarPersonal_Load(object sender, EventArgs e)
{
var Recorrer = 50;
lblpersonal.Location = new Point(TxtPersonal.Location.X, TxtPersonal.Location.Y - Recorrer);
lblCodigo.Location = new Point(TxtCodigo.Location.X, TxtCodigo.Location.Y - Recorrer);
}
private void button1_Click(object sender, EventArgs e)
{
ImgLoader.Visible = true;
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(CargaPersonal);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
private void CargaPersonal()
{
empleados = Servicecon.GETPersonal(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), ModVarsPV.UserV2.CveEmpresa.ToString().ToEntero(), -1);
if (empleados != null)
{
empleados = empleados.Where(x => (string.IsNullOrEmpty(TxtCodigo.Text) || (x.Codigo != null && x.Codigo.Contains(TxtCodigo.Text, StringComparison.OrdinalIgnoreCase))) &&
(string.IsNullOrEmpty(TxtPersonal.Text) || (x.NombreCompleto != null && x.NombreCompleto.Contains(TxtPersonal.Text, StringComparison.OrdinalIgnoreCase)))
).ToList();
this.Invoke((MethodInvoker)delegate
{
try
{
gvpersonal.DataSource = ToDataTable(empleados);
}
catch (Exception)
{
}
});
}
else
{
this.Invoke((MethodInvoker)delegate
{
try
{
gvpersonal.DataSource = new DataTable();
}
catch (Exception)
{
}
});
}
this.Invoke((MethodInvoker)delegate
{
try
{
ImgLoader.Visible = false;
}
catch (Exception)
{
}
});
}
private void btnCancelar_Click(object sender, EventArgs e)
{
this.Close();
}
private void BtnVincular_Click(object sender, EventArgs e)
{
this.Invoke((MethodInvoker)delegate
{
ImgLoader.Visible = true;
});
int CvePersonal = 0;
foreach (DataGridViewRow row in gvpersonal.Rows)
{
DataGridViewCheckBoxCell chk = (DataGridViewCheckBoxCell)(row.Cells[0]);
if (!(chk.Value == chk.FalseValue || chk.Value == null))
{
CvePersonal = row.Cells["CvePersonal"].Value.ToString().ToEntero();
frmNewPersonalChecador.AddPersonal(empleados.FirstOrDefault(x => x.CvePersonal == CvePersonal));
break;
}
}
this.Invoke((MethodInvoker)delegate
{
ImgLoader.Visible = false;
});
if (CvePersonal == 0)
ModExtensiones.Alert("Seleccione un empleado", "Información", MessageBoxButtons.OK);
else
this.Close();
}
private void TxtCodigo_KeyUp(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
{
ImgLoader.Visible = true;
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(CargaPersonal);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
}
private void TxtPersonal_KeyUp(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
{
ImgLoader.Visible = true;
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(CargaPersonal);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
}
public static DataTable ToDataTable<T>(List<T> items)
{
var dt = new DataTable(typeof(T).Name);
var props = typeof(T).GetProperties();
foreach (var prop in props)
dt.Columns.Add(prop.Name, Nullable.GetUnderlyingType(prop.PropertyType) ?? prop.PropertyType);
foreach (var item in items)
{
var values = new object[props.Length];
for (int i = 0; i < props.Length; i++)
values[i] = props[i].GetValue(item) ?? DBNull.Value;
dt.Rows.Add(values);
}
return dt;
}
}
}

View File

@@ -0,0 +1,123 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="CvePersonal.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>

View File

@@ -0,0 +1,232 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmCambiarEmpresa
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.DtGVEmpresa = new System.Windows.Forms.DataGridView();
this.CveEmpresa = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Empresa = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.LblTitulo = new System.Windows.Forms.Label();
this.Btnok = new System.Windows.Forms.Button();
this.BtnCancel = new System.Windows.Forms.Button();
this.BtnMinimize = new FontAwesome.Sharp.IconButton();
this.BtnMaximizeRestore = new FontAwesome.Sharp.IconButton();
this.BtnClose = new FontAwesome.Sharp.IconButton();
this.panel1 = new System.Windows.Forms.Panel();
this.LblFrmTitulo = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)(this.DtGVEmpresa)).BeginInit();
this.panel1.SuspendLayout();
this.SuspendLayout();
//
// DtGVEmpresa
//
this.DtGVEmpresa.AllowUserToAddRows = false;
this.DtGVEmpresa.AllowUserToDeleteRows = false;
this.DtGVEmpresa.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DtGVEmpresa.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
this.DtGVEmpresa.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.DtGVEmpresa.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.CveEmpresa,
this.Empresa});
this.DtGVEmpresa.Location = new System.Drawing.Point(12, 80);
this.DtGVEmpresa.Name = "DtGVEmpresa";
this.DtGVEmpresa.AutoGenerateColumns = false;
this.DtGVEmpresa.RowHeadersVisible = false;
this.DtGVEmpresa.RowTemplate.Height = 25;
this.DtGVEmpresa.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
this.DtGVEmpresa.Size = new System.Drawing.Size(410, 216);
this.DtGVEmpresa.TabIndex = 9;
//
// CveEmpresa
//
this.CveEmpresa.DataPropertyName = "CveEmpresa";
this.CveEmpresa.HeaderText = "CveEmpresa";
this.CveEmpresa.Name = "CveEmpresa";
this.CveEmpresa.ReadOnly = true;
this.CveEmpresa.Visible = false;
//
// Empresa
//
this.Empresa.DataPropertyName = "Empresa";
this.Empresa.HeaderText = "Empresa";
this.Empresa.Name = "Empresa";
this.Empresa.ReadOnly = true;
//
// LblTitulo
//
this.LblTitulo.AutoSize = true;
this.LblTitulo.Location = new System.Drawing.Point(15, 50);
this.LblTitulo.Name = "LblTitulo";
this.LblTitulo.Size = new System.Drawing.Size(134, 15);
this.LblTitulo.TabIndex = 8;
this.LblTitulo.Text = "Seleccione una empresa";
this.LblTitulo.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
// Btnok
//
this.Btnok.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.Btnok.Location = new System.Drawing.Point(227, 321);
this.Btnok.Name = "Btnok";
this.Btnok.Size = new System.Drawing.Size(94, 35);
this.Btnok.TabIndex = 6;
this.Btnok.Text = "OK";
this.Btnok.UseVisualStyleBackColor = true;
this.Btnok.Click += new System.EventHandler(this.BtnOK_Click);
//
// BtnCancel
//
this.BtnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.BtnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.BtnCancel.Location = new System.Drawing.Point(327, 321);
this.BtnCancel.Name = "BtnCancel";
this.BtnCancel.Size = new System.Drawing.Size(94, 35);
this.BtnCancel.TabIndex = 7;
this.BtnCancel.Text = "Cancel";
this.BtnCancel.UseVisualStyleBackColor = true;
this.BtnCancel.Click += new System.EventHandler(this.BtnCancel_Click);
//
// BtnMinimize
//
this.BtnMinimize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMinimize.FlatAppearance.BorderSize = 0;
this.BtnMinimize.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMinimize.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMinimize.IconChar = FontAwesome.Sharp.IconChar.WindowMinimize;
this.BtnMinimize.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMinimize.IconSize = 20;
this.BtnMinimize.Location = new System.Drawing.Point(343, 1);
this.BtnMinimize.Name = "BtnMinimize";
this.BtnMinimize.Rotation = 0D;
this.BtnMinimize.Size = new System.Drawing.Size(30, 28);
this.BtnMinimize.TabIndex = 0;
this.BtnMinimize.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMinimize.UseVisualStyleBackColor = true;
this.BtnMinimize.Click += new System.EventHandler(this.BtnMinimize_Click_1);
//
// BtnMaximizeRestore
//
this.BtnMaximizeRestore.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMaximizeRestore.FlatAppearance.BorderSize = 0;
this.BtnMaximizeRestore.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMaximizeRestore.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMaximizeRestore.IconChar = FontAwesome.Sharp.IconChar.WindowMaximize;
this.BtnMaximizeRestore.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMaximizeRestore.IconSize = 20;
this.BtnMaximizeRestore.Location = new System.Drawing.Point(373, 1);
this.BtnMaximizeRestore.Name = "BtnMaximizeRestore";
this.BtnMaximizeRestore.Rotation = 0D;
this.BtnMaximizeRestore.Size = new System.Drawing.Size(30, 28);
this.BtnMaximizeRestore.TabIndex = 0;
this.BtnMaximizeRestore.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMaximizeRestore.UseVisualStyleBackColor = true;
this.BtnMaximizeRestore.Click += new System.EventHandler(this.BtnMaximizeRestore_Click_1);
//
// BtnClose
//
this.BtnClose.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnClose.FlatAppearance.BorderSize = 0;
this.BtnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnClose.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnClose.IconChar = FontAwesome.Sharp.IconChar.Times;
this.BtnClose.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnClose.IconSize = 20;
this.BtnClose.Location = new System.Drawing.Point(403, 1);
this.BtnClose.Name = "BtnClose";
this.BtnClose.Rotation = 0D;
this.BtnClose.Size = new System.Drawing.Size(30, 28);
this.BtnClose.TabIndex = 0;
this.BtnClose.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnClose.UseVisualStyleBackColor = true;
this.BtnClose.Click += new System.EventHandler(this.BtnClose_Click_1);
//
// panel1
//
this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.panel1.Controls.Add(this.LblFrmTitulo);
this.panel1.Controls.Add(this.BtnMinimize);
this.panel1.Controls.Add(this.BtnMaximizeRestore);
this.panel1.Controls.Add(this.BtnClose);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(434, 30);
this.panel1.TabIndex = 1;
this.panel1.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// LblFrmTitulo
//
this.LblFrmTitulo.AutoSize = true;
this.LblFrmTitulo.Font = new System.Drawing.Font("Open Sans", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point);
this.LblFrmTitulo.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblFrmTitulo.Location = new System.Drawing.Point(15, 5);
this.LblFrmTitulo.Name = "LblFrmTitulo";
this.LblFrmTitulo.Size = new System.Drawing.Size(160, 22);
this.LblFrmTitulo.TabIndex = 1;
this.LblFrmTitulo.Text = "Cambiar empresa";
//
// FrmCambiarEmpresa
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(434, 373);
this.ControlBox = false;
this.Controls.Add(this.DtGVEmpresa);
this.Controls.Add(this.panel1);
this.Controls.Add(this.BtnCancel);
this.Controls.Add(this.Btnok);
this.Controls.Add(this.LblTitulo);
this.MinimumSize = new System.Drawing.Size(450, 225);
this.Name = "FrmCambiarEmpresa";
this.ShowIcon = false;
this.ShowInTaskbar = false;
this.Load += new System.EventHandler(this.FrmCambiarEmpresa_Load);
((System.ComponentModel.ISupportInitialize)(this.DtGVEmpresa)).EndInit();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label LblTitulo;
private System.Windows.Forms.Button Btnok;
private System.Windows.Forms.Button BtnCancel;
private FontAwesome.Sharp.IconButton iconButton1;
private FontAwesome.Sharp.IconButton BtnMaximizeRestore;
private FontAwesome.Sharp.IconButton BtnClose;
private System.Windows.Forms.Panel panel1;
private FontAwesome.Sharp.IconButton BtnMinimize;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label LblFrmTitulo;
private System.Windows.Forms.DataGridView DtGVEmpresa;
private System.Windows.Forms.DataGridViewTextBoxColumn CveEmpresa;
private System.Windows.Forms.DataGridViewTextBoxColumn Empresa;
}
}

View File

@@ -0,0 +1,90 @@
using ADSUtileriasWF.Helpers;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmCambiarEmpresa : FormBase
{
public FrmCambiarEmpresa()
{
InitializeComponent();
}
private void BtnCancel_Click(object sender, EventArgs e)
{
this.DialogResult = System.Windows.Forms.DialogResult.Abort;
this.Close();
}
private void BtnOK_Click(object sender, EventArgs e)
{
int _CveEmpresa = 0;
string empresa = ModVarsPV.UserV2.Empresa;
int selectedRowCount = DtGVEmpresa.Rows.GetRowCount(DataGridViewElementStates.Selected);
if (selectedRowCount > 0)
{
_CveEmpresa = DtGVEmpresa.SelectedRows[0].Cells["CveEmpresa"].Value.ToString().ToEntero();
empresa = DtGVEmpresa.SelectedRows[0].Cells["Empresa"].Value.ToString();
}
if (_CveEmpresa > 0)
{
var user = Servicecon.CambiarEmpresa(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), _CveEmpresa, -1);
if (user != null)
{
ModVarsPV.UserV2.CveEmpresa = _CveEmpresa;
ModVarsPV.UserV2.Empresa = empresa;
ModVarsPV.UserV2.CveSubProyecto = user.cveSubProyecto;
this.DialogResult = System.Windows.Forms.DialogResult.OK;
this.Close();
}
else
{
MessageBox.Show("no se pudo realizar el cambio de empresa.");
}
}
else
{
MessageBox.Show("Debe seleccionar una empresa para continuar.");
}
}
private void BtnClose_Click_1(object sender, EventArgs e)
{
this.Close();
}
private void BtnMaximizeRestore_Click_1(object sender, EventArgs e)
{
BtnMaximizeRestore_Click(sender, e);
}
private void BtnMinimize_Click_1(object sender, EventArgs e)
{
BtnMinimize_Click(sender, e);
}
private void FrmCambiarEmpresa_Load(object sender, EventArgs e)
{
List<UtileriasServiceWCF.UsuarioEmpresa> empresas = new List<UtileriasServiceWCF.UsuarioEmpresa>();//.Select(m => new { m.CveEmpresa, m.Empresa }).Distinct().Select(x => new UtileriasServiceWCF.UsuarioEmpresa { CveEmpresa=x.CveEmpresa, Empresa=x.Empresa });
empresas.Add(ModVarsPV.UserV2.UsuarioEmpresas.FirstOrDefault(x => x.CveEmpresa == ModVarsPV.UserV2.CveEmpresa));
foreach (var item in ModVarsPV.UserV2.UsuarioEmpresas)
{
if (empresas.FirstOrDefault(x => x.CveEmpresa == item.CveEmpresa) == null)
{ empresas.Add(item); }
}
DtGVEmpresa.DataSource = empresas;
DtGVEmpresa.Refresh();
}
}
}

View File

@@ -0,0 +1,66 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="CveEmpresa.UserAddedColumn" type="System.Boolean, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
<value>True</value>
</metadata>
<metadata name="Empresa.UserAddedColumn" type="System.Boolean, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
<value>True</value>
</metadata>
</root>

View File

@@ -0,0 +1,263 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmChecadores
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.LblChecador = new System.Windows.Forms.Label();
this.DdlChecador = new System.Windows.Forms.ComboBox();
this.Getchecadores = new FontAwesome.Sharp.IconButton();
this.iconButton1 = new FontAwesome.Sharp.IconButton();
this.GrpBoxEmpleados = new System.Windows.Forms.GroupBox();
this.GVEmpleadosCheck = new System.Windows.Forms.DataGridView();
this.checadorID = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.CvePersonal = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Codigo = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.NombreCompleto = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.NombreChecador = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Huella = new System.Windows.Forms.DataGridViewButtonColumn();
this.BtnVincular = new FontAwesome.Sharp.IconButton();
((System.ComponentModel.ISupportInitialize)(this.GVEmpleadosCheck)).BeginInit();
this.GrpBoxEmpleados.SuspendLayout();
this.SuspendLayout();
//
// LblChecador
//
this.LblChecador.AutoSize = true;
this.LblChecador.Font = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblChecador.Location = new System.Drawing.Point(23, 9);
this.LblChecador.Name = "LblChecador";
this.LblChecador.Size = new System.Drawing.Size(172, 21);
this.LblChecador.TabIndex = 1;
this.LblChecador.Text = "Seleccione un checador";
//
// DdlChecador
//
this.DdlChecador.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DdlChecador.Font = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.DdlChecador.FormattingEnabled = true;
this.DdlChecador.Location = new System.Drawing.Point(201, 6);
this.DdlChecador.Name = "DdlChecador";
this.DdlChecador.Size = new System.Drawing.Size(420, 29);
this.DdlChecador.TabIndex = 2;
//
// Getchecadores
//
this.Getchecadores.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.Getchecadores.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.Getchecadores.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.Getchecadores.Font = new System.Drawing.Font("Segoe UI", 3F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.Getchecadores.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.Getchecadores.IconChar = FontAwesome.Sharp.IconChar.SyncAlt;
this.Getchecadores.IconColor = System.Drawing.Color.White;
this.Getchecadores.IconSize = 16;
this.Getchecadores.Location = new System.Drawing.Point(688, 9);
this.Getchecadores.Margin = new System.Windows.Forms.Padding(0);
this.Getchecadores.Name = "Getchecadores";
this.Getchecadores.Rotation = 0D;
this.Getchecadores.Size = new System.Drawing.Size(38, 30);
this.Getchecadores.TabIndex = 3;
this.Getchecadores.UseVisualStyleBackColor = false;
this.Getchecadores.Visible = false;
//
// iconButton1
//
this.iconButton1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.iconButton1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.iconButton1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.iconButton1.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.iconButton1.Font = new System.Drawing.Font("Segoe UI", 3F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.iconButton1.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.iconButton1.IconChar = FontAwesome.Sharp.IconChar.Check;
this.iconButton1.IconColor = System.Drawing.Color.White;
this.iconButton1.IconSize = 16;
this.iconButton1.Location = new System.Drawing.Point(635, 9);
this.iconButton1.Margin = new System.Windows.Forms.Padding(0);
this.iconButton1.Name = "iconButton1";
this.iconButton1.Rotation = 0D;
this.iconButton1.Size = new System.Drawing.Size(38, 30);
this.iconButton1.TabIndex = 3;
this.iconButton1.UseVisualStyleBackColor = false;
this.iconButton1.Click += new System.EventHandler(this.iconButton1_Click);
//
// GrpBoxEmpleados
//
this.GrpBoxEmpleados.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
//
// GVEmpleadosCheck
//
this.GVEmpleadosCheck.AllowUserToAddRows = false;
this.GVEmpleadosCheck.AllowUserToDeleteRows = false;
this.GVEmpleadosCheck.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.GVEmpleadosCheck.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.GVEmpleadosCheck.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.GVEmpleadosCheck.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.checadorID,
this.CvePersonal,
this.Codigo,
this.NombreCompleto,
this.NombreChecador,
this.Huella});
this.GVEmpleadosCheck.Location = new System.Drawing.Point(6, 22);
this.GVEmpleadosCheck.MultiSelect = false;
this.GVEmpleadosCheck.Name = "GVEmpleadosCheck";
this.GVEmpleadosCheck.ReadOnly = true;
this.GVEmpleadosCheck.RowHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.None;
this.GVEmpleadosCheck.RowHeadersVisible = false;
this.GVEmpleadosCheck.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
this.GVEmpleadosCheck.Size = new System.Drawing.Size(697, 322);
this.GVEmpleadosCheck.TabIndex = 0;
this.GVEmpleadosCheck.Text = "dataGridView1";
this.GVEmpleadosCheck.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.GVEmpleadosCheck_CellContentClick);
this.GVEmpleadosCheck.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.GVEmpleadosCheck_CellDoubleClick);
this.GrpBoxEmpleados.Controls.Add(this.GVEmpleadosCheck);
this.GrpBoxEmpleados.Location = new System.Drawing.Point(23, 65);
this.GrpBoxEmpleados.Name = "GrpBoxEmpleados";
this.GrpBoxEmpleados.Size = new System.Drawing.Size(703, 350);
this.GrpBoxEmpleados.TabIndex = 4;
this.GrpBoxEmpleados.TabStop = false;
this.GrpBoxEmpleados.Text = "Empleados";
//
// checadorID
//
this.checadorID.DataPropertyName = "checadorID";
this.checadorID.FillWeight = 30.38718F;
this.checadorID.HeaderText = "ID";
this.checadorID.Name = "checadorID";
this.checadorID.ReadOnly = true;
this.checadorID.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// CvePersonal
//
this.CvePersonal.DataPropertyName = "CvePersonal";
this.CvePersonal.HeaderText = "CvePersonal";
this.CvePersonal.Name = "CvePersonal";
this.CvePersonal.ReadOnly = true;
this.CvePersonal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.CvePersonal.Visible = false;
//
// Codigo
//
this.Codigo.DataPropertyName = "Codigo";
this.Codigo.FillWeight = 36.46462F;
this.Codigo.HeaderText = "Codigo";
this.Codigo.Name = "Codigo";
this.Codigo.ReadOnly = true;
this.Codigo.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// NombreCompleto
//
this.NombreCompleto.DataPropertyName = "NombreCompleto";
this.NombreCompleto.FillWeight = 121.5487F;
this.NombreCompleto.HeaderText = "Nombre";
this.NombreCompleto.Name = "NombreCompleto";
this.NombreCompleto.ReadOnly = true;
this.NombreCompleto.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// NombreChecador
//
this.NombreChecador.DataPropertyName = "NombreChecador";
this.NombreChecador.FillWeight = 121.5487F;
this.NombreChecador.HeaderText = "Checador";
this.NombreChecador.Name = "NombreChecador";
this.NombreChecador.ReadOnly = true;
this.NombreChecador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// Huella
//
this.Huella.FillWeight = 25F;
this.Huella.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.Huella.HeaderText = "huella";
this.Huella.Name = "Huella";
this.Huella.ReadOnly = true;
this.Huella.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.Huella.Text = "Agregar";
//
// BtnVincular
//
this.BtnVincular.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.BtnVincular.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.BtnVincular.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnVincular.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnVincular.Font = new System.Drawing.Font("Segoe UI", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnVincular.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnVincular.IconChar = FontAwesome.Sharp.IconChar.Check;
this.BtnVincular.IconColor = System.Drawing.Color.White;
this.BtnVincular.IconSize = 16;
this.BtnVincular.Location = new System.Drawing.Point(579, 418);
this.BtnVincular.Margin = new System.Windows.Forms.Padding(0);
this.BtnVincular.Name = "BtnVincular";
this.BtnVincular.Rotation = 0D;
this.BtnVincular.Size = new System.Drawing.Size(147, 30);
this.BtnVincular.TabIndex = 3;
this.BtnVincular.Text = "Aplicar cambios";
this.BtnVincular.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnVincular.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnVincular.UseVisualStyleBackColor = false;
this.BtnVincular.Click += new System.EventHandler(this.BtnVincular_Click);
//
// FrmChecadores
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(750, 457);
this.Controls.Add(this.BtnVincular);
this.Controls.Add(this.GrpBoxEmpleados);
this.Controls.Add(this.iconButton1);
this.Controls.Add(this.Getchecadores);
this.Controls.Add(this.DdlChecador);
this.Controls.Add(this.LblChecador);
this.Name = "FrmChecadores";
this.Text = "FrmChecadores";
((System.ComponentModel.ISupportInitialize)(this.GVEmpleadosCheck)).EndInit();
this.GrpBoxEmpleados.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label LblChecador;
private System.Windows.Forms.ComboBox DdlChecador;
private FontAwesome.Sharp.IconButton Getchecadores;
private FontAwesome.Sharp.IconButton iconButton1;
private System.Windows.Forms.GroupBox GrpBoxEmpleados;
private System.Windows.Forms.DataGridView GVEmpleadosCheck;
private FontAwesome.Sharp.IconButton BtnVincular;
private System.Windows.Forms.DataGridViewTextBoxColumn checadorID;
private System.Windows.Forms.DataGridViewTextBoxColumn CvePersonal;
private System.Windows.Forms.DataGridViewTextBoxColumn Codigo;
private System.Windows.Forms.DataGridViewTextBoxColumn NombreCompleto;
private System.Windows.Forms.DataGridViewTextBoxColumn NombreChecador;
private System.Windows.Forms.DataGridViewButtonColumn Huella;
}
}

View File

@@ -0,0 +1,240 @@
using ADSUtileriasWF.Helpers;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmChecadores : Form
{
DataTable dt;
List<WCF_Checador.PersonalChecador> empleadoschecador;
List<WCF_Checador.PersonalChecador> empleadoschecadorDisponible;
WCF_Checador.ResponseGetPersonal[] empleados;
public int cvePersonal; int cveChecador; int maxchecadorID = 1;
public int GetNextmaxchecadorID()
{
while (empleadoschecador.FirstOrDefault(t => t.IdPersonal.ToEntero() == maxchecadorID) != null)
{
maxchecadorID++;
}
return maxchecadorID;
}
Form1 frmvinculo;
public FrmChecadores()
{
InitializeComponent();
CargaChecadores();
initdt();
frmvinculo = new Form1();
}
public void initdt()
{
dt = new DataTable();
dt.Clear();
dt.Columns.Add("checadorID");
dt.Columns.Add("CvePersonal");
dt.Columns.Add("Codigo");
dt.Columns.Add("NombreCompleto");
dt.Columns.Add("NombreChecador");
}
private void CargaChecadores()
{
var proxi = new WCF_Checador.ChecadorServiceClient();
var checklist = proxi.GetChecadores(-1);
proxi.CloseAsync();
if (checklist != null)
{
DdlChecador.ValueMember = "cveChecador";
DdlChecador.DisplayMember = "checador";
DdlChecador.DataSource = checklist;
}
}
private void iconButton1_Click(object sender, EventArgs e)
{
cveChecador = DdlChecador.SelectedValue.ToString().ToEntero();
var proxi = new WCF_Checador.ChecadorServiceClient();
empleadoschecador = proxi.GetChecadorEmpleado(cveChecador).ToList();
/*
empleadoschecador = new WCF_Checador.PersonalChecador[] { new WCF_Checador.PersonalChecador() { IdPersonal ="1",Nombre="Jose"} ,
new WCF_Checador.PersonalChecador() { IdPersonal ="2",Nombre="Julian"} ,
new WCF_Checador.PersonalChecador() { IdPersonal ="3",Nombre="alba Sandobal"},
new WCF_Checador.PersonalChecador() { IdPersonal ="4",Nombre="Paola castillo"},
new WCF_Checador.PersonalChecador() { IdPersonal ="5",Nombre="Luisa esperanza"} ,
new WCF_Checador.PersonalChecador() { IdPersonal ="6",Nombre="rene Molina"} }.ToList();
*/
empleadoschecadorDisponible = empleadoschecador.ToList();
empleados = proxi.GETPersonal(-1);
dt.Rows.Clear();
if (empleados != null)
{
foreach (WCF_Checador.ResponseGetPersonal per in empleados)
{
DataRow drow = dt.NewRow();
drow["checadorID"] = per.checadorID;
drow["CvePersonal"] = per.CvePersonal;
drow["Codigo"] = per.Codigo;
drow["NombreCompleto"] = per.NombreCompleto;
if (empleadoschecador != null)
{
if (per.checadorID > 0)
{
var perchek = empleadoschecadorDisponible.FirstOrDefault(t => t.IdPersonal.ToEntero() == per.checadorID);
if (perchek != null)
{
empleadoschecadorDisponible.Remove(perchek);
drow["NombreChecador"] = perchek.Nombre;
}
}
}
dt.Rows.Add(drow);
}
}
GVEmpleadosCheck.AutoGenerateColumns = false;
GVEmpleadosCheck.DataSource = dt;
GVEmpleadosCheck.Refresh();
//GVEmpleadosCheck.datab
}
private void GVEmpleadosCheck_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
{
if (e.RowIndex >= 0 && e.ColumnIndex == 4)
{
cvePersonal = GVEmpleadosCheck.Rows[e.RowIndex].Cells["CvePersonal"].Value.ToString().ToEntero();
int checadorID = GVEmpleadosCheck.Rows[e.RowIndex].Cells["checadorID"].Value.ToString().ToEntero();
string nombre = string.Format("{0} {1}",
GVEmpleadosCheck.Rows[e.RowIndex].Cells["Codigo"].Value.ToString(),
GVEmpleadosCheck.Rows[e.RowIndex].Cells["NombreCompleto"].Value.ToString());
using (FrmPersonalChecador frmvinculo = new FrmPersonalChecador(cvePersonal, checadorID, nombre, empleadoschecadorDisponible))
{
DialogResult result = frmvinculo.ShowDialog();
if (result == System.Windows.Forms.DialogResult.OK)
{
if (frmvinculo.checadorID == -1)
{
frmvinculo.checadorID = GetNextmaxchecadorID();
WCF_Checador.PersonalChecador empchecador = new WCF_Checador.PersonalChecador() { IdPersonal = frmvinculo.checadorID.ToString(), Nombre = GVEmpleadosCheck.Rows[e.RowIndex].Cells["NombreCompleto"].Value.ToString(), Activo = true, Password = "", Privilege = 0 };
try
{
var proxi = new WCF_Checador.ChecadorServiceClient();
proxi.AddChecadorEmpleado(cveChecador, empchecador, CvePersonal.ToString());
}
catch (Exception)
{
}
empleadoschecador.Add(empchecador);
}
empleadoschecadorDisponible = empleadoschecador.ToList();
if (empleados != null)
{
foreach (WCF_Checador.ResponseGetPersonal per in empleados)
{
if (per.checadorID == frmvinculo.checadorID)
{
per.checadorID = 0;
per.cveChecador = 0;
}
if (per.CvePersonal == frmvinculo.cvePersonal)
{
per.checadorID = frmvinculo.checadorID;
per.cveChecador = cveChecador;
}
}
dt.Rows.Clear();
foreach (WCF_Checador.ResponseGetPersonal per in empleados)
{
DataRow drow = dt.NewRow();
drow["checadorID"] = per.checadorID;
drow["CvePersonal"] = per.CvePersonal;
drow["Codigo"] = per.Codigo;
drow["NombreCompleto"] = per.NombreCompleto;
if (empleadoschecador != null)
{
if (per.checadorID > 0)
{
var perchek = empleadoschecadorDisponible.FirstOrDefault(t => t.IdPersonal.ToEntero() == per.checadorID);
if (perchek != null)
{
empleadoschecadorDisponible.Remove(perchek);
drow["NombreChecador"] = perchek.Nombre;
}
}
}
dt.Rows.Add(drow);
}
GVEmpleadosCheck.DataSource = dt;
}
}
}
//CargaCuenta(false);
//if (tCveEstatusFactura != 2)
//{
// //ReAbrirCuenta();
//}
//else
//{
// MessageBox.Show("Esta Cuenta ya esta Cerrada y no se puede agregrar mas Productos");
//}
}
}
private void BtnVincular_Click(object sender, EventArgs e)
{
var proxi = new WCF_Checador.ChecadorServiceClient();
List<WCF_Checador.RequestPersonalChecadorUp> empup = new List<WCF_Checador.RequestPersonalChecadorUp>();
foreach (var item in empleados)
{
empup.Add(new WCF_Checador.RequestPersonalChecadorUp() { CvePersonal = item.CvePersonal.ToString().ToEntero(), cveChecador = item.cveChecador, checadorID = item.checadorID });
if (empup.Count > 50)
{
proxi.SetPersonalChecador(empup.ToArray());
empup.Clear();
}
}
if (empup.Count > 0)
{
proxi.SetPersonalChecador(empup.ToArray());
empup.Clear();
}
ModExtensiones.Alert("El personal se ha vinculado correctamente.", "Información", MessageBoxButtons.OK);
}
private void GVEmpleadosCheck_CellContentClick(object sender, DataGridViewCellEventArgs e)
{
var senderGrid = (DataGridView)sender;
if (senderGrid.Columns[e.ColumnIndex] is DataGridViewButtonColumn && e.RowIndex >= 0 && e.ColumnIndex == 5)
{
//TODO - Button Clicked - Execute Code Here
frmvinculo.bnEnroll_Click(null, null);
frmvinculo.Show();
}
}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,182 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmConfiguracion
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
this.DdlSubProyecto = new System.Windows.Forms.ComboBox();
this.label2 = new System.Windows.Forms.Label();
this.BtnAceptar = new FontAwesome.Sharp.IconButton();
this.DtgvSubProyectos = new System.Windows.Forms.DataGridView();
this.IsCheked = new System.Windows.Forms.DataGridViewCheckBoxColumn();
this.CveSubProyecto = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.SubProyecto = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.ImgLoader = new System.Windows.Forms.PictureBox();
((System.ComponentModel.ISupportInitialize)(this.DtgvSubProyectos)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.ImgLoader)).BeginInit();
this.SuspendLayout();
//
// DdlSubProyecto
//
this.DdlSubProyecto.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DdlSubProyecto.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
this.DdlSubProyecto.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
this.DdlSubProyecto.DisplayMember = "SubProyecto";
this.DdlSubProyecto.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.DdlSubProyecto.FormattingEnabled = true;
this.DdlSubProyecto.Location = new System.Drawing.Point(12, 72);
this.DdlSubProyecto.Name = "DdlSubProyecto";
this.DdlSubProyecto.Size = new System.Drawing.Size(766, 23);
this.DdlSubProyecto.TabIndex = 2;
this.DdlSubProyecto.Tag = "SubProyecto";
this.DdlSubProyecto.ValueMember = "CveSubProyecto";
this.DdlSubProyecto.SelectedIndexChanged += new System.EventHandler(this.DdlSubProyecto_SelectedIndexChanged);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(12, 42);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(96, 15);
this.label2.TabIndex = 3;
this.label2.Text = "Centro de costos";
//
// BtnAceptar
//
this.BtnAceptar.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.BtnAceptar.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnAceptar.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnAceptar.ForeColor = System.Drawing.SystemColors.ButtonHighlight;
this.BtnAceptar.IconChar = FontAwesome.Sharp.IconChar.Save;
this.BtnAceptar.IconColor = System.Drawing.Color.White;
this.BtnAceptar.IconSize = 32;
this.BtnAceptar.Location = new System.Drawing.Point(658, 388);
this.BtnAceptar.Name = "BtnAceptar";
this.BtnAceptar.Rotation = 0D;
this.BtnAceptar.Size = new System.Drawing.Size(118, 50);
this.BtnAceptar.TabIndex = 5;
this.BtnAceptar.Text = "Guardar";
this.BtnAceptar.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnAceptar.UseVisualStyleBackColor = false;
this.BtnAceptar.Click += new System.EventHandler(this.BtnAceptar_Click);
//
// DtgvSubProyectos
//
this.DtgvSubProyectos.AllowUserToAddRows = false;
this.DtgvSubProyectos.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DtgvSubProyectos.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DtgvSubProyectos.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText;
dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
this.DtgvSubProyectos.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2;
this.DtgvSubProyectos.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.DtgvSubProyectos.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.IsCheked,
this.CveSubProyecto,
this.SubProyecto});
this.DtgvSubProyectos.Location = new System.Drawing.Point(12, 110);
this.DtgvSubProyectos.Name = "DtgvSubProyectos";
this.DtgvSubProyectos.ReadOnly = true;
this.DtgvSubProyectos.RowHeadersVisible = false;
this.DtgvSubProyectos.RowTemplate.Height = 25;
this.DtgvSubProyectos.Size = new System.Drawing.Size(766, 103);
this.DtgvSubProyectos.TabIndex = 6;
this.DtgvSubProyectos.Visible = false;
//
// IsCheked
//
this.IsCheked.FillWeight = 10F;
this.IsCheked.HeaderText = "✔";
this.IsCheked.Name = "IsCheked";
this.IsCheked.ReadOnly = true;
this.IsCheked.Visible = false;
//
// CveSubProyecto
//
this.CveSubProyecto.DataPropertyName = "CveSubProyecto";
this.CveSubProyecto.HeaderText = "CveSubProyecto";
this.CveSubProyecto.Name = "CveSubProyecto";
this.CveSubProyecto.ReadOnly = true;
this.CveSubProyecto.Visible = false;
//
// SubProyecto
//
this.SubProyecto.DataPropertyName = "SubProyecto";
this.SubProyecto.HeaderText = "SubProyecto";
this.SubProyecto.Name = "SubProyecto";
this.SubProyecto.ReadOnly = true;
//
// ImgLoader
//
this.ImgLoader.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.ImgLoader.Image = global::ADSUtileriasWF.Properties.Resources.Loader;
this.ImgLoader.Location = new System.Drawing.Point(667, 16);
this.ImgLoader.Name = "ImgLoader";
this.ImgLoader.Size = new System.Drawing.Size(100, 50);
this.ImgLoader.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.ImgLoader.TabIndex = 7;
this.ImgLoader.TabStop = false;
//
// FrmConfiguracion
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(802, 450);
this.Controls.Add(this.ImgLoader);
this.Controls.Add(this.DtgvSubProyectos);
this.Controls.Add(this.BtnAceptar);
this.Controls.Add(this.label2);
this.Controls.Add(this.DdlSubProyecto);
this.Name = "FrmConfiguracion";
this.Text = "FrmConfiguracion";
this.Load += new System.EventHandler(this.FrmConfiguracion_Load);
((System.ComponentModel.ISupportInitialize)(this.DtgvSubProyectos)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.ImgLoader)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.ComboBox DdlSubProyecto;
private System.Windows.Forms.Label label2;
private FontAwesome.Sharp.IconButton BtnAceptar;
private System.Windows.Forms.DataGridView DtgvSubProyectos;
private System.Windows.Forms.PictureBox ImgLoader;
private System.Windows.Forms.DataGridViewCheckBoxColumn IsCheked;
private System.Windows.Forms.DataGridViewTextBoxColumn CveSubProyecto;
private System.Windows.Forms.DataGridViewTextBoxColumn SubProyecto;
}
}

View File

@@ -0,0 +1,74 @@
using ADSUtileriasWF.Helpers;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmConfiguracion : Form
{
public ADSUtileriasWF.Views.RelojChecador.Views.FrmInicio frminicio;
public FrmConfiguracion()
{
InitializeComponent();
DtgvSubProyectos.AutoGenerateColumns = false;
//DtgvSubProyectos.Visible = false;
}
public void loadpage()
{
this.Invoke((MethodInvoker)delegate
{
var subproyectos = Servicecon.GetSubProyectos(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), ModVarsPV.UserV2.CveEmpresa.ToString().ToEntero());
DdlSubProyecto.DataSource = subproyectos;
DtgvSubProyectos.DataSource = subproyectos;
DtgvSubProyectos.Refresh();
DdlSubProyecto.Refresh();
int index = 0;
foreach (UtileriasServiceWCF.ResponseSubProyectoUsuario item in DdlSubProyecto.Items)
{
if (item.CveSubProyecto == ModVarsPV.UserV2.CveSubProyecto)
{
DdlSubProyecto.SelectedIndex = index;
}
index++;
}
//try
//{
// DdlSubProyecto.SelectedValue = ModVarsPV.UserV2.cveSubProyecto.ToString();
//}
//catch (Exception)
//{
//}
ImgLoader.Visible = false;
});
}
private void FrmConfiguracion_Load(object sender, EventArgs e)
{
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(loadpage);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
private void DdlSubProyecto_SelectedIndexChanged(object sender, EventArgs e)
{
}
private void BtnAceptar_Click(object sender, EventArgs e)
{
int cveSubproyecto = DdlSubProyecto.SelectedValue.ToString().ToEntero();
string SubProyecto = ((UtileriasServiceWCF.ResponseSubProyectoUsuario)DdlSubProyecto.SelectedItem).SubProyecto;
Servicecon.CambiarEmpresa(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), ModVarsPV.UserV2.CveEmpresa.ToString().ToEntero(), cveSubproyecto);
ModVarsPV.UserV2.CveSubProyecto = cveSubproyecto;
frminicio.LblSubProyecto.Text = SubProyecto;
MessageBox.Show("Se ha actualizado el centro de costos.");
}
}
}

View File

@@ -0,0 +1,69 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="IsCheked.UserAddedColumn" type="System.Boolean, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
<value>True</value>
</metadata>
<metadata name="CveSubProyecto.UserAddedColumn" type="System.Boolean, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
<value>True</value>
</metadata>
<metadata name="SubProyecto.UserAddedColumn" type="System.Boolean, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
<value>True</value>
</metadata>
</root>

View File

@@ -0,0 +1,602 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmInicio
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmInicio));
this.PnlMenu = new System.Windows.Forms.Panel();
this.btnSistema = new FontAwesome.Sharp.IconButton();
this.byadsistemas = new System.Windows.Forms.Label();
this.BtnConfiguracion = new FontAwesome.Sharp.IconButton();
this.BtnReporte = new FontAwesome.Sharp.IconButton();
this.ChecadoresGluyas = new FontAwesome.Sharp.IconButton();
this.BtnNomina = new FontAwesome.Sharp.IconButton();
this.BtnAsistencia = new FontAwesome.Sharp.IconButton();
this.BtnPersonal = new FontAwesome.Sharp.IconButton();
this.BtnChecador = new FontAwesome.Sharp.IconButton();
this.PnlLogo = new System.Windows.Forms.Panel();
this.PnlTitle = new System.Windows.Forms.Panel();
this.PnlmenuXD = new System.Windows.Forms.Panel();
this.btnmenuXD = new FontAwesome.Sharp.IconButton();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.PnlBody = new System.Windows.Forms.Panel();
this.PnlBodyForms = new System.Windows.Forms.Panel();
this.PnlTopMenu = new System.Windows.Forms.Panel();
this.LblUsuario = new System.Windows.Forms.Label();
this.IboxUsuario = new FontAwesome.Sharp.IconPictureBox();
this.iconButton2 = new FontAwesome.Sharp.IconButton();
this.BtnClose = new FontAwesome.Sharp.IconButton();
this.BtnMaximizeRestore = new FontAwesome.Sharp.IconButton();
this.LblEmpresa = new System.Windows.Forms.Label();
this.BtnMinimize = new FontAwesome.Sharp.IconButton();
this.label1 = new System.Windows.Forms.Label();
this.PnlTitulo = new System.Windows.Forms.Panel();
this.LblSubProyecto = new System.Windows.Forms.Label();
this.PnlMenu.SuspendLayout();
this.PnlLogo.SuspendLayout();
this.PnlTitle.SuspendLayout();
this.PnlmenuXD.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.PnlBody.SuspendLayout();
this.PnlTopMenu.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.IboxUsuario)).BeginInit();
this.PnlTitulo.SuspendLayout();
this.SuspendLayout();
//
// PnlMenu
//
this.PnlMenu.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.PnlMenu.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.PnlMenu.Controls.Add(this.btnSistema);
this.PnlMenu.Controls.Add(this.byadsistemas);
this.PnlMenu.Controls.Add(this.BtnConfiguracion);
this.PnlMenu.Controls.Add(this.BtnReporte);
this.PnlMenu.Controls.Add(this.ChecadoresGluyas);
this.PnlMenu.Controls.Add(this.BtnNomina);
this.PnlMenu.Controls.Add(this.BtnAsistencia);
this.PnlMenu.Controls.Add(this.BtnPersonal);
this.PnlMenu.Controls.Add(this.BtnChecador);
this.PnlMenu.Controls.Add(this.PnlLogo);
this.PnlMenu.Location = new System.Drawing.Point(0, 0);
this.PnlMenu.Name = "PnlMenu";
this.PnlMenu.Size = new System.Drawing.Size(220, 584);
this.PnlMenu.TabIndex = 0;
//
// btnSistema
//
this.btnSistema.Dock = System.Windows.Forms.DockStyle.Top;
this.btnSistema.FlatAppearance.BorderSize = 0;
this.btnSistema.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnSistema.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnSistema.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.btnSistema.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnSistema.IconChar = FontAwesome.Sharp.IconChar.Tools;
this.btnSistema.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnSistema.IconSize = 28;
this.btnSistema.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnSistema.Location = new System.Drawing.Point(0, 309);
this.btnSistema.Name = "btnSistema";
this.btnSistema.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.btnSistema.Rotation = 0D;
this.btnSistema.Size = new System.Drawing.Size(220, 40);
this.btnSistema.TabIndex = 4;
this.btnSistema.Text = "Sistema";
this.btnSistema.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.btnSistema.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.btnSistema.UseVisualStyleBackColor = true;
this.btnSistema.Click += new System.EventHandler(this.ActivateButton);
//
// byadsistemas
//
this.byadsistemas.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.byadsistemas.AutoSize = true;
this.byadsistemas.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.byadsistemas.Location = new System.Drawing.Point(65, 560);
this.byadsistemas.Name = "byadsistemas";
this.byadsistemas.Size = new System.Drawing.Size(91, 15);
this.byadsistemas.TabIndex = 1;
this.byadsistemas.Text = "by ADSISTEMAS";
//
// BtnConfiguracion
//
this.BtnConfiguracion.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnConfiguracion.FlatAppearance.BorderSize = 0;
this.BtnConfiguracion.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnConfiguracion.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnConfiguracion.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnConfiguracion.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnConfiguracion.IconChar = FontAwesome.Sharp.IconChar.Tools;
this.BtnConfiguracion.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnConfiguracion.IconSize = 28;
this.BtnConfiguracion.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnConfiguracion.Location = new System.Drawing.Point(0, 269);
this.BtnConfiguracion.Name = "BtnConfiguracion";
this.BtnConfiguracion.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnConfiguracion.Rotation = 0D;
this.BtnConfiguracion.Size = new System.Drawing.Size(220, 40);
this.BtnConfiguracion.TabIndex = 0;
this.BtnConfiguracion.Text = "Configuración";
this.BtnConfiguracion.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnConfiguracion.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnConfiguracion.UseVisualStyleBackColor = true;
this.BtnConfiguracion.Click += new System.EventHandler(this.ActivateButton);
//
// BtnReporte
//
this.BtnReporte.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnReporte.FlatAppearance.BorderSize = 0;
this.BtnReporte.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnReporte.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnReporte.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnReporte.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnReporte.IconChar = FontAwesome.Sharp.IconChar.FilePdf;
this.BtnReporte.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnReporte.IconSize = 28;
this.BtnReporte.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnReporte.Location = new System.Drawing.Point(0, 229);
this.BtnReporte.Name = "BtnReporte";
this.BtnReporte.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnReporte.Rotation = 0D;
this.BtnReporte.Size = new System.Drawing.Size(220, 40);
this.BtnReporte.TabIndex = 3;
this.BtnReporte.Text = "Reportes";
this.BtnReporte.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnReporte.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnReporte.UseVisualStyleBackColor = true;
this.BtnReporte.Visible = false;
this.BtnReporte.Click += new System.EventHandler(this.ActivateButton);
//
// ChecadoresGluyas
//
this.ChecadoresGluyas.Dock = System.Windows.Forms.DockStyle.Top;
this.ChecadoresGluyas.FlatAppearance.BorderSize = 0;
this.ChecadoresGluyas.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.ChecadoresGluyas.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.ChecadoresGluyas.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.ChecadoresGluyas.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.ChecadoresGluyas.IconChar = FontAwesome.Sharp.IconChar.Algolia;
this.ChecadoresGluyas.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.ChecadoresGluyas.IconSize = 28;
this.ChecadoresGluyas.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.ChecadoresGluyas.Location = new System.Drawing.Point(0, 189);
this.ChecadoresGluyas.Name = "ChecadoresGluyas";
this.ChecadoresGluyas.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.ChecadoresGluyas.Rotation = 0D;
this.ChecadoresGluyas.Size = new System.Drawing.Size(220, 40);
this.ChecadoresGluyas.TabIndex = 2;
this.ChecadoresGluyas.Text = "Checadores";
this.ChecadoresGluyas.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.ChecadoresGluyas.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.ChecadoresGluyas.UseVisualStyleBackColor = true;
this.ChecadoresGluyas.Visible = false;
this.ChecadoresGluyas.Click += new System.EventHandler(this.ActivateButton);
//
// BtnNomina
//
this.BtnNomina.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnNomina.FlatAppearance.BorderSize = 0;
this.BtnNomina.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnNomina.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnNomina.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnNomina.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnNomina.IconChar = FontAwesome.Sharp.IconChar.Bell;
this.BtnNomina.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnNomina.IconSize = 28;
this.BtnNomina.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnNomina.Location = new System.Drawing.Point(0, 149);
this.BtnNomina.Name = "BtnNomina";
this.BtnNomina.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnNomina.Rotation = 0D;
this.BtnNomina.Size = new System.Drawing.Size(220, 40);
this.BtnNomina.TabIndex = 0;
this.BtnNomina.Text = "Nomina";
this.BtnNomina.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnNomina.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnNomina.UseVisualStyleBackColor = true;
this.BtnNomina.Visible = false;
this.BtnNomina.Click += new System.EventHandler(this.ActivateButton);
//
// BtnAsistencia
//
this.BtnAsistencia.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnAsistencia.FlatAppearance.BorderSize = 0;
this.BtnAsistencia.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnAsistencia.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnAsistencia.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnAsistencia.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnAsistencia.IconChar = FontAwesome.Sharp.IconChar.Check;
this.BtnAsistencia.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnAsistencia.IconSize = 28;
this.BtnAsistencia.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnAsistencia.Location = new System.Drawing.Point(0, 109);
this.BtnAsistencia.Name = "BtnAsistencia";
this.BtnAsistencia.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnAsistencia.Rotation = 0D;
this.BtnAsistencia.Size = new System.Drawing.Size(220, 40);
this.BtnAsistencia.TabIndex = 0;
this.BtnAsistencia.Text = "Asistencia";
this.BtnAsistencia.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnAsistencia.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnAsistencia.UseVisualStyleBackColor = true;
this.BtnAsistencia.Visible = false;
this.BtnAsistencia.Click += new System.EventHandler(this.ActivateButton);
//
// BtnPersonal
//
this.BtnPersonal.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnPersonal.FlatAppearance.BorderSize = 0;
this.BtnPersonal.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnPersonal.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnPersonal.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnPersonal.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnPersonal.IconChar = FontAwesome.Sharp.IconChar.IdCard;
this.BtnPersonal.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnPersonal.IconSize = 28;
this.BtnPersonal.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnPersonal.Location = new System.Drawing.Point(0, 69);
this.BtnPersonal.Name = "BtnPersonal";
this.BtnPersonal.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnPersonal.Rotation = 0D;
this.BtnPersonal.Size = new System.Drawing.Size(220, 40);
this.BtnPersonal.TabIndex = 0;
this.BtnPersonal.Text = "Personal";
this.BtnPersonal.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnPersonal.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnPersonal.UseVisualStyleBackColor = true;
this.BtnPersonal.Click += new System.EventHandler(this.ActivateButton);
//
// BtnChecador
//
this.BtnChecador.Dock = System.Windows.Forms.DockStyle.Top;
this.BtnChecador.FlatAppearance.BorderSize = 0;
this.BtnChecador.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnChecador.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnChecador.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.BtnChecador.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnChecador.IconChar = FontAwesome.Sharp.IconChar.Algolia;
this.BtnChecador.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnChecador.IconSize = 28;
this.BtnChecador.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnChecador.Location = new System.Drawing.Point(0, 29);
this.BtnChecador.Name = "BtnChecador";
this.BtnChecador.Padding = new System.Windows.Forms.Padding(10, 0, 10, 0);
this.BtnChecador.Rotation = 0D;
this.BtnChecador.Size = new System.Drawing.Size(220, 40);
this.BtnChecador.TabIndex = 0;
this.BtnChecador.Text = "Checadores";
this.BtnChecador.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.BtnChecador.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnChecador.UseVisualStyleBackColor = true;
this.BtnChecador.Visible = false;
this.BtnChecador.Click += new System.EventHandler(this.ActivateButton);
//
// PnlLogo
//
this.PnlLogo.Controls.Add(this.PnlTitle);
this.PnlLogo.Dock = System.Windows.Forms.DockStyle.Top;
this.PnlLogo.Location = new System.Drawing.Point(0, 0);
this.PnlLogo.Name = "PnlLogo";
this.PnlLogo.Size = new System.Drawing.Size(220, 29);
this.PnlLogo.TabIndex = 0;
//
// PnlTitle
//
this.PnlTitle.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.PnlTitle.Controls.Add(this.PnlmenuXD);
this.PnlTitle.Dock = System.Windows.Forms.DockStyle.Top;
this.PnlTitle.Location = new System.Drawing.Point(0, 0);
this.PnlTitle.Name = "PnlTitle";
this.PnlTitle.Size = new System.Drawing.Size(220, 30);
this.PnlTitle.TabIndex = 0;
this.PnlTitle.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// PnlmenuXD
//
this.PnlmenuXD.Controls.Add(this.btnmenuXD);
this.PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Right;
this.PnlmenuXD.Location = new System.Drawing.Point(180, 0);
this.PnlmenuXD.Name = "PnlmenuXD";
this.PnlmenuXD.Size = new System.Drawing.Size(40, 30);
this.PnlmenuXD.TabIndex = 0;
//
// btnmenuXD
//
this.btnmenuXD.FlatAppearance.BorderSize = 0;
this.btnmenuXD.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnmenuXD.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnmenuXD.Font = new System.Drawing.Font("Segoe UI", 16F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.btnmenuXD.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnmenuXD.IconChar = FontAwesome.Sharp.IconChar.Bars;
this.btnmenuXD.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnmenuXD.IconSize = 24;
this.btnmenuXD.ImageAlign = System.Drawing.ContentAlignment.TopLeft;
this.btnmenuXD.Location = new System.Drawing.Point(0, 1);
this.btnmenuXD.Name = "btnmenuXD";
this.btnmenuXD.Rotation = 0D;
this.btnmenuXD.Size = new System.Drawing.Size(40, 30);
this.btnmenuXD.TabIndex = 0;
this.btnmenuXD.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
this.btnmenuXD.UseVisualStyleBackColor = true;
this.btnmenuXD.Click += new System.EventHandler(this.BtnMenuShowHide_Click);
//
// pictureBox1
//
this.pictureBox1.Location = new System.Drawing.Point(9, 7);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(51, 46);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
this.pictureBox1.TabIndex = 2;
this.pictureBox1.TabStop = false;
this.pictureBox1.Click += new System.EventHandler(this.LblEmpresa_Click);
//
// PnlBody
//
this.PnlBody.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.PnlBody.AutoScroll = true;
this.PnlBody.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.PnlBody.Controls.Add(this.PnlBodyForms);
this.PnlBody.Location = new System.Drawing.Point(220, 100);
this.PnlBody.Name = "PnlBody";
this.PnlBody.Size = new System.Drawing.Size(1014, 480);
this.PnlBody.TabIndex = 2;
this.PnlBody.SizeChanged += new System.EventHandler(this.PnlBody_SizeChanged);
this.PnlBody.Paint += new System.Windows.Forms.PaintEventHandler(this.PnlBody_Paint);
//
// PnlBodyForms
//
this.PnlBodyForms.Location = new System.Drawing.Point(0, 0);
this.PnlBodyForms.Name = "PnlBodyForms";
this.PnlBodyForms.Size = new System.Drawing.Size(219, 215);
this.PnlBodyForms.TabIndex = 0;
//
// PnlTopMenu
//
this.PnlTopMenu.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.PnlTopMenu.Controls.Add(this.pictureBox1);
this.PnlTopMenu.Controls.Add(this.LblUsuario);
this.PnlTopMenu.Controls.Add(this.IboxUsuario);
this.PnlTopMenu.Location = new System.Drawing.Point(220, 30);
this.PnlTopMenu.Name = "PnlTopMenu";
this.PnlTopMenu.Size = new System.Drawing.Size(1024, 70);
this.PnlTopMenu.TabIndex = 3;
//
// LblUsuario
//
this.LblUsuario.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.LblUsuario.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblUsuario.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblUsuario.Location = new System.Drawing.Point(870, 30);
this.LblUsuario.Name = "LblUsuario";
this.LblUsuario.Size = new System.Drawing.Size(140, 40);
this.LblUsuario.TabIndex = 1;
this.LblUsuario.Text = "Usuario este es un texto muy largo que se brincara la lines para no";
this.LblUsuario.TextAlign = System.Drawing.ContentAlignment.TopCenter;
//
// IboxUsuario
//
this.IboxUsuario.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.IboxUsuario.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(54)))), ((int)(((byte)(65)))), ((int)(((byte)(80)))));
this.IboxUsuario.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.IboxUsuario.IconChar = FontAwesome.Sharp.IconChar.Portrait;
this.IboxUsuario.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.IboxUsuario.IconSize = 26;
this.IboxUsuario.Location = new System.Drawing.Point(930, 5);
this.IboxUsuario.Name = "IboxUsuario";
this.IboxUsuario.Size = new System.Drawing.Size(32, 26);
this.IboxUsuario.TabIndex = 0;
this.IboxUsuario.TabStop = false;
this.IboxUsuario.Click += new System.EventHandler(this.IboxUsuario_Click);
//
// iconButton2
//
this.iconButton2.Dock = System.Windows.Forms.DockStyle.Top;
this.iconButton2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.iconButton2.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.iconButton2.Font = new System.Drawing.Font("Segoe UI", 16F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.iconButton2.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.iconButton2.IconChar = FontAwesome.Sharp.IconChar.Bars;
this.iconButton2.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.iconButton2.IconSize = 24;
this.iconButton2.ImageAlign = System.Drawing.ContentAlignment.TopLeft;
this.iconButton2.Location = new System.Drawing.Point(0, 0);
this.iconButton2.Name = "iconButton2";
this.iconButton2.Rotation = 0D;
this.iconButton2.Size = new System.Drawing.Size(40, 30);
this.iconButton2.TabIndex = 0;
this.iconButton2.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
this.iconButton2.UseVisualStyleBackColor = true;
//
// BtnClose
//
this.BtnClose.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnClose.FlatAppearance.BorderSize = 0;
this.BtnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnClose.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnClose.IconChar = FontAwesome.Sharp.IconChar.Times;
this.BtnClose.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnClose.IconSize = 20;
this.BtnClose.Location = new System.Drawing.Point(1207, 1);
this.BtnClose.Name = "BtnClose";
this.BtnClose.Rotation = 0D;
this.BtnClose.Size = new System.Drawing.Size(30, 28);
this.BtnClose.TabIndex = 0;
this.BtnClose.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnClose.UseVisualStyleBackColor = true;
this.BtnClose.Click += new System.EventHandler(this.BtnClose_Click);
//
// BtnMaximizeRestore
//
this.BtnMaximizeRestore.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMaximizeRestore.FlatAppearance.BorderSize = 0;
this.BtnMaximizeRestore.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMaximizeRestore.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMaximizeRestore.IconChar = FontAwesome.Sharp.IconChar.WindowMaximize;
this.BtnMaximizeRestore.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMaximizeRestore.IconSize = 20;
this.BtnMaximizeRestore.Location = new System.Drawing.Point(1177, 1);
this.BtnMaximizeRestore.Name = "BtnMaximizeRestore";
this.BtnMaximizeRestore.Rotation = 0D;
this.BtnMaximizeRestore.Size = new System.Drawing.Size(30, 28);
this.BtnMaximizeRestore.TabIndex = 0;
this.BtnMaximizeRestore.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMaximizeRestore.UseVisualStyleBackColor = true;
this.BtnMaximizeRestore.Click += new System.EventHandler(this.BtnMaximizeRestore_Click);
//
// LblEmpresa
//
this.LblEmpresa.AutoSize = true;
this.LblEmpresa.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblEmpresa.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblEmpresa.Location = new System.Drawing.Point(226, 7);
this.LblEmpresa.Name = "LblEmpresa";
this.LblEmpresa.Size = new System.Drawing.Size(82, 17);
this.LblEmpresa.TabIndex = 2;
this.LblEmpresa.Text = "ADSISTEMAS";
this.LblEmpresa.Click += new System.EventHandler(this.LblEmpresa_Click);
//
// BtnMinimize
//
this.BtnMinimize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.BtnMinimize.FlatAppearance.BorderSize = 0;
this.BtnMinimize.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.BtnMinimize.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.BtnMinimize.IconChar = FontAwesome.Sharp.IconChar.WindowMinimize;
this.BtnMinimize.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.BtnMinimize.IconSize = 20;
this.BtnMinimize.Location = new System.Drawing.Point(1147, 1);
this.BtnMinimize.Name = "BtnMinimize";
this.BtnMinimize.Rotation = 0D;
this.BtnMinimize.Size = new System.Drawing.Size(30, 28);
this.BtnMinimize.TabIndex = 0;
this.BtnMinimize.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.BtnMinimize.UseVisualStyleBackColor = true;
this.BtnMinimize.Click += new System.EventHandler(this.BtnMinimize_Click);
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.label1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.label1.Location = new System.Drawing.Point(578, 284);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(82, 17);
this.label1.TabIndex = 5;
this.label1.Text = "ADSISTEMAS";
//
// PnlTitulo
//
this.PnlTitulo.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.PnlTitulo.Controls.Add(this.LblSubProyecto);
this.PnlTitulo.Controls.Add(this.label1);
this.PnlTitulo.Controls.Add(this.BtnMinimize);
this.PnlTitulo.Controls.Add(this.LblEmpresa);
this.PnlTitulo.Controls.Add(this.BtnMaximizeRestore);
this.PnlTitulo.Controls.Add(this.BtnClose);
this.PnlTitulo.Dock = System.Windows.Forms.DockStyle.Fill;
this.PnlTitulo.Location = new System.Drawing.Point(0, 0);
this.PnlTitulo.Name = "PnlTitulo";
this.PnlTitulo.Size = new System.Drawing.Size(1238, 584);
this.PnlTitulo.TabIndex = 1;
this.PnlTitulo.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// LblSubProyecto
//
this.LblSubProyecto.AutoSize = true;
this.LblSubProyecto.Font = new System.Drawing.Font("Open Sans", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.LblSubProyecto.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.LblSubProyecto.Location = new System.Drawing.Point(548, 7);
this.LblSubProyecto.Name = "LblSubProyecto";
this.LblSubProyecto.Size = new System.Drawing.Size(122, 17);
this.LblSubProyecto.TabIndex = 6;
this.LblSubProyecto.Text = "Sin Centro de costos";
//
// FrmInicio
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(1238, 584);
this.ControlBox = false;
this.Controls.Add(this.PnlTopMenu);
this.Controls.Add(this.PnlBody);
this.Controls.Add(this.PnlMenu);
this.Controls.Add(this.PnlTitulo);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MinimumSize = new System.Drawing.Size(650, 400);
this.Name = "FrmInicio";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.PnlMenu.ResumeLayout(false);
this.PnlMenu.PerformLayout();
this.PnlLogo.ResumeLayout(false);
this.PnlTitle.ResumeLayout(false);
this.PnlmenuXD.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.PnlBody.ResumeLayout(false);
this.PnlTopMenu.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.IboxUsuario)).EndInit();
this.PnlTitulo.ResumeLayout(false);
this.PnlTitulo.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Panel PnlMenu;
private System.Windows.Forms.Panel PnlLogo;
private FontAwesome.Sharp.IconButton BtnChecador;
private FontAwesome.Sharp.IconButton BtnConfiguracion;
private FontAwesome.Sharp.IconButton ChecadoresGluyas;
private FontAwesome.Sharp.IconButton BtnAsistencia;
private FontAwesome.Sharp.IconButton BtnPersonal;
private System.Windows.Forms.Panel PnlTitle;
private System.Windows.Forms.Panel PnlmenuXD;
private FontAwesome.Sharp.IconButton btnmenuXD;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Label byadsistemas;
private System.Windows.Forms.Panel PnlBody;
private System.Windows.Forms.Panel PnlTopMenu;
private System.Windows.Forms.Panel PnlBodyForms;
private FontAwesome.Sharp.IconPictureBox IboxUsuario;
private System.Windows.Forms.Label LblUsuario;
private FontAwesome.Sharp.IconButton BtnNomina;
private FontAwesome.Sharp.IconButton iconButton2;
private FontAwesome.Sharp.IconButton BtnReporte;
private FontAwesome.Sharp.IconButton BtnClose;
private FontAwesome.Sharp.IconButton BtnMaximizeRestore;
private System.Windows.Forms.Label LblEmpresa;
private FontAwesome.Sharp.IconButton BtnMinimize;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Panel PnlTitulo;
public System.Windows.Forms.Label LblSubProyecto;
private FontAwesome.Sharp.IconButton btnSistema;
}
}

View File

@@ -0,0 +1,367 @@
using ADSUtileriasWF.Helpers;
using ADSUtileriasWF.Views.Timbrado.Views;
using FontAwesome.Sharp;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmInicio : FormBase
{
const int PnlMenuWidthOpen = 220;
const int PnlMenuWidthClose = 68;
private IconButton currentBtn;
private Form currentForm;
private Panel leftBorderBtn;
private FrmConfiguracion frmConfiguracion;
private FrmAsistencia frmAsistencia;
//private FrmPersonal frmPersonal;
private FrmTimbradoNomina frmTimbradoNomina;
private FrmNewPersonalChecador frmnewPersonal;
private FrmChecadores frmChecadores;
List<string[]> btnestexto;
public FrmInicio()
{
InitializeComponent();
this.SetStyle(ControlStyles.ResizeRedraw, true);
leftBorderBtn = new Panel();
PnlMenu.Controls.Add(leftBorderBtn);
LblUsuario.Text = ModVarsPV.UserV2.Nombre;// "";//"brenda.martinez@agrojam.com.mx";//UsuarioActual.Nombre;
LblEmpresa.Text = ModVarsPV.UserV2.Empresa;//"";//"Agroquimicos JAM";//UsuarioActual.Empresa.empresa1Field;
loadsubproyecto();
btnestexto = new List<string[]>();
//PnlMenu.Controls.OfType<Control>().SelectMany(x => x is Button))
foreach (Control item in PnlMenu.Controls)
{
if (item is Button) { btnestexto.Add(new string[] { item.Name, item.Text }); }
}
if (ModVarsPV.CveTipoTerminal > 1)
{
activeMenu("BtnComedor");
BtnMenuShowHide_Click(null, null);
this.PnlBody.Width = PnlBody.Width + this.PnlMenu.Width;
this.PnlTopMenu.Width = PnlTopMenu.Width + this.PnlMenu.Width;
this.PnlMenu.Width = 0;
PnlMenu.Visible = false;
PnlTopMenu.Location = new System.Drawing.Point(0, PnlTopMenu.Location.Y);
PnlBody.Location = new System.Drawing.Point(0, PnlBody.Location.Y);
}
}
public void loadsubproyecto()
{
if (ModVarsPV.UserV2.CveSubProyecto > 0)
{
var subproyectos = Servicecon.GetSubProyectos(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), ModVarsPV.UserV2.CveEmpresa.ToString().ToEntero());
var subp = subproyectos.FirstOrDefault(x => x.CveSubProyecto == ModVarsPV.UserV2.CveSubProyecto);
if (subp != null)
{
LblSubProyecto.Text = subp.SubProyecto;
}
}
}
#region viewchanges
private void BtnMenuShowHide_Click(object sender, EventArgs e)
{
int restante = PnlMenuWidthOpen - PnlMenuWidthClose;
if (PnlMenu.Size.Width == PnlMenuWidthOpen)
{
this.PnlMenu.Width = PnlMenuWidthClose;
//LblEmpresa.Location = new System.Drawing.Point(10, LblEmpresa.Location.Y);
PnlTopMenu.Width = PnlTopMenu.Width + restante;
PnlTopMenu.Location = new System.Drawing.Point(PnlMenuWidthClose, PnlTopMenu.Location.Y);
LblEmpresa.Location = new System.Drawing.Point(LblEmpresa.Location.X - restante, LblEmpresa.Location.Y);
this.PnlBody.Width = PnlBody.Width + restante;
PnlBody.Location = new System.Drawing.Point(PnlMenuWidthClose, PnlBody.Location.Y);
foreach (Control item in PnlMenu.Controls)
{
if (item is Button) { item.Text = ""; }
}
/*
BtnConfiguracion.Text = "";
BtnAsistencia.Text = "";
BtnPersonal.Text = "";
BtnChecador.Text = "";
BtnNomina.Text = "";*/
PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Left;
PnlmenuXD.Size = new System.Drawing.Size(PnlMenuWidthClose, 30);
btnmenuXD.Size = new System.Drawing.Size(PnlMenuWidthClose, 30);
btnmenuXD.Padding = new System.Windows.Forms.Padding(0, 0, 20, 0);
btnmenuXD.Text = " ";
}
else
{
PnlMenu.Width = PnlMenuWidthOpen;
//LblEmpresa.Location = new System.Drawing.Point(160, LblEmpresa.Location.Y);
LblEmpresa.Location = new System.Drawing.Point(LblEmpresa.Location.X + restante, LblEmpresa.Location.Y);
PnlTopMenu.Width = PnlTopMenu.Width - restante;
PnlTopMenu.Location = new System.Drawing.Point(PnlMenuWidthOpen, PnlTopMenu.Location.Y);
PnlBody.Location = new System.Drawing.Point(PnlMenuWidthOpen, PnlBody.Location.Y);
this.PnlBody.Width = PnlBody.Width - restante;
foreach (Control item in PnlMenu.Controls)
{
if (item is Button)
{
string texto = btnestexto.FirstOrDefault(x => x[0] == item.Name)[1];
item.Text = texto == null ? "" : texto;
}
}/*
BtnConfiguracion.Text = "Configuración";
BtnAsistencia.Text = "Asistencia";
BtnPersonal.Text = "Personal";
BtnChecador.Text = "Checadores";
BtnNomina.Text = "Nómina";*/
PnlmenuXD.Dock = System.Windows.Forms.DockStyle.Right;
PnlmenuXD.Size = new System.Drawing.Size(40, 30);
btnmenuXD.Size = new System.Drawing.Size(40, 30);
btnmenuXD.Padding = new System.Windows.Forms.Padding(0, 0, 0, 0);
btnmenuXD.Text = "";
}
}
private void setActivateButton(object sender, EventArgs e)
{
if (currentBtn != sender)
{
if (currentBtn != null)
{
currentBtn.BackColor = System.Drawing.Color.FromArgb(54, 65, 80);
currentBtn.ForeColor = btnmenuXD.ForeColor;
currentBtn.TextAlign = ContentAlignment.MiddleLeft;
currentBtn.IconColor = Color.Gainsboro;
currentBtn.TextImageRelation = TextImageRelation.ImageBeforeText;
currentBtn.ImageAlign = ContentAlignment.MiddleLeft;
}
if (sender != null)
{
Color color = Color.FromArgb(53, 152, 220);
//Button
currentBtn = (IconButton)sender;
currentBtn.BackColor = Color.FromArgb(43, 54, 67);
//currentBtn.ForeColor = color;
currentBtn.TextAlign = ContentAlignment.MiddleCenter;
currentBtn.IconColor = color;
currentBtn.TextImageRelation = TextImageRelation.TextBeforeImage;
currentBtn.ImageAlign = ContentAlignment.MiddleRight;
//Left border button
leftBorderBtn.BackColor = color;
leftBorderBtn.Size = new Size(7, currentBtn.Size.Height);
leftBorderBtn.Location = new Point(0, currentBtn.Location.Y);
leftBorderBtn.Visible = true;
leftBorderBtn.BringToFront();
activeMenu(currentBtn.Name.ToString());
}
}
PnlBody_SizeChanged(PnlBody, null);
}
private void ActivateButton(object sender, EventArgs e)
{
setActivateButton(sender, e);
}
private void PnlBody_SizeChanged(object sender, EventArgs e)
{
int width = PnlBody.Width - 5;
int height = PnlBody.Height - 5;
if (currentForm != null)
{
if (width < currentForm.MinimumSize.Width)
{
width = currentForm.MinimumSize.Width;
}
if (height < currentForm.MinimumSize.Height)
{
height = currentForm.MinimumSize.Height;
}
currentForm.Size = new System.Drawing.Size(width, height);
}
PnlBodyForms.Size = new System.Drawing.Size(width, height);
}
#endregion
private void activeMenu(string buttonname)
{
bool isnewform = false;
if (currentForm != null)
{
currentForm.Hide();
currentForm = null;
}
switch (buttonname)
{
/*
private ;
private ;
.Text = "";
.Text = "";*/
case "BtnConfiguracion":
frmConfiguracion = new FrmConfiguracion();
frmConfiguracion.frminicio = this;
isnewform = true;
currentForm = frmConfiguracion;
break;
case "BtnPersonal":
//if (frmPersonal == null)
//{
// frmPersonal = new FrmPersonal();
// isnewform = true;
//}
//currentForm = frmPersonal;
if (ModVarsPV.UserV2.CveSubProyecto > 0)
{
frmnewPersonal = new FrmNewPersonalChecador();
isnewform = true;
currentForm = frmnewPersonal;
}
else
{
frmConfiguracion = new FrmConfiguracion();
frmConfiguracion.frminicio = this;
isnewform = true;
{
if (currentBtn != null)
{
currentBtn.BackColor = System.Drawing.Color.FromArgb(54, 65, 80);
currentBtn.ForeColor = btnmenuXD.ForeColor;
currentBtn.TextAlign = ContentAlignment.MiddleLeft;
currentBtn.IconColor = Color.Gainsboro;
currentBtn.TextImageRelation = TextImageRelation.ImageBeforeText;
currentBtn.ImageAlign = ContentAlignment.MiddleLeft;
}
if (BtnConfiguracion != null)
{
Color color = Color.FromArgb(53, 152, 220);
//Button
currentBtn = BtnConfiguracion;
currentBtn.BackColor = Color.FromArgb(43, 54, 67);
//currentBtn.ForeColor = color;
currentBtn.TextAlign = ContentAlignment.MiddleCenter;
currentBtn.IconColor = color;
currentBtn.TextImageRelation = TextImageRelation.TextBeforeImage;
currentBtn.ImageAlign = ContentAlignment.MiddleRight;
//Left border button
leftBorderBtn.BackColor = color;
leftBorderBtn.Size = new Size(7, currentBtn.Size.Height);
leftBorderBtn.Location = new Point(0, currentBtn.Location.Y);
leftBorderBtn.Visible = true;
leftBorderBtn.BringToFront();
}
}
currentForm = frmConfiguracion;
ModExtensiones.Alert("Debe seleccionar un centro de costos antes de entrar a este módulo", "Información", MessageBoxButtons.OK);
}
break;
case "BtnAsistencia":
if (frmAsistencia == null)
{
frmAsistencia = new FrmAsistencia();
isnewform = true;
}
currentForm = frmAsistencia;
break;
case "BtnChecador":
if (frmChecadores == null)
{
frmChecadores = new FrmChecadores();
isnewform = true;
}
currentForm = frmChecadores;
break;
case "BtnNomina":
if (frmTimbradoNomina == null)
{
frmTimbradoNomina = new FrmTimbradoNomina();
isnewform = true;
}
currentForm = frmTimbradoNomina;
break;
case "btnSistema":
currentForm = new FrmSistema();
isnewform = true;
break;
case "ChecadoresGluyas":
isnewform = true;
currentForm = new ADSUtileriasWF.Views.RelojChecador.Gluyas.Checadores();
break;
case "BtnReporte":
isnewform = true;
currentForm = new ADSUtileriasWF.Views.RelojChecador.Gluyas.ReporteChecadores();
break;
default:
break;
}
if (currentForm != null)
{
if (isnewform)
{
currentForm.TopLevel = false;
currentForm.AutoScroll = true;
this.PnlBodyForms.Controls.Add(currentForm);
currentForm.FormBorderStyle = FormBorderStyle.None;
currentForm.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right)));
}
PnlBodyForms.MinimumSize = currentForm.MinimumSize;
currentForm.BringToFront();
currentForm.Show();
}
else
{
PnlBodyForms.MinimumSize = new System.Drawing.Size(0, 0);
}
}
private void LblEmpresa_Click(object sender, EventArgs e)
{
activeMenu("");
}
private void PnlBody_Paint(object sender, PaintEventArgs e)
{
}
private void IboxUsuario_Click(object sender, EventArgs e)
{
using (FrmCambiarEmpresa frmBitacora = new FrmCambiarEmpresa())
{
DialogResult result = frmBitacora.ShowDialog();
if (result != System.Windows.Forms.DialogResult.OK)
{
}
else
{
LblEmpresa.Text = ModVarsPV.UserV2.Empresa;
loadsubproyecto();
//ObservacionesBitacora_ = frmBitacora.ObservacionesBitacora;
//if (string.IsNullOrEmpty(ObservacionesBitacora_.Trim())) { MessageBox.Show("Debe indicar una Observacion y/o Justificacion"); }
}
}
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,684 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmNewPersonalChecador
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
LblEmpleado = new System.Windows.Forms.Label();
GBoxHuellas = new System.Windows.Forms.GroupBox();
btnCancelar = new System.Windows.Forms.Button();
BtnVincular = new System.Windows.Forms.Button();
label3 = new System.Windows.Forms.Label();
ddlChek = new System.Windows.Forms.ComboBox();
ChkVincularsinhuella = new System.Windows.Forms.CheckBox();
Huella3 = new System.Windows.Forms.PictureBox();
Huella2 = new System.Windows.Forms.PictureBox();
Huella1 = new System.Windows.Forms.PictureBox();
textRes = new System.Windows.Forms.TextBox();
DdlEmpleados = new System.Windows.Forms.ComboBox();
DGVChecadores = new System.Windows.Forms.DataGridView();
Seleccionar = new System.Windows.Forms.DataGridViewCheckBoxColumn();
cveChecador = new System.Windows.Forms.DataGridViewTextBoxColumn();
checador = new System.Windows.Forms.DataGridViewTextBoxColumn();
subProyecto = new System.Windows.Forms.DataGridViewTextBoxColumn();
Vinculado = new System.Windows.Forms.DataGridViewCheckBoxColumn();
iPLocal = new System.Windows.Forms.DataGridViewTextBoxColumn();
puerto = new System.Windows.Forms.DataGridViewTextBoxColumn();
ImgLoader = new System.Windows.Forms.PictureBox();
tabpanel = new System.Windows.Forms.TabControl();
tabRegistro = new System.Windows.Forms.TabPage();
btnmostarcontroles = new System.Windows.Forms.Button();
BtnAggregarPersonal = new System.Windows.Forms.Button();
button1 = new System.Windows.Forms.Button();
TxtPersonal = new System.Windows.Forms.TextBox();
TxtCodigo = new System.Windows.Forms.TextBox();
LblSubProyecto = new System.Windows.Forms.Label();
DdlSubProyecto = new System.Windows.Forms.ComboBox();
BtnActualizar = new System.Windows.Forms.Button();
chkMostrarTodos = new System.Windows.Forms.CheckBox();
tabvalidacion = new System.Windows.Forms.TabPage();
dataGridView1 = new System.Windows.Forms.DataGridView();
dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
CentrodeCostos = new System.Windows.Forms.DataGridViewTextBoxColumn();
CvePersonal = new System.Windows.Forms.DataGridViewTextBoxColumn();
CodigoNombreCompleto = new System.Windows.Forms.DataGridViewTextBoxColumn();
label1 = new System.Windows.Forms.Label();
panel1 = new System.Windows.Forms.Panel();
LblChecadorseleccionado = new System.Windows.Forms.Label();
TxtNombrevinculo = new System.Windows.Forms.TextBox();
Ddlchecador = new System.Windows.Forms.ComboBox();
TxtNombreRegistro = new System.Windows.Forms.TextBox();
lblregistrochecador = new System.Windows.Forms.Label();
label2 = new System.Windows.Forms.Label();
GBoxHuellas.SuspendLayout();
((System.ComponentModel.ISupportInitialize)Huella3).BeginInit();
((System.ComponentModel.ISupportInitialize)Huella2).BeginInit();
((System.ComponentModel.ISupportInitialize)Huella1).BeginInit();
((System.ComponentModel.ISupportInitialize)DGVChecadores).BeginInit();
((System.ComponentModel.ISupportInitialize)ImgLoader).BeginInit();
tabpanel.SuspendLayout();
tabRegistro.SuspendLayout();
tabvalidacion.SuspendLayout();
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
panel1.SuspendLayout();
SuspendLayout();
//
// LblEmpleado
//
LblEmpleado.AutoSize = true;
LblEmpleado.Location = new System.Drawing.Point(6, 60);
LblEmpleado.Name = "LblEmpleado";
LblEmpleado.Size = new System.Drawing.Size(131, 15);
LblEmpleado.TabIndex = 0;
LblEmpleado.Text = "Seleccione el empleado";
//
// GBoxHuellas
//
GBoxHuellas.Controls.Add(btnCancelar);
GBoxHuellas.Controls.Add(BtnVincular);
GBoxHuellas.Controls.Add(label3);
GBoxHuellas.Controls.Add(ddlChek);
GBoxHuellas.Controls.Add(ChkVincularsinhuella);
GBoxHuellas.Controls.Add(Huella3);
GBoxHuellas.Controls.Add(Huella2);
GBoxHuellas.Controls.Add(Huella1);
GBoxHuellas.Controls.Add(textRes);
GBoxHuellas.Location = new System.Drawing.Point(402, 134);
GBoxHuellas.Name = "GBoxHuellas";
GBoxHuellas.Size = new System.Drawing.Size(418, 296);
GBoxHuellas.TabIndex = 1;
GBoxHuellas.TabStop = false;
GBoxHuellas.Text = "Huellas";
//
// btnCancelar
//
btnCancelar.BackColor = System.Drawing.Color.IndianRed;
btnCancelar.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
btnCancelar.ForeColor = System.Drawing.SystemColors.Window;
btnCancelar.Location = new System.Drawing.Point(284, 247);
btnCancelar.Name = "btnCancelar";
btnCancelar.Size = new System.Drawing.Size(75, 32);
btnCancelar.TabIndex = 18;
btnCancelar.Text = "Cancelar";
btnCancelar.UseVisualStyleBackColor = false;
btnCancelar.Click += BtnCancelar_Click;
//
// BtnVincular
//
BtnVincular.BackColor = System.Drawing.Color.FromArgb(43, 54, 67);
BtnVincular.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
BtnVincular.ForeColor = System.Drawing.SystemColors.ControlLightLight;
BtnVincular.Location = new System.Drawing.Point(145, 247);
BtnVincular.Name = "BtnVincular";
BtnVincular.Size = new System.Drawing.Size(108, 32);
BtnVincular.TabIndex = 17;
BtnVincular.Text = "Vincular";
BtnVincular.UseVisualStyleBackColor = false;
BtnVincular.Click += Btncapturar_Click;
//
// label3
//
label3.AutoSize = true;
label3.Location = new System.Drawing.Point(7, 213);
label3.Name = "label3";
label3.Size = new System.Drawing.Size(111, 15);
label3.TabIndex = 16;
label3.Text = "Capturar huella con";
//
// ddlChek
//
ddlChek.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest;
ddlChek.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
ddlChek.DisplayMember = "Checador";
ddlChek.Enabled = false;
ddlChek.FormattingEnabled = true;
ddlChek.Location = new System.Drawing.Point(124, 210);
ddlChek.Name = "ddlChek";
ddlChek.Size = new System.Drawing.Size(288, 23);
ddlChek.TabIndex = 15;
ddlChek.ValueMember = "CveChecador";
//
// ChkVincularsinhuella
//
ChkVincularsinhuella.AutoSize = true;
ChkVincularsinhuella.Location = new System.Drawing.Point(7, 247);
ChkVincularsinhuella.Name = "ChkVincularsinhuella";
ChkVincularsinhuella.Size = new System.Drawing.Size(122, 19);
ChkVincularsinhuella.TabIndex = 14;
ChkVincularsinhuella.Text = "Vincular sin huella";
ChkVincularsinhuella.UseVisualStyleBackColor = true;
//
// Huella3
//
Huella3.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
Huella3.Location = new System.Drawing.Point(283, 22);
Huella3.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
Huella3.Name = "Huella3";
Huella3.Size = new System.Drawing.Size(130, 140);
Huella3.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
Huella3.TabIndex = 8;
Huella3.TabStop = false;
//
// Huella2
//
Huella2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
Huella2.Location = new System.Drawing.Point(145, 22);
Huella2.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
Huella2.Name = "Huella2";
Huella2.Size = new System.Drawing.Size(130, 140);
Huella2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
Huella2.TabIndex = 8;
Huella2.TabStop = false;
//
// Huella1
//
Huella1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
Huella1.Location = new System.Drawing.Point(7, 22);
Huella1.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
Huella1.Name = "Huella1";
Huella1.Size = new System.Drawing.Size(130, 140);
Huella1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
Huella1.TabIndex = 8;
Huella1.TabStop = false;
//
// textRes
//
textRes.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
textRes.BackColor = System.Drawing.Color.FromArgb(43, 54, 67);
textRes.BorderStyle = System.Windows.Forms.BorderStyle.None;
textRes.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F);
textRes.ForeColor = System.Drawing.Color.FromArgb(180, 188, 200);
textRes.Location = new System.Drawing.Point(7, 168);
textRes.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
textRes.Multiline = true;
textRes.Name = "textRes";
textRes.ReadOnly = true;
textRes.Size = new System.Drawing.Size(406, 36);
textRes.TabIndex = 7;
//
// DdlEmpleados
//
DdlEmpleados.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest;
DdlEmpleados.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
DdlEmpleados.DisplayMember = "CodigoNombreCompleto";
DdlEmpleados.Enabled = false;
DdlEmpleados.FormattingEnabled = true;
DdlEmpleados.Location = new System.Drawing.Point(6, 78);
DdlEmpleados.Name = "DdlEmpleados";
DdlEmpleados.Size = new System.Drawing.Size(671, 23);
DdlEmpleados.TabIndex = 2;
DdlEmpleados.ValueMember = "CvePersonal";
//
// DGVChecadores
//
DGVChecadores.AllowUserToAddRows = false;
DGVChecadores.AllowUserToDeleteRows = false;
DGVChecadores.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
DGVChecadores.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
DGVChecadores.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
DGVChecadores.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { Seleccionar, cveChecador, checador, subProyecto, Vinculado, iPLocal, puerto });
DGVChecadores.Location = new System.Drawing.Point(6, 179);
DGVChecadores.Name = "DGVChecadores";
DGVChecadores.RowHeadersVisible = false;
DGVChecadores.Size = new System.Drawing.Size(390, 251);
DGVChecadores.TabIndex = 8;
DGVChecadores.Text = "DGVChecadores";
//
// Seleccionar
//
Seleccionar.FillWeight = 10F;
Seleccionar.HeaderText = "✔";
Seleccionar.Name = "Seleccionar";
Seleccionar.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// cveChecador
//
cveChecador.DataPropertyName = "cveChecador";
cveChecador.HeaderText = "cveChecador";
cveChecador.Name = "cveChecador";
cveChecador.ReadOnly = true;
cveChecador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
cveChecador.Visible = false;
//
// checador
//
checador.DataPropertyName = "checador";
checador.FillWeight = 50F;
checador.HeaderText = "Checador";
checador.Name = "checador";
checador.ReadOnly = true;
checador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
checador.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
//
// subProyecto
//
subProyecto.DataPropertyName = "subProyecto";
subProyecto.FillWeight = 70F;
subProyecto.HeaderText = "Centro de Costos";
subProyecto.Name = "subProyecto";
subProyecto.ReadOnly = true;
subProyecto.Resizable = System.Windows.Forms.DataGridViewTriState.True;
subProyecto.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
//
// Vinculado
//
Vinculado.FillWeight = 30F;
Vinculado.HeaderText = "Vinculado";
Vinculado.Name = "Vinculado";
Vinculado.ReadOnly = true;
//
// iPLocal
//
iPLocal.DataPropertyName = "iPLocal";
iPLocal.HeaderText = "iPLocal";
iPLocal.Name = "iPLocal";
iPLocal.ReadOnly = true;
iPLocal.Visible = false;
//
// puerto
//
puerto.DataPropertyName = "puerto";
puerto.HeaderText = "puerto";
puerto.Name = "puerto";
puerto.ReadOnly = true;
puerto.Visible = false;
//
// ImgLoader
//
ImgLoader.Image = Properties.Resources.Loader;
ImgLoader.Location = new System.Drawing.Point(770, 78);
ImgLoader.Name = "ImgLoader";
ImgLoader.Size = new System.Drawing.Size(34, 23);
ImgLoader.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
ImgLoader.TabIndex = 13;
ImgLoader.TabStop = false;
//
// tabpanel
//
tabpanel.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
tabpanel.Controls.Add(tabRegistro);
tabpanel.Controls.Add(tabvalidacion);
tabpanel.Location = new System.Drawing.Point(12, 12);
tabpanel.Name = "tabpanel";
tabpanel.SelectedIndex = 0;
tabpanel.Size = new System.Drawing.Size(923, 482);
tabpanel.TabIndex = 16;
//
// tabRegistro
//
tabRegistro.Controls.Add(btnmostarcontroles);
tabRegistro.Controls.Add(BtnAggregarPersonal);
tabRegistro.Controls.Add(button1);
tabRegistro.Controls.Add(TxtPersonal);
tabRegistro.Controls.Add(TxtCodigo);
tabRegistro.Controls.Add(LblSubProyecto);
tabRegistro.Controls.Add(DdlSubProyecto);
tabRegistro.Controls.Add(BtnActualizar);
tabRegistro.Controls.Add(chkMostrarTodos);
tabRegistro.Controls.Add(LblEmpleado);
tabRegistro.Controls.Add(GBoxHuellas);
tabRegistro.Controls.Add(ImgLoader);
tabRegistro.Controls.Add(DdlEmpleados);
tabRegistro.Controls.Add(DGVChecadores);
tabRegistro.Location = new System.Drawing.Point(4, 24);
tabRegistro.Name = "tabRegistro";
tabRegistro.Padding = new System.Windows.Forms.Padding(3);
tabRegistro.Size = new System.Drawing.Size(915, 454);
tabRegistro.TabIndex = 0;
tabRegistro.Text = "Registro";
tabRegistro.UseVisualStyleBackColor = true;
//
// btnmostarcontroles
//
btnmostarcontroles.BackColor = System.Drawing.Color.CornflowerBlue;
btnmostarcontroles.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
btnmostarcontroles.ForeColor = System.Drawing.SystemColors.ButtonFace;
btnmostarcontroles.Location = new System.Drawing.Point(728, 78);
btnmostarcontroles.Name = "btnmostarcontroles";
btnmostarcontroles.Size = new System.Drawing.Size(36, 23);
btnmostarcontroles.TabIndex = 25;
btnmostarcontroles.Text = "+";
btnmostarcontroles.UseVisualStyleBackColor = false;
btnmostarcontroles.Click += btnmostarcontroles_Click;
//
// BtnAggregarPersonal
//
BtnAggregarPersonal.BackColor = System.Drawing.Color.DarkSlateGray;
BtnAggregarPersonal.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
BtnAggregarPersonal.ForeColor = System.Drawing.SystemColors.ButtonFace;
BtnAggregarPersonal.Location = new System.Drawing.Point(686, 105);
BtnAggregarPersonal.Name = "BtnAggregarPersonal";
BtnAggregarPersonal.Size = new System.Drawing.Size(36, 23);
BtnAggregarPersonal.TabIndex = 24;
BtnAggregarPersonal.Text = "+";
BtnAggregarPersonal.UseVisualStyleBackColor = false;
BtnAggregarPersonal.Visible = false;
BtnAggregarPersonal.Click += BtnAggregarPersonal_Click;
//
// button1
//
button1.BackColor = System.Drawing.Color.CornflowerBlue;
button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
button1.ForeColor = System.Drawing.SystemColors.ButtonFace;
button1.Location = new System.Drawing.Point(101, 107);
button1.Name = "button1";
button1.Size = new System.Drawing.Size(36, 23);
button1.TabIndex = 23;
button1.Text = "🔎";
button1.UseVisualStyleBackColor = false;
button1.Visible = false;
//
// TxtPersonal
//
TxtPersonal.Enabled = false;
TxtPersonal.Location = new System.Drawing.Point(132, 107);
TxtPersonal.Name = "TxtPersonal";
TxtPersonal.Size = new System.Drawing.Size(545, 23);
TxtPersonal.TabIndex = 22;
TxtPersonal.Visible = false;
//
// TxtCodigo
//
TxtCodigo.Location = new System.Drawing.Point(6, 107);
TxtCodigo.Name = "TxtCodigo";
TxtCodigo.Size = new System.Drawing.Size(100, 23);
TxtCodigo.TabIndex = 21;
TxtCodigo.Visible = false;
TxtCodigo.KeyUp += TxtCodigo_KeyUp;
//
// LblSubProyecto
//
LblSubProyecto.AutoSize = true;
LblSubProyecto.Location = new System.Drawing.Point(6, 16);
LblSubProyecto.Name = "LblSubProyecto";
LblSubProyecto.Size = new System.Drawing.Size(98, 15);
LblSubProyecto.TabIndex = 20;
LblSubProyecto.Text = "Centro de Costos";
LblSubProyecto.Visible = false;
//
// DdlSubProyecto
//
DdlSubProyecto.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppend;
DdlSubProyecto.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems;
DdlSubProyecto.DisplayMember = "SubProyecto";
DdlSubProyecto.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
DdlSubProyecto.FormattingEnabled = true;
DdlSubProyecto.Location = new System.Drawing.Point(6, 34);
DdlSubProyecto.Name = "DdlSubProyecto";
DdlSubProyecto.Size = new System.Drawing.Size(733, 23);
DdlSubProyecto.TabIndex = 19;
DdlSubProyecto.Tag = "SubProyecto";
DdlSubProyecto.ValueMember = "CveSubProyecto";
DdlSubProyecto.Visible = false;
//
// BtnActualizar
//
BtnActualizar.BackColor = System.Drawing.Color.DarkSlateGray;
BtnActualizar.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
BtnActualizar.ForeColor = System.Drawing.SystemColors.ButtonFace;
BtnActualizar.Location = new System.Drawing.Point(686, 78);
BtnActualizar.Name = "BtnActualizar";
BtnActualizar.Size = new System.Drawing.Size(36, 23);
BtnActualizar.TabIndex = 18;
BtnActualizar.Text = "🗘";
BtnActualizar.UseVisualStyleBackColor = false;
BtnActualizar.Click += BtnRefresh_Click;
//
// chkMostrarTodos
//
chkMostrarTodos.AutoSize = true;
chkMostrarTodos.Location = new System.Drawing.Point(6, 156);
chkMostrarTodos.Name = "chkMostrarTodos";
chkMostrarTodos.Size = new System.Drawing.Size(181, 19);
chkMostrarTodos.TabIndex = 16;
chkMostrarTodos.Text = "Mostrar todos los checadores";
chkMostrarTodos.UseVisualStyleBackColor = true;
//
// tabvalidacion
//
tabvalidacion.Controls.Add(dataGridView1);
tabvalidacion.Controls.Add(label1);
tabvalidacion.Controls.Add(panel1);
tabvalidacion.Location = new System.Drawing.Point(4, 24);
tabvalidacion.Name = "tabvalidacion";
tabvalidacion.Padding = new System.Windows.Forms.Padding(3);
tabvalidacion.Size = new System.Drawing.Size(915, 454);
tabvalidacion.TabIndex = 1;
tabvalidacion.Text = "Validación";
tabvalidacion.UseVisualStyleBackColor = true;
//
// dataGridView1
//
dataGridView1.AllowUserToAddRows = false;
dataGridView1.AllowUserToDeleteRows = false;
dataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
dataGridView1.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { dataGridViewTextBoxColumn1, dataGridViewTextBoxColumn2, CentrodeCostos, CvePersonal, CodigoNombreCompleto });
dataGridView1.Location = new System.Drawing.Point(16, 64);
dataGridView1.Name = "dataGridView1";
dataGridView1.RowHeadersVisible = false;
dataGridView1.Size = new System.Drawing.Size(843, 185);
dataGridView1.TabIndex = 23;
//
// dataGridViewTextBoxColumn1
//
dataGridViewTextBoxColumn1.DataPropertyName = "cveChecador";
dataGridViewTextBoxColumn1.HeaderText = "CveChecador";
dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
dataGridViewTextBoxColumn1.ReadOnly = true;
dataGridViewTextBoxColumn1.Visible = false;
//
// dataGridViewTextBoxColumn2
//
dataGridViewTextBoxColumn2.DataPropertyName = "checador";
dataGridViewTextBoxColumn2.HeaderText = "Checador";
dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
dataGridViewTextBoxColumn2.ReadOnly = true;
//
// CentrodeCostos
//
CentrodeCostos.DataPropertyName = "subProyecto";
CentrodeCostos.HeaderText = "Centro de costos";
CentrodeCostos.Name = "CentrodeCostos";
CentrodeCostos.ReadOnly = true;
//
// CvePersonal
//
CvePersonal.DataPropertyName = "cvePersonal";
CvePersonal.HeaderText = "CvePersonal";
CvePersonal.Name = "CvePersonal";
CvePersonal.ReadOnly = true;
CvePersonal.Visible = false;
//
// CodigoNombreCompleto
//
CodigoNombreCompleto.DataPropertyName = "CodigoNombreCompleto";
CodigoNombreCompleto.FillWeight = 400F;
CodigoNombreCompleto.HeaderText = "Empleado";
CodigoNombreCompleto.Name = "CodigoNombreCompleto";
CodigoNombreCompleto.ReadOnly = true;
//
// label1
//
label1.AutoSize = true;
label1.Location = new System.Drawing.Point(16, 29);
label1.Name = "label1";
label1.Size = new System.Drawing.Size(177, 15);
label1.TabIndex = 22;
label1.Text = "Registros pendientes de vincular";
//
// panel1
//
panel1.Controls.Add(LblChecadorseleccionado);
panel1.Controls.Add(TxtNombrevinculo);
panel1.Controls.Add(Ddlchecador);
panel1.Controls.Add(TxtNombreRegistro);
panel1.Controls.Add(lblregistrochecador);
panel1.Controls.Add(label2);
panel1.Location = new System.Drawing.Point(16, 255);
panel1.Name = "panel1";
panel1.Size = new System.Drawing.Size(843, 179);
panel1.TabIndex = 21;
panel1.Visible = false;
//
// LblChecadorseleccionado
//
LblChecadorseleccionado.AutoSize = true;
LblChecadorseleccionado.Location = new System.Drawing.Point(23, 28);
LblChecadorseleccionado.Name = "LblChecadorseleccionado";
LblChecadorseleccionado.Size = new System.Drawing.Size(243, 15);
LblChecadorseleccionado.TabIndex = 20;
LblChecadorseleccionado.Text = "Seleccione un checador para validar usuarios";
//
// TxtNombrevinculo
//
TxtNombrevinculo.Location = new System.Drawing.Point(23, 136);
TxtNombrevinculo.Name = "TxtNombrevinculo";
TxtNombrevinculo.Size = new System.Drawing.Size(447, 23);
TxtNombrevinculo.TabIndex = 18;
//
// Ddlchecador
//
Ddlchecador.DisplayMember = "Checador";
Ddlchecador.FormattingEnabled = true;
Ddlchecador.Location = new System.Drawing.Point(23, 46);
Ddlchecador.Name = "Ddlchecador";
Ddlchecador.Size = new System.Drawing.Size(497, 23);
Ddlchecador.TabIndex = 14;
Ddlchecador.ValueMember = "CveChecador";
//
// TxtNombreRegistro
//
TxtNombreRegistro.Location = new System.Drawing.Point(23, 91);
TxtNombreRegistro.Name = "TxtNombreRegistro";
TxtNombreRegistro.Size = new System.Drawing.Size(447, 23);
TxtNombreRegistro.TabIndex = 17;
//
// lblregistrochecador
//
lblregistrochecador.AutoSize = true;
lblregistrochecador.Location = new System.Drawing.Point(23, 72);
lblregistrochecador.Name = "lblregistrochecador";
lblregistrochecador.Size = new System.Drawing.Size(168, 15);
lblregistrochecador.TabIndex = 15;
lblregistrochecador.Text = "Registrado en checador como:";
//
// label2
//
label2.AutoSize = true;
label2.Location = new System.Drawing.Point(23, 117);
label2.Name = "label2";
label2.Size = new System.Drawing.Size(123, 15);
label2.TabIndex = 16;
label2.Text = "Vinculado al personal:";
//
// FrmNewPersonalChecador
//
AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
ClientSize = new System.Drawing.Size(943, 506);
Controls.Add(tabpanel);
Name = "FrmNewPersonalChecador";
Text = "FrmNewPersonalChecador";
Load += FrmNewPersonalChecador_Load;
GBoxHuellas.ResumeLayout(false);
GBoxHuellas.PerformLayout();
((System.ComponentModel.ISupportInitialize)Huella3).EndInit();
((System.ComponentModel.ISupportInitialize)Huella2).EndInit();
((System.ComponentModel.ISupportInitialize)Huella1).EndInit();
((System.ComponentModel.ISupportInitialize)DGVChecadores).EndInit();
((System.ComponentModel.ISupportInitialize)ImgLoader).EndInit();
tabpanel.ResumeLayout(false);
tabRegistro.ResumeLayout(false);
tabRegistro.PerformLayout();
tabvalidacion.ResumeLayout(false);
tabvalidacion.PerformLayout();
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
panel1.ResumeLayout(false);
panel1.PerformLayout();
ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label LblEmpleado;
private System.Windows.Forms.GroupBox GBoxHuellas;
private System.Windows.Forms.ComboBox DdlEmpleados;
private System.Windows.Forms.PictureBox Huella3;
private System.Windows.Forms.PictureBox Huella2;
private System.Windows.Forms.PictureBox Huella1;
private System.Windows.Forms.TextBox textRes;
private System.Windows.Forms.DataGridView DGVChecadores;
private System.Windows.Forms.DataGridViewCheckBoxColumn Seleccionar;
private System.Windows.Forms.DataGridViewTextBoxColumn cveChecador;
private System.Windows.Forms.DataGridViewTextBoxColumn checador;
private System.Windows.Forms.DataGridViewTextBoxColumn subProyecto;
private System.Windows.Forms.DataGridViewCheckBoxColumn Vinculado;
private System.Windows.Forms.DataGridViewTextBoxColumn iPLocal;
private System.Windows.Forms.DataGridViewTextBoxColumn puerto;
private System.Windows.Forms.PictureBox ImgLoader;
private FontAwesome.Sharp.IconButton BtnCapturarHuella;
private FontAwesome.Sharp.IconButton BtnRefresh;
private System.Windows.Forms.TabControl tabpanel;
private System.Windows.Forms.TabPage tabRegistro;
private System.Windows.Forms.TabPage tabvalidacion;
private FontAwesome.Sharp.IconButton BtnValidar;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.TextBox TxtNombreRegistro;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label lblregistrochecador;
private System.Windows.Forms.ComboBox Ddlchecador;
private System.Windows.Forms.TextBox TxtNombrevinculo;
private System.Windows.Forms.Label LblChecadorseleccionado;
private FontAwesome.Sharp.IconButton BtnCancelar;
private System.Windows.Forms.CheckBox ChkVincularsinhuella;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.ComboBox ddlChek;
private System.Windows.Forms.CheckBox chkMostrarTodos;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
private System.Windows.Forms.DataGridViewTextBoxColumn CentrodeCostos;
private System.Windows.Forms.DataGridViewTextBoxColumn CvePersonal;
private System.Windows.Forms.DataGridViewTextBoxColumn CodigoNombreCompleto;
private System.Windows.Forms.Button BtnVincular;
private System.Windows.Forms.Button btnCancelar;
private System.Windows.Forms.Button BtnActualizar;
private System.Windows.Forms.ComboBox DdlSubProyecto;
private System.Windows.Forms.Label LblSubProyecto;
private System.Windows.Forms.Button BtnAggregarPersonal;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.TextBox TxtPersonal;
private System.Windows.Forms.TextBox TxtCodigo;
private System.Windows.Forms.Button btnmostarcontroles;
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,141 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="iPLocal.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="puerto.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="CentrodeCostos.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="CvePersonal.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="CodigoNombreCompleto.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>

View File

@@ -0,0 +1,164 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmPersonal
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
comboBox1 = new System.Windows.Forms.ComboBox();
label1 = new System.Windows.Forms.Label();
groupBox1 = new System.Windows.Forms.GroupBox();
dataGridView1 = new System.Windows.Forms.DataGridView();
upPersonal = new System.Windows.Forms.DataGridViewCheckBoxColumn();
Codigo = new System.Windows.Forms.DataGridViewTextBoxColumn();
Personal = new System.Windows.Forms.DataGridViewTextBoxColumn();
Centrocosto = new System.Windows.Forms.DataGridViewTextBoxColumn();
Checador = new System.Windows.Forms.DataGridViewTextBoxColumn();
button1 = new System.Windows.Forms.Button();
groupBox1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
SuspendLayout();
//
// comboBox1
//
comboBox1.FormattingEnabled = true;
comboBox1.Location = new System.Drawing.Point(184, 10);
comboBox1.Name = "comboBox1";
comboBox1.Size = new System.Drawing.Size(349, 23);
comboBox1.TabIndex = 2;
//
// label1
//
label1.AutoSize = true;
label1.Location = new System.Drawing.Point(21, 13);
label1.Name = "label1";
label1.Size = new System.Drawing.Size(132, 15);
label1.TabIndex = 3;
label1.Text = "Seleccione un checador";
//
// groupBox1
//
groupBox1.Controls.Add(dataGridView1);
groupBox1.Location = new System.Drawing.Point(21, 65);
groupBox1.Name = "groupBox1";
groupBox1.Size = new System.Drawing.Size(608, 342);
groupBox1.TabIndex = 4;
groupBox1.TabStop = false;
groupBox1.Text = "Personal";
//
// dataGridView1
//
dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { upPersonal, Codigo, Personal, Centrocosto, Checador });
dataGridView1.Location = new System.Drawing.Point(0, 22);
dataGridView1.Name = "dataGridView1";
dataGridView1.Size = new System.Drawing.Size(604, 314);
dataGridView1.TabIndex = 0;
dataGridView1.Text = "dataGridView1";
//
// upPersonal
//
upPersonal.FillWeight = 40F;
upPersonal.HeaderText = "";
upPersonal.Name = "upPersonal";
upPersonal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
upPersonal.Width = 40;
//
// Codigo
//
Codigo.FillWeight = 50F;
Codigo.HeaderText = "Codigo";
Codigo.Name = "Codigo";
Codigo.ReadOnly = true;
Codigo.Resizable = System.Windows.Forms.DataGridViewTriState.True;
Codigo.Width = 50;
//
// Personal
//
Personal.FillWeight = 250F;
Personal.HeaderText = "Personal";
Personal.Name = "Personal";
Personal.ReadOnly = true;
Personal.Resizable = System.Windows.Forms.DataGridViewTriState.True;
Personal.Width = 250;
//
// Centrocosto
//
Centrocosto.FillWeight = 120F;
Centrocosto.HeaderText = "Centro de costo";
Centrocosto.Name = "Centrocosto";
Centrocosto.ReadOnly = true;
Centrocosto.Resizable = System.Windows.Forms.DataGridViewTriState.True;
Centrocosto.Width = 120;
//
// Checador
//
Checador.HeaderText = "Checador";
Checador.Name = "Checador";
Checador.ReadOnly = true;
Checador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
//
// button1
//
button1.Location = new System.Drawing.Point(554, 13);
button1.Name = "button1";
button1.Size = new System.Drawing.Size(75, 23);
button1.TabIndex = 5;
button1.Text = "Actualizar";
button1.UseVisualStyleBackColor = true;
//
// FrmPersonal
//
AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
ClientSize = new System.Drawing.Size(693, 450);
Controls.Add(button1);
Controls.Add(groupBox1);
Controls.Add(label1);
Controls.Add(comboBox1);
Name = "FrmPersonal";
Text = "FrmPersonal";
groupBox1.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
ResumeLayout(false);
PerformLayout();
}
#endregion
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.DataGridViewCheckBoxColumn upPersonal;
private System.Windows.Forms.DataGridViewTextBoxColumn Codigo;
private System.Windows.Forms.DataGridViewTextBoxColumn Personal;
private System.Windows.Forms.DataGridViewTextBoxColumn Centrocosto;
private System.Windows.Forms.DataGridViewTextBoxColumn Checador;
private System.Windows.Forms.Button button1;
}
}

View File

@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmPersonal : Form
{
public FrmPersonal()
{
InitializeComponent();
}
}
}

View File

@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,278 @@
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmPersonalChecador
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.btnMinimize = new FontAwesome.Sharp.IconButton();
this.btnMaximise = new FontAwesome.Sharp.IconButton();
this.btnClose = new FontAwesome.Sharp.IconButton();
this.panel1 = new System.Windows.Forms.Panel();
this.BtnCancel = new System.Windows.Forms.Button();
this.Btnok = new System.Windows.Forms.Button();
this.LblEmpleado = new System.Windows.Forms.Label();
this.DdlChecador = new System.Windows.Forms.ComboBox();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.GrpSeleccioneAsociar = new System.Windows.Forms.GroupBox();
this.rdbAsociar = new System.Windows.Forms.RadioButton();
this.rdbAgregar = new System.Windows.Forms.RadioButton();
this.rdbDesasociar = new System.Windows.Forms.RadioButton();
this.panel1.SuspendLayout();
this.groupBox1.SuspendLayout();
this.GrpSeleccioneAsociar.SuspendLayout();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Open Sans", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point);
this.label1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.label1.Location = new System.Drawing.Point(15, 5);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(153, 22);
this.label1.TabIndex = 1;
this.label1.Text = "Asociar personal";
//
// btnMinimize
//
this.btnMinimize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnMinimize.FlatAppearance.BorderSize = 0;
this.btnMinimize.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnMinimize.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnMinimize.IconChar = FontAwesome.Sharp.IconChar.WindowMinimize;
this.btnMinimize.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnMinimize.IconSize = 20;
this.btnMinimize.Location = new System.Drawing.Point(529, 1);
this.btnMinimize.Name = "btnMinimize";
this.btnMinimize.Rotation = 0D;
this.btnMinimize.Size = new System.Drawing.Size(30, 28);
this.btnMinimize.TabIndex = 0;
this.btnMinimize.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.btnMinimize.UseVisualStyleBackColor = true;
this.btnMinimize.Click += new System.EventHandler(this.btnMinimize_Click);
//
// btnMaximise
//
this.btnMaximise.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnMaximise.FlatAppearance.BorderSize = 0;
this.btnMaximise.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnMaximise.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnMaximise.IconChar = FontAwesome.Sharp.IconChar.WindowMaximize;
this.btnMaximise.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnMaximise.IconSize = 20;
this.btnMaximise.Location = new System.Drawing.Point(559, 1);
this.btnMaximise.Name = "btnMaximise";
this.btnMaximise.Rotation = 0D;
this.btnMaximise.Size = new System.Drawing.Size(30, 28);
this.btnMaximise.TabIndex = 0;
this.btnMaximise.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.btnMaximise.UseVisualStyleBackColor = true;
this.btnMaximise.Click += new System.EventHandler(this.btnMaximise_Click);
//
// btnClose
//
this.btnClose.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.btnClose.FlatAppearance.BorderSize = 0;
this.btnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.btnClose.Flip = FontAwesome.Sharp.FlipOrientation.Normal;
this.btnClose.IconChar = FontAwesome.Sharp.IconChar.Times;
this.btnClose.IconColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(188)))), ((int)(((byte)(200)))));
this.btnClose.IconSize = 20;
this.btnClose.Location = new System.Drawing.Point(589, 1);
this.btnClose.Name = "btnClose";
this.btnClose.Rotation = 0D;
this.btnClose.Size = new System.Drawing.Size(30, 28);
this.btnClose.TabIndex = 0;
this.btnClose.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageBeforeText;
this.btnClose.UseVisualStyleBackColor = true;
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
//
// panel1
//
this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(43)))), ((int)(((byte)(54)))), ((int)(((byte)(67)))));
this.panel1.Controls.Add(this.label1);
this.panel1.Controls.Add(this.btnMinimize);
this.panel1.Controls.Add(this.btnMaximise);
this.panel1.Controls.Add(this.btnClose);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(620, 30);
this.panel1.TabIndex = 1;
this.panel1.MouseDown += new System.Windows.Forms.MouseEventHandler(this.ArrastrarForm_MouseDown);
//
// BtnCancel
//
this.BtnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.BtnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.BtnCancel.Location = new System.Drawing.Point(516, 302);
this.BtnCancel.Name = "BtnCancel";
this.BtnCancel.Size = new System.Drawing.Size(94, 35);
this.BtnCancel.TabIndex = 7;
this.BtnCancel.Text = "Cancel";
this.BtnCancel.UseVisualStyleBackColor = true;
this.BtnCancel.Click += new System.EventHandler(this.BtnCancel_Click);
//
// Btnok
//
this.Btnok.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.Btnok.Location = new System.Drawing.Point(416, 302);
this.Btnok.Name = "Btnok";
this.Btnok.Size = new System.Drawing.Size(94, 35);
this.Btnok.TabIndex = 6;
this.Btnok.Text = "Asociar";
this.Btnok.UseVisualStyleBackColor = true;
this.Btnok.Click += new System.EventHandler(this.BtnOK_Click);
//
// LblEmpleado
//
this.LblEmpleado.AutoSize = true;
this.LblEmpleado.Location = new System.Drawing.Point(6, 36);
this.LblEmpleado.Name = "LblEmpleado";
this.LblEmpleado.Size = new System.Drawing.Size(79, 21);
this.LblEmpleado.TabIndex = 8;
this.LblEmpleado.Text = "Empleado";
//
// DdlChecador
//
this.DdlChecador.FormattingEnabled = true;
this.DdlChecador.Location = new System.Drawing.Point(6, 39);
this.DdlChecador.Name = "DdlChecador";
this.DdlChecador.Size = new System.Drawing.Size(564, 29);
this.DdlChecador.TabIndex = 11;
this.DdlChecador.SelectedIndexChanged += new System.EventHandler(this.DdlChecador_SelectedIndexChanged);
//
// groupBox1
//
this.groupBox1.Controls.Add(this.LblEmpleado);
this.groupBox1.Location = new System.Drawing.Point(19, 48);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(589, 75);
this.groupBox1.TabIndex = 12;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "Datos empleado";
//
// GrpSeleccioneAsociar
//
this.GrpSeleccioneAsociar.Controls.Add(this.DdlChecador);
this.GrpSeleccioneAsociar.Location = new System.Drawing.Point(19, 198);
this.GrpSeleccioneAsociar.Name = "GrpSeleccioneAsociar";
this.GrpSeleccioneAsociar.Size = new System.Drawing.Size(589, 85);
this.GrpSeleccioneAsociar.TabIndex = 13;
this.GrpSeleccioneAsociar.TabStop = false;
this.GrpSeleccioneAsociar.Text = "Seleccione";
//
// rdbAsociar
//
this.rdbAsociar.AutoSize = true;
this.rdbAsociar.Checked = true;
this.rdbAsociar.Location = new System.Drawing.Point(25, 147);
this.rdbAsociar.Name = "rdbAsociar";
this.rdbAsociar.Size = new System.Drawing.Size(79, 25);
this.rdbAsociar.TabIndex = 14;
this.rdbAsociar.TabStop = true;
this.rdbAsociar.Text = "Asociar";
this.rdbAsociar.UseVisualStyleBackColor = true;
this.rdbAsociar.Click += new System.EventHandler(this.rdbAsociar_Click);
//
// rdbAgregar
//
this.rdbAgregar.AutoSize = true;
this.rdbAgregar.Location = new System.Drawing.Point(166, 147);
this.rdbAgregar.Name = "rdbAgregar";
this.rdbAgregar.Size = new System.Drawing.Size(163, 25);
this.rdbAgregar.TabIndex = 15;
this.rdbAgregar.TabStop = true;
this.rdbAgregar.Text = "Agregar a checador";
this.rdbAgregar.UseVisualStyleBackColor = true;
this.rdbAgregar.Visible = false;
this.rdbAgregar.Click += new System.EventHandler(this.rdbAgregar_Click);
//
// rdbDesasociar
//
this.rdbDesasociar.AutoSize = true;
this.rdbDesasociar.Location = new System.Drawing.Point(388, 147);
this.rdbDesasociar.Name = "rdbDesasociar";
this.rdbDesasociar.Size = new System.Drawing.Size(103, 25);
this.rdbDesasociar.TabIndex = 16;
this.rdbDesasociar.TabStop = true;
this.rdbDesasociar.Text = "Desasociar";
this.rdbDesasociar.UseVisualStyleBackColor = true;
this.rdbDesasociar.Visible = false;
this.rdbDesasociar.Click += new System.EventHandler(this.rdbDesasociar_Click);
//
// FrmPersonalChecador
//
this.AcceptButton = this.Btnok;
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.CancelButton = this.BtnCancel;
this.ClientSize = new System.Drawing.Size(620, 360);
this.ControlBox = false;
this.Controls.Add(this.rdbDesasociar);
this.Controls.Add(this.rdbAgregar);
this.Controls.Add(this.rdbAsociar);
this.Controls.Add(this.GrpSeleccioneAsociar);
this.Controls.Add(this.groupBox1);
this.Controls.Add(this.Btnok);
this.Controls.Add(this.BtnCancel);
this.Controls.Add(this.panel1);
this.Font = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "FrmPersonalChecador";
this.ShowIcon = false;
this.ShowInTaskbar = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.groupBox1.ResumeLayout(false);
this.groupBox1.PerformLayout();
this.GrpSeleccioneAsociar.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label1;
private FontAwesome.Sharp.IconButton btnMinimize;
private FontAwesome.Sharp.IconButton btnMaximise;
private FontAwesome.Sharp.IconButton btnClose;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Button BtnCancel;
private System.Windows.Forms.Button Btnok;
private System.Windows.Forms.Label LblEmpleado;
private System.Windows.Forms.ComboBox DdlChecador;
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.GroupBox GrpSeleccioneAsociar;
private System.Windows.Forms.RadioButton rdbAsociar;
private System.Windows.Forms.RadioButton rdbAgregar;
private System.Windows.Forms.RadioButton rdbDesasociar;
}
}

View File

@@ -0,0 +1,117 @@
using ADSUtileriasWF.Helpers;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmPersonalChecador : FormBase
{
private List<WCF_Checador.PersonalChecador> empleadoschecador;
public int cvePersonal;
private int _checadorID;
public int checadorID
{
get { return _checadorID; }
set
{
_checadorID = value;
}
}
public FrmPersonalChecador(int cvePersonal, int checadorID, string nombreempleado, List<WCF_Checador.PersonalChecador> empleadoschecador)
{
InitializeComponent();
if (empleadoschecador != null)
{
List<WCF_Checador.PersonalChecador> empleados = new List<WCF_Checador.PersonalChecador>();
foreach (var emp in empleadoschecador)
{
empleados.Add(new WCF_Checador.PersonalChecador() { IdPersonal = emp.IdPersonal, Nombre = string.Format("{0} - {1}", emp.IdPersonal, emp.Nombre) });
}
if (checadorID <= 0)
{
checadorID = 0;
empleados.Insert(0, new WCF_Checador.PersonalChecador() { IdPersonal = "0", Nombre = "Sin Asociar" });
rdbAgregar.Visible = true;
}
else
{
rdbDesasociar.Visible = true;
}
//empleados.Insert(1, new WCF_Checador.PersonalChecador() { IdPersonal = "-1", Nombre = "Sin asignar en checador" });
DdlChecador.ValueMember = "IdPersonal";
DdlChecador.DisplayMember = "Nombre";
DdlChecador.DataSource = empleados;
}
LblEmpleado.Text = nombreempleado;
this.empleadoschecador = empleadoschecador;
this.cvePersonal = cvePersonal;
this.checadorID = checadorID;
}
private void BtnCancel_Click(object sender, EventArgs e)
{
this.DialogResult = System.Windows.Forms.DialogResult.Abort;
this.Close();
}
private void BtnOK_Click(object sender, EventArgs e)
{
//ObservacionesBitacora_ = TxtObservacion.Text;
this.DialogResult = System.Windows.Forms.DialogResult.OK;
this.Close();
}
private void btnClose_Click(object sender, EventArgs e)
{
this.Close();
}
private void btnMaximise_Click(object sender, EventArgs e)
{
base.BtnMaximizeRestore_Click(sender, e);
}
private void btnMinimize_Click(object sender, EventArgs e)
{
base.BtnMinimize_Click(sender, e);
}
private void DdlChecador_SelectedIndexChanged(object sender, EventArgs e)
{
this.checadorID = DdlChecador.SelectedValue.ToString().ToEntero();
}
private void rdbAgregar_Click(object sender, EventArgs e)
{
GrpSeleccioneAsociar.Visible = false;
Btnok.Text = "Agregar";
this.checadorID = -1;
}
private void rdbDesasociar_Click(object sender, EventArgs e)
{
GrpSeleccioneAsociar.Visible = false;
Btnok.Text = "Desasociar";
this.checadorID = 0;
}
private void rdbAsociar_Click(object sender, EventArgs e)
{
GrpSeleccioneAsociar.Visible = true;
Btnok.Text = "Asociar";
this.checadorID = DdlChecador.SelectedValue.ToString().ToEntero();
}
//private void numericUpDown1_ValueChanged(object sender, EventArgs e)
//{
// this.checadorID = txtchecadorID.Value.ToString().ToEntero();
//}
}
}

View File

@@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,456 @@

namespace ADSUtileriasWF.Views.RelojChecador.Views
{
partial class FrmSistema
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
Sincronizacion = new System.Windows.Forms.TabControl();
tabPage1 = new System.Windows.Forms.TabPage();
lblSincronizados = new System.Windows.Forms.TabControl();
tabPage5 = new System.Windows.Forms.TabPage();
button1 = new System.Windows.Forms.Button();
ImgLoader = new System.Windows.Forms.PictureBox();
DGVChecadores = new System.Windows.Forms.DataGridView();
Seleccionar = new System.Windows.Forms.DataGridViewCheckBoxColumn();
cveChecador = new System.Windows.Forms.DataGridViewTextBoxColumn();
checador = new System.Windows.Forms.DataGridViewTextBoxColumn();
IpLocal = new System.Windows.Forms.DataGridViewTextBoxColumn();
Puerto = new System.Windows.Forms.DataGridViewTextBoxColumn();
Estatus = new System.Windows.Forms.DataGridViewTextBoxColumn();
tabPage6 = new System.Windows.Forms.TabPage();
DTGVPersonal = new System.Windows.Forms.DataGridView();
tabPage7 = new System.Windows.Forms.TabPage();
tabPage2 = new System.Windows.Forms.TabPage();
Tabsincronizacion = new System.Windows.Forms.TabControl();
tabPage3 = new System.Windows.Forms.TabPage();
DGVAsistensincaSincronizar = new System.Windows.Forms.DataGridView();
CvePersonal = new System.Windows.Forms.DataGridViewTextBoxColumn();
CodigoNombreCompleto = new System.Windows.Forms.DataGridViewTextBoxColumn();
Fecha = new System.Windows.Forms.DataGridViewTextBoxColumn();
tabPage4 = new System.Windows.Forms.TabPage();
dataGridView1 = new System.Windows.Forms.DataGridView();
dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
dwEnrollNumber = new System.Windows.Forms.DataGridViewTextBoxColumn();
Enabled = new System.Windows.Forms.DataGridViewTextBoxColumn();
Namet = new System.Windows.Forms.DataGridViewTextBoxColumn();
Password = new System.Windows.Forms.DataGridViewTextBoxColumn();
Sincronizacion.SuspendLayout();
tabPage1.SuspendLayout();
lblSincronizados.SuspendLayout();
tabPage5.SuspendLayout();
((System.ComponentModel.ISupportInitialize)ImgLoader).BeginInit();
((System.ComponentModel.ISupportInitialize)DGVChecadores).BeginInit();
tabPage6.SuspendLayout();
((System.ComponentModel.ISupportInitialize)DTGVPersonal).BeginInit();
tabPage2.SuspendLayout();
Tabsincronizacion.SuspendLayout();
tabPage3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)DGVAsistensincaSincronizar).BeginInit();
tabPage4.SuspendLayout();
((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit();
SuspendLayout();
//
// Sincronizacion
//
Sincronizacion.Controls.Add(tabPage1);
Sincronizacion.Controls.Add(tabPage2);
Sincronizacion.Dock = System.Windows.Forms.DockStyle.Fill;
Sincronizacion.Location = new System.Drawing.Point(0, 0);
Sincronizacion.Name = "Sincronizacion";
Sincronizacion.SelectedIndex = 0;
Sincronizacion.Size = new System.Drawing.Size(800, 450);
Sincronizacion.TabIndex = 0;
Sincronizacion.SelectedIndexChanged += Sincronizacion_SelectedIndexChanged;
//
// tabPage1
//
tabPage1.Controls.Add(lblSincronizados);
tabPage1.Location = new System.Drawing.Point(4, 24);
tabPage1.Name = "tabPage1";
tabPage1.Padding = new System.Windows.Forms.Padding(3);
tabPage1.Size = new System.Drawing.Size(792, 422);
tabPage1.TabIndex = 0;
tabPage1.Text = "Checadores";
tabPage1.UseVisualStyleBackColor = true;
//
// lblSincronizados
//
lblSincronizados.Controls.Add(tabPage5);
lblSincronizados.Controls.Add(tabPage6);
lblSincronizados.Controls.Add(tabPage7);
lblSincronizados.Location = new System.Drawing.Point(4, 25);
lblSincronizados.Name = "lblSincronizados";
lblSincronizados.SelectedIndex = 0;
lblSincronizados.Size = new System.Drawing.Size(780, 389);
lblSincronizados.TabIndex = 10;
//
// tabPage5
//
tabPage5.Controls.Add(button1);
tabPage5.Controls.Add(ImgLoader);
tabPage5.Controls.Add(DGVChecadores);
tabPage5.Location = new System.Drawing.Point(4, 24);
tabPage5.Name = "tabPage5";
tabPage5.Padding = new System.Windows.Forms.Padding(3);
tabPage5.Size = new System.Drawing.Size(772, 361);
tabPage5.TabIndex = 0;
tabPage5.Text = "Estatus";
tabPage5.UseVisualStyleBackColor = true;
//
// button1
//
button1.BackColor = System.Drawing.Color.DarkCyan;
button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
button1.ForeColor = System.Drawing.SystemColors.HighlightText;
button1.Location = new System.Drawing.Point(526, 22);
button1.Name = "button1";
button1.Size = new System.Drawing.Size(144, 23);
button1.TabIndex = 18;
button1.Text = "Actualizar";
button1.UseVisualStyleBackColor = false;
button1.Click += BtnRefresh_Click;
//
// ImgLoader
//
ImgLoader.Image = Properties.Resources.Loader;
ImgLoader.Location = new System.Drawing.Point(688, 22);
ImgLoader.Name = "ImgLoader";
ImgLoader.Size = new System.Drawing.Size(34, 23);
ImgLoader.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
ImgLoader.TabIndex = 17;
ImgLoader.TabStop = false;
//
// DGVChecadores
//
DGVChecadores.AllowUserToAddRows = false;
DGVChecadores.AllowUserToDeleteRows = false;
DGVChecadores.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
DGVChecadores.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
DGVChecadores.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
DGVChecadores.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
DGVChecadores.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { Seleccionar, cveChecador, checador, IpLocal, Puerto, Estatus });
DGVChecadores.Location = new System.Drawing.Point(3, 51);
DGVChecadores.Name = "DGVChecadores";
DGVChecadores.RowHeadersVisible = false;
DGVChecadores.Size = new System.Drawing.Size(766, 267);
DGVChecadores.TabIndex = 9;
DGVChecadores.Text = "DGVChecadores";
//
// Seleccionar
//
Seleccionar.FillWeight = 20F;
Seleccionar.HeaderText = "✔";
Seleccionar.Name = "Seleccionar";
Seleccionar.Resizable = System.Windows.Forms.DataGridViewTriState.True;
Seleccionar.Visible = false;
//
// cveChecador
//
cveChecador.DataPropertyName = "cveChecador";
cveChecador.HeaderText = "cveChecador";
cveChecador.Name = "cveChecador";
cveChecador.ReadOnly = true;
cveChecador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
cveChecador.Visible = false;
//
// checador
//
checador.DataPropertyName = "checador";
checador.FillWeight = 106.9035F;
checador.HeaderText = "Checador";
checador.Name = "checador";
checador.ReadOnly = true;
checador.Resizable = System.Windows.Forms.DataGridViewTriState.True;
checador.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
//
// IpLocal
//
IpLocal.DataPropertyName = "IpLocal";
IpLocal.HeaderText = "IP";
IpLocal.Name = "IpLocal";
IpLocal.ReadOnly = true;
//
// Puerto
//
Puerto.DataPropertyName = "puerto";
Puerto.HeaderText = "Puerto";
Puerto.Name = "Puerto";
Puerto.ReadOnly = true;
//
// Estatus
//
Estatus.DataPropertyName = "EstatusConexion";
Estatus.FillWeight = 60F;
Estatus.HeaderText = "Estatus";
Estatus.Name = "Estatus";
Estatus.ReadOnly = true;
//
// tabPage6
//
tabPage6.Controls.Add(DTGVPersonal);
tabPage6.Location = new System.Drawing.Point(4, 24);
tabPage6.Name = "tabPage6";
tabPage6.Padding = new System.Windows.Forms.Padding(3);
tabPage6.Size = new System.Drawing.Size(772, 361);
tabPage6.TabIndex = 1;
tabPage6.Text = "Personal";
tabPage6.UseVisualStyleBackColor = true;
//
// DTGVPersonal
//
DTGVPersonal.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
DTGVPersonal.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
DTGVPersonal.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
DTGVPersonal.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { Password, Namet, Enabled, dwEnrollNumber });
DTGVPersonal.Location = new System.Drawing.Point(4, 52);
DTGVPersonal.Name = "DTGVPersonal";
DTGVPersonal.RowHeadersVisible = false;
DTGVPersonal.RowTemplate.Height = 25;
DTGVPersonal.Size = new System.Drawing.Size(765, 247);
DTGVPersonal.TabIndex = 0;
//
// tabPage7
//
tabPage7.Location = new System.Drawing.Point(4, 24);
tabPage7.Name = "tabPage7";
tabPage7.Padding = new System.Windows.Forms.Padding(3);
tabPage7.Size = new System.Drawing.Size(772, 361);
tabPage7.TabIndex = 2;
tabPage7.Text = "Checadores Sincronizados";
tabPage7.UseVisualStyleBackColor = true;
//
// tabPage2
//
tabPage2.Controls.Add(Tabsincronizacion);
tabPage2.Location = new System.Drawing.Point(4, 24);
tabPage2.Name = "tabPage2";
tabPage2.Padding = new System.Windows.Forms.Padding(3);
tabPage2.Size = new System.Drawing.Size(792, 422);
tabPage2.TabIndex = 1;
tabPage2.Text = "Sincronización";
tabPage2.UseVisualStyleBackColor = true;
//
// Tabsincronizacion
//
Tabsincronizacion.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
Tabsincronizacion.Controls.Add(tabPage3);
Tabsincronizacion.Controls.Add(tabPage4);
Tabsincronizacion.Location = new System.Drawing.Point(8, 29);
Tabsincronizacion.Name = "Tabsincronizacion";
Tabsincronizacion.SelectedIndex = 0;
Tabsincronizacion.Size = new System.Drawing.Size(776, 385);
Tabsincronizacion.TabIndex = 0;
//
// tabPage3
//
tabPage3.Controls.Add(DGVAsistensincaSincronizar);
tabPage3.Location = new System.Drawing.Point(4, 24);
tabPage3.Name = "tabPage3";
tabPage3.Padding = new System.Windows.Forms.Padding(3);
tabPage3.Size = new System.Drawing.Size(768, 357);
tabPage3.TabIndex = 0;
tabPage3.Text = "Asistencia";
tabPage3.UseVisualStyleBackColor = true;
//
// DGVAsistensincaSincronizar
//
DGVAsistensincaSincronizar.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
DGVAsistensincaSincronizar.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
DGVAsistensincaSincronizar.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
DGVAsistensincaSincronizar.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { CvePersonal, CodigoNombreCompleto, Fecha });
DGVAsistensincaSincronizar.Location = new System.Drawing.Point(4, 22);
DGVAsistensincaSincronizar.Name = "DGVAsistensincaSincronizar";
DGVAsistensincaSincronizar.RowHeadersVisible = false;
DGVAsistensincaSincronizar.RowTemplate.Height = 25;
DGVAsistensincaSincronizar.Size = new System.Drawing.Size(744, 305);
DGVAsistensincaSincronizar.TabIndex = 0;
//
// CvePersonal
//
CvePersonal.DataPropertyName = "CvePersonal";
CvePersonal.HeaderText = "CvePersonal";
CvePersonal.Name = "CvePersonal";
CvePersonal.ReadOnly = true;
CvePersonal.Visible = false;
//
// CodigoNombreCompleto
//
CodigoNombreCompleto.DataPropertyName = "CodigoNombreCompleto";
CodigoNombreCompleto.HeaderText = "Nombre";
CodigoNombreCompleto.Name = "CodigoNombreCompleto";
CodigoNombreCompleto.ReadOnly = true;
//
// Fecha
//
Fecha.DataPropertyName = "Fecha";
Fecha.FillWeight = 40F;
Fecha.HeaderText = "Fecha";
Fecha.Name = "Fecha";
Fecha.ReadOnly = true;
//
// tabPage4
//
tabPage4.Controls.Add(dataGridView1);
tabPage4.Location = new System.Drawing.Point(4, 24);
tabPage4.Name = "tabPage4";
tabPage4.Padding = new System.Windows.Forms.Padding(3);
tabPage4.Size = new System.Drawing.Size(768, 357);
tabPage4.TabIndex = 1;
tabPage4.Text = "Personal";
tabPage4.UseVisualStyleBackColor = true;
//
// dataGridView1
//
dataGridView1.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
dataGridView1.BackgroundColor = System.Drawing.SystemColors.ActiveCaption;
dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { dataGridViewTextBoxColumn1, dataGridViewTextBoxColumn2, dataGridViewTextBoxColumn3 });
dataGridView1.Location = new System.Drawing.Point(12, 26);
dataGridView1.Name = "dataGridView1";
dataGridView1.RowHeadersVisible = false;
dataGridView1.RowTemplate.Height = 25;
dataGridView1.Size = new System.Drawing.Size(744, 305);
dataGridView1.TabIndex = 1;
//
// dataGridViewTextBoxColumn1
//
dataGridViewTextBoxColumn1.DataPropertyName = "CvePersonal";
dataGridViewTextBoxColumn1.HeaderText = "CvePersonal";
dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
dataGridViewTextBoxColumn1.ReadOnly = true;
dataGridViewTextBoxColumn1.Visible = false;
//
// dataGridViewTextBoxColumn2
//
dataGridViewTextBoxColumn2.DataPropertyName = "CodigoNombreCompleto";
dataGridViewTextBoxColumn2.HeaderText = "Nombre";
dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
dataGridViewTextBoxColumn2.ReadOnly = true;
//
// dataGridViewTextBoxColumn3
//
dataGridViewTextBoxColumn3.DataPropertyName = "Fecha";
dataGridViewTextBoxColumn3.FillWeight = 40F;
dataGridViewTextBoxColumn3.HeaderText = "Fecha";
dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
dataGridViewTextBoxColumn3.ReadOnly = true;
//
// dwEnrollNumber
//
dwEnrollNumber.DataPropertyName = "dwEnrollNumber";
dwEnrollNumber.HeaderText = "IdChecador";
dwEnrollNumber.Name = "dwEnrollNumber";
dwEnrollNumber.ReadOnly = true;
//
// Enabled
//
Enabled.FillWeight = 30F;
Enabled.HeaderText = "activo";
Enabled.Name = "Enabled";
Enabled.ReadOnly = true;
//
// Namet
//
Namet.DataPropertyName = "Name";
Namet.HeaderText = "Empleado";
Namet.Name = "Namet";
Namet.ReadOnly = true;
//
// Password
//
Password.DataPropertyName = "Password";
Password.HeaderText = "CvePersonal";
Password.Name = "Password";
Password.ReadOnly = true;
Password.Visible = false;
//
// FrmSistema
//
AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
ClientSize = new System.Drawing.Size(800, 450);
Controls.Add(Sincronizacion);
Name = "FrmSistema";
Text = "Sistema";
Load += FrmSistema_Load;
Sincronizacion.ResumeLayout(false);
tabPage1.ResumeLayout(false);
lblSincronizados.ResumeLayout(false);
tabPage5.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)ImgLoader).EndInit();
((System.ComponentModel.ISupportInitialize)DGVChecadores).EndInit();
tabPage6.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)DTGVPersonal).EndInit();
tabPage2.ResumeLayout(false);
Tabsincronizacion.ResumeLayout(false);
tabPage3.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)DGVAsistensincaSincronizar).EndInit();
tabPage4.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit();
ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TabControl Sincronizacion;
private System.Windows.Forms.TabPage tabPage1;
private System.Windows.Forms.TabPage tabPage2;
private System.Windows.Forms.DataGridView DGVChecadores;
private System.Windows.Forms.TabControl Tabsincronizacion;
private System.Windows.Forms.TabPage tabPage3;
private System.Windows.Forms.TabPage tabPage4;
private System.Windows.Forms.DataGridView DGVAsistensincaSincronizar;
private System.Windows.Forms.DataGridViewTextBoxColumn CvePersonal;
private System.Windows.Forms.DataGridViewTextBoxColumn CodigoNombreCompleto;
private System.Windows.Forms.DataGridViewTextBoxColumn Fecha;
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
private System.Windows.Forms.DataGridViewCheckBoxColumn Seleccionar;
private System.Windows.Forms.DataGridViewTextBoxColumn cveChecador;
private System.Windows.Forms.DataGridViewTextBoxColumn checador;
private System.Windows.Forms.DataGridViewTextBoxColumn IpLocal;
private System.Windows.Forms.DataGridViewTextBoxColumn Puerto;
private System.Windows.Forms.DataGridViewTextBoxColumn Estatus;
private System.Windows.Forms.TabControl lblSincronizados;
private System.Windows.Forms.TabPage tabPage5;
private System.Windows.Forms.TabPage tabPage6;
private System.Windows.Forms.DataGridView DTGVPersonal;
private FontAwesome.Sharp.IconButton BtnRefresh;
private System.Windows.Forms.PictureBox ImgLoader;
private System.Windows.Forms.TabPage tabPage7;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.DataGridViewTextBoxColumn Password;
private System.Windows.Forms.DataGridViewTextBoxColumn Namet;
private System.Windows.Forms.DataGridViewTextBoxColumn Enabled;
private System.Windows.Forms.DataGridViewTextBoxColumn dwEnrollNumber;
}
}

View File

@@ -0,0 +1,132 @@
using ADSNetLibrary.Helpers.Conexiones.ZkTeckoLib;
using ADSNetLibrary.SIGAPI.Helpers;
using ADSUtileriasWF.Helpers;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ADSUtileriasWF.Views.RelojChecador.Views
{
public partial class FrmSistema : Form
{
public FrmSistema()
{
InitializeComponent();
}
private void Sincronizacion_SelectedIndexChanged(object sender, EventArgs e)
{
}
private void FrmSistema_Load(object sender, EventArgs e)
{
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(CargaChecadores);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
private void CargaChecadores()
{
//var proxi = new WCF_Checador.ChecadorServiceClient();
//var checklist = proxi.GetChecadores(-1);
//proxi.CloseAsync();
try
{
UtileriasServiceWCF.ResponseGetChecadoresModel[] checklist = Servicecon.GetChecadores(ModVarsPV.UserV2.CveUsuario.ToString().ToEntero(), ModVarsPV.UserV2.CveSubProyecto.ToString().ToEntero(), ModVarsPV.UserV2.CveEmpresa.ToString().ToEntero());
List<MyCheck> chks = new List<MyCheck>();
foreach (var item in checklist)
{
MyCheck chk = new MyCheck();
chk.checador = item.checador;
chk.cveChecador = item.cveChecador;
chk.cveSubProyecto = item.cveSubProyecto;
chk.cveSubProyecto = item.cveSubProyecto;
chk.iPLocal = item.iPLocal;
chk.puerto = item.puerto;
chk.subProyecto = item.subProyecto;
chk.EstatusConexion = "Sin conexión";
try
{
zkemkeeper.CZKEM conectarse = new zkemkeeper.CZKEM();
if (conectarse.Connect_Net(chk.iPLocal, chk.puerto.ToEntero()))
{
conectarse.Disconnect();
chk.EstatusConexion = "Activo";
getempleados(chk.iPLocal, chk.puerto);
}
}
catch (Exception) { }
chks.Add(chk);
}
//if (checklist != null)
//{
this.Invoke((MethodInvoker)delegate
{
DGVChecadores.AutoGenerateColumns = false;
DGVChecadores.DataSource = chks;
DGVChecadores.Refresh();
ImgLoader.Visible = false;
});
}
catch(Exception ex)
{
ADSNetLibrary.Helpers.ModExtensiones.GuardaLog(ex.Message);
}
//}
}
public void getempleados(string iPLocal, string puerto)
{
SDKZkTeckoHelper lib = new SDKZkTeckoHelper();
bool conected = lib.GetConnectState();
if (conected)
{
lib.sta_DisConnect();
}
conected = lib.sta_ConnectTCP(iPLocal, puerto, "0") > 0;
if (conected)
{
this.Invoke((MethodInvoker)delegate
{
DTGVPersonal.AutoGenerateColumns = false;
DTGVPersonal.DataSource = lib.GetUserInfo();
DTGVPersonal.Refresh();
});
}
}
private class MyCheck : UtileriasServiceWCF.ResponseGetChecadoresModel
{
public string EstatusConexion { get; set; }
}
private void BtnRefresh_Click(object sender, EventArgs e)
{
ImgLoader.Visible = true;
System.Threading.ThreadStart threadStart = new System.Threading.ThreadStart(CargaChecadores);
System.Threading.Thread thread = new System.Threading.Thread(threadStart);
thread.SetApartmentState(System.Threading.ApartmentState.STA);
thread.Start();
}
}
}

View File

@@ -0,0 +1,90 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="IpLocal.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Puerto.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Estatus.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dwEnrollNumber.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="CvePersonal.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="CodigoNombreCompleto.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Fecha.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>