on 04-28-2016 11:49 AM
Hi,
I created choose from list in matrix.
How can i catch choose from list value in matrix.
Hi,
Try it like this:
if ((pVal.ItemUID == "Matrix") && (pVal.ColUID == "colItemCode") && pVal.EventType == BoEventTypes.et_CHOOSE_FROM_LIST && pVal.FormMode != 0)
{
SAPbouiCOM.ChooseFromListEvent cflevent = (SAPbouiCOM.ChooseFromListEvent)pVal;
SAPbouiCOM.ChooseFromList oCFLEvento = default(SAPbouiCOM.ChooseFromList);
string strUid = cflevent.ChooseFromListUID;
oCFLEvento = this.m_SBO_Form.ChooseFromLists.Item(strUid);
SAPbouiCOM.DataTable oDataTable = cflevent.SelectedObjects;
SAPbobsCOM.Recordset oRecSet = (SAPbobsCOM.Recordset)SBO_Company.GetBusinessObject(BoObjectTypes.BoRecordset);
if (oDataTable == null)
{
m_SBO_Form.Freeze(false);
return;
}
SAPbouiCOM.EditText oEdit = default(SAPbouiCOM.EditText);
SAPbouiCOM.Matrix oMatrixItem = (SAPbouiCOM.Matrix)this.m_SBO_Form.Items.Item(pVal.ItemUID).Specific;
int i = 0;
int Row = pVal.Row;
for (i = 0; i <= oDataTable.Rows.Count - 1; i++)
{
string ItemCode = oDataTable.GetValue("ItemCode", i).ToString();
try
{
oEdit = (SAPbouiCOM.EditText)oMatrixItem.Columns.Item("colItemCode").Cells.Item(Row).Specific;
oEdit.Value = oDataTable.GetValue("ItemCode", i).ToString();
}
catch { }
}
Hope it helps.
Kind regards,
ANKIT CHAUHAN
SAP Business One Global Support
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
91 | |
8 | |
7 | |
4 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.