Ejemplo n.º 1
0
        private static databases.tmpDS.stockCodeDataTable StockFromCodeList(string[] codes)
        {
            try
            {
                databases.tmpDS.stockCodeDataTable retTbl = new databases.tmpDS.stockCodeDataTable();

                databases.tmpDS.stockCodeRow stockRow;
                databases.tmpDS.stockCodeDataTable stockCodeTbl = myStockCodeTbl;
                for (int idx = 0; idx < codes.Length; idx++)
                {
                    stockRow = stockCodeTbl.FindBycode(codes[idx]);
                    if (stockRow != null) retTbl.ImportRow(stockRow);
                }
                return retTbl;
            }
            catch (Exception er)
            {
                if (OnError != null) OnError(er);
            }
            return null;
        }