public SNums[] UpdateSNArrayWithLicenseAndSKU(DataSet objCryptoLgrDS, SNums[] tempSNArray) { CommonBL objCommonBL = new CommonBL(); DataTable dtSKU = objCryptoLgrDS.Tables[0]; for (int n = 0; n < tempSNArray.Count(); n++) { DataRow[] Rows; string str = "SNumTemp like '" + tempSNArray[n].SNum + "'"; if (str.Contains('%') || str.Contains('*') || str.Contains('-')) { str = str.Replace('%', '/'); } else { if (str.IsValidString()) { Rows = objCryptoLgrDS.Tables[0].Select(str); if (Rows.Count() > 0) { string[] arrSKU = new string[Rows.Count()]; for (int s = 0; s < Rows.Count(); s++) { DataRow dr = Rows[s]; arrSKU[s] = dr["PartName"].ToString(); tempSNArray[n].IsLicensableSNum = true; } tempSNArray[n].SKU = objCommonBL.GetSKUDetailInfo(arrSKU, tempSNArray[n].SNum); } } } } return(tempSNArray); }