/// <remarks/> public void ConfirmShipmentWithTermInfoAsync(ConfirmQuoteRequestInfo ConfirmQuoteRequestInfo, object userState) { if ((this.ConfirmShipmentWithTermInfoOperationCompleted == null)) { this.ConfirmShipmentWithTermInfoOperationCompleted = new System.Threading.SendOrPostCallback(this.OnConfirmShipmentWithTermInfoOperationCompleted); } this.InvokeAsync("ConfirmShipmentWithTermInfo", new object[] { ConfirmQuoteRequestInfo}, this.ConfirmShipmentWithTermInfoOperationCompleted, userState); }
/// <summary> /// Handles the Click event of the btnConfirmShipment control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param> private void btnConfirmShipment_Click(object sender, EventArgs e) { if (string.IsNullOrEmpty(txtIndex.Text)) { MessageBox.Show("Carrier Index is Empty."); txtIndex.Focus(); } else { RateQuoteWebServiceReference.Service rateQuoteWebService = new RateQuoteWebServiceReference.Service(); Int32 productsCount; productsCount = 1; QuoteItemsInfo[] quoteItemsInfo = new QuoteItemsInfo[productsCount]; quoteItemsInfo = InsertIntoQuoteItems(productsCount, quoteItemsInfo); ConfirmQuoteRequestInfo confirmation = new ConfirmQuoteRequestInfo(); confirmation.AgreementAcceptance = true; confirmation.DeliveryRemarks = "test remark"; confirmation.PickUpRemarks = "test remark"; confirmation.PONo = "1000000"; confirmation.QuoteItems = quoteItemsInfo; string RedayTime = string.Concat("07:00 PM"); string CloseTime = string.Concat("09:00 PM"); confirmation.ShipmentCloseTime = CloseTime; confirmation.ShipmentReadyTime = RedayTime; confirmation.ShipmentDate = DateTime.Now.AddDays(1); int index = Convert.ToInt32(txtIndex.Text); confirmation.SelectedCarrierCodeForShipment = dgvRateMyShipment.Rows[index].Cells[1].Value.ToString(); confirmation.ServiceTransactionId = dgvRateMyShipment.Rows[index].Cells["ServiceTransactionId"].Value.ToString(); confirmation.RefrenceNumber = ""; confirmation.CustomerBOL = ""; confirmation.ConsigneeAddress = new ShipmentAddress(); confirmation.ConsigneeAddress.CompanyName = "Asik comp 1"; confirmation.ConsigneeAddress.ContactPerson = "Asik AMjad 1"; confirmation.ConsigneeAddress.Street = "1st street"; confirmation.ConsigneeAddress.Fax = ""; confirmation.ConsigneeAddress.Phone = "1234567890"; confirmation.ConsigneeAddress.PhoneExtention = "1234"; confirmation.ConsigneeAddress.City = "Auburn"; confirmation.ConsigneeAddress.State = "WA"; confirmation.ConsigneeAddress.ZipCode = "980001"; confirmation.ConsigneeAddress.Country = "USA"; confirmation.ShipperAddress = new ShipmentAddress(); confirmation.ShipperAddress.CompanyName = "Asik Comp 2"; confirmation.ShipperAddress.ContactPerson = "Asik AMjad 2"; confirmation.ShipperAddress.Street = "2nd street"; confirmation.ShipperAddress.Fax = "1111111111"; confirmation.ShipperAddress.Phone = "2222222222"; confirmation.ConsigneeAddress.PhoneExtention = "1234"; confirmation.ShipperAddress.City = "Los Angeles"; confirmation.ShipperAddress.State = "CA"; confirmation.ShipperAddress.ZipCode = "10001"; confirmation.ShipperAddress.Country = "USA"; rateQuoteWebService.ConfirmShipmentCompleted += new ConfirmShipmentCompletedEventHandler(ser_ConfirmShipmentCompleted); textBoxBolNo.Text = Convert.ToString(rateQuoteWebService.ConfirmShipment(confirmation)); } }
/// <remarks/> public void ConfirmShipmentWithTermInfoAsync(ConfirmQuoteRequestInfo ConfirmQuoteRequestInfo) { this.ConfirmShipmentWithTermInfoAsync(ConfirmQuoteRequestInfo, null); }