Пример #1
0
            public static IEnumerable <VariableInfoTypeCategory> getCategoryElement(int variableID, VariablesDataset ds)
            {
                DataRow[] dr = ds.Tables["categories"].Select("variableID =  " + variableID);
                foreach (VariablesDataset.CategoriesRow row in dr)
                {
                    VariableInfoTypeCategory category = new VariableInfoTypeCategory();
                    category.dataValue   = Convert.ToDecimal(row.DataValue);
                    category.description = row.CategoryDescription;

                    yield return(category);
                }
            }
Пример #2
0
            public static IEnumerable<VariableInfoTypeCategory> getCategoryElement(int variableID,  VariablesDataset ds)
            {
                DataRow[] dr = ds.Tables["categories"].Select("variableID =  " + variableID);
                foreach (VariablesDataset.CategoriesRow row in dr)
                {
                    VariableInfoTypeCategory category = new VariableInfoTypeCategory();
                    category.dataValue = Convert.ToDecimal(row.DataValue);
                    category.description = row.CategoryDescription;

                    yield return category;

                }
            }