private void AddDocEntryToGR(Goods_Receipt goodsReceiptForm) { var docEntry = this.UIAPIRawForm.DataSources.DBDataSources.Item(0).GetValue("DocEntry", 0); goodsReceiptForm.selectedGoodsIssue = new List <string> { docEntry }; }
private void CopyToGoodsIssue(object sboObject, SAPbouiCOM.SBOItemEventArg pVal) { if (pVal.FormMode == Convert.ToInt32(SAPbouiCOM.BoFormMode.fm_OK_MODE)) { if (IsTransferRequest()) { var grForm = Application.SBO_Application.OpenForm(SAPbouiCOM.BoFormObjectEnum.fo_GoodsReceipt, "", ""); grForm.Mode = SAPbouiCOM.BoFormMode.fm_ADD_MODE; Goods_Receipt grF = B1SystemForm.goodsReceiptForms[grForm.UniqueID]; List <Item> items = GetItems(); grF.populateItemsFromGR(items); //Add DocEntry to GR Form AddDocEntryToGR(grF); //Change Flag To Processed //UpdateComboBoxField(true, "U_isTransfered", "P"); } else { Application.SBO_Application.MessageBox("Warning: Transfered Field should be set to Not Processed", 1, "Ok"); } } }