private void LlenaComboBox() { var data = InfoShippingBusiness.GetAll(); cboShipTo.DisplayMember = "shipTo"; cboShipTo.ValueMember = "shipTo"; cboShipTo.DataSource = data; }
private void ImprimirEtiqueta(string shipTo, string caja) { var info = InfoShippingBusiness.GetInfoShipping(shipTo); if (info != null && impresora != "") { zebraInstructions = new StringBuilder(); zebraInstructions.Append("^XA"); zebraInstructions.Append("^FT413,153^A0N,39,38^FH\\^FDCountry:^FS"); zebraInstructions.Append("^FT572,153^A0N,39,38^FH\\^FD" + info.country + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT21,371^A0N,39,38^FH\\^FDState:^FS"); zebraInstructions.Append("^FT192,367^A0N,28,28^FH\\^FD" + info.state + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT21,270^A0N,39,38^FH\\^FDCity:^FS"); zebraInstructions.Append("^FT167,263^A0N,25,24^FH\\^FD" + info.city + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT21,219^A0N,39,38^FH\\^FDAddress:^FS"); zebraInstructions.Append("^FT165,213^A0N,25,24^FH\\^FD" + info.address + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT23,420^A0N,39,38^FH\\^FDClient:^FS"); zebraInstructions.Append("^FT175,420^A0N,39,30^FH\\^FD" + info.client + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT23,465^A0N,39,38^FH\\^FDContact:^FS"); zebraInstructions.Append("^FT175,465^A0N,39,38^FH\\^FD" + info.contact + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT22,153^A0N,39,38^FH\\^FDShip To:^FS"); zebraInstructions.Append("^^FT184,153^A0N,39,38^FH\\^FD" + info.shipTo + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT195,66^A0N,39,38^FH\\^FDBOXID:^FS" + Environment.NewLine); zebraInstructions.Append("^BY3,3,56^FT327,76^BCN,,Y,N"); zebraInstructions.Append("^FD>:" + caja + "^FS" + Environment.NewLine); //Codigo QR zebraInstructions.Append("^FT687,112^BQN,2,4" + Environment.NewLine); zebraInstructions.Append(@"^FH\^FDLA" + caja + "^FS"); zebraInstructions.Append("^FT21,320^A0N,39,38^FH\\^FDZip Code:^FS"); zebraInstructions.Append("^FT192,316^A0N,28,28^FH\\^FD" + info.zipcode + "^FS" + Environment.NewLine); zebraInstructions.Append("^FT23,506^A0N,39,38^FH\\^FDEmail:^FS"); zebraInstructions.Append("^FT175,505^A0N,39,38^FH\\^FD" + info.email + "^FS" + Environment.NewLine); zebraInstructions.Append("^PQ1,0,1,Y^XZ"); string selectedPrinterName = impresora; var z = new ZebraPrinter(selectedPrinterName); z.Print(zebraInstructions.ToString()); z.Print(zebraInstructions.ToString()); } }
private void LlenaComboDireccion(string shipTo) { List <InfoShipping> data = new List <InfoShipping>(); if (shipTo != "") { data = InfoShippingBusiness.GetAdressByShipTo(shipTo); } else { data = null; } cboDireccion.DisplayMember = "address"; cboDireccion.ValueMember = "address"; cboDireccion.DataSource = data; }
private void LlenaComboBox(string pais) { List <InfoShipping> data = new List <InfoShipping>(); if (pais != "") { data = InfoShippingBusiness.GetShipToByCountry(pais); } else { data = null; } cboShipTo.DisplayMember = "shipTo"; cboShipTo.ValueMember = "shipTo"; cboShipTo.DataSource = data; }
private void LlenaComboBox() { //Combo Ship To var data = InfoShippingBusiness.GetAll(); cboShipTo.DisplayMember = "shipTo"; cboShipTo.ValueMember = "shipTo"; cboShipTo.DataSource = data; //Combo Project Lead var data2 = InfoFieldBookBusiness.GetProjectLead(); cboProject.DisplayMember = "projectLead"; cboProject.ValueMember = "projectLead"; cboProject.DataSource = data2; //Combo Emails var emails = EmailBusiness.GetEmails(); cboEmail.DisplayMember = "EmailUsado"; cboEmail.ValueMember = "Id"; cboEmail.DataSource = emails; //Combo Anio var anios = InfoFieldBookBusiness.GetAnio(); cboAnio.DisplayMember = "anio"; cboAnio.ValueMember = "anio"; cboAnio.DataSource = anios; //Combo CC var ccs = InfoFieldBookBusiness.GetCC(); cboCC.DisplayMember = "cc"; cboCC.ValueMember = "cc"; cboCC.DataSource = ccs; //Combo ExpName var expNames = InfoFieldBookBusiness.GetExpName(); cboExpName.DisplayMember = "expName"; cboExpName.ValueMember = "expName"; cboExpName.DataSource = expNames; }