本文整理汇总了C#中SelectQuery.get_Items方法的典型用法代码示例。如果您正苦于以下问题:C# SelectQuery.get_Items方法的具体用法?C# SelectQuery.get_Items怎么用?C# SelectQuery.get_Items使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SelectQuery
的用法示例。
在下文中一共展示了SelectQuery.get_Items方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddCompareFilter
public static CompareFilter AddCompareFilter(SelectQuery SelectQuery, string FieldName, IParameter Parameter)
{
Filters Filters = SelectQuery.get_Items(0).Filters;
TableField Field = SelectQuery.get_Items(0).FromTable.Fields[FieldName];
CompareFilter Filter = Filters.CreateCompareFilter();
Filter.Code = FieldName;
FieldFilterExpression TestExpression = Filter.CreateFieldFilterExpression();
ParamFilterExpression ValueExpression = Filter.CreateParamFilterExpression();
TestExpression.Field = Field;
ValueExpression.Parameter = Parameter;
Filter.TestExpression = TestExpression;
Filter.ValueExpression = ValueExpression;
Filters.Add(Filter);
return Filter;
}
示例2: AddIncludeFilter
public static IncludeFilter AddIncludeFilter(SelectQuery SelectQuery, string FieldName, string[] IDs)
{
Filters Filters = SelectQuery.get_Items(0).Filters;
TableField Field = SelectQuery.get_Items(0).FromTable.Fields[FieldName];
IncludeFilter Filter = Filters.CreateIncludeFilter();
Filter.Code = FieldName + "_Include";
FieldFilterExpression TestExpression = Filter.CreateFieldFilterExpression();
TestExpression.Field = Field;
Filter.TestExpression = TestExpression;
for (var i = 0; i < IDs.Length; i++) {
string ID = IDs[i];
ParamFilterExpression ValueExpression = Filter.CreateParamFilterExpression();
Parameter Parameter = AddParameter(SelectQuery.Parameters, "Expression"+i.ToString(), ParamDataTypeEnum.pdtUnicodeString);
Parameter.Value = ID;
ValueExpression.Parameter = Parameter;
ValueExpression.Code = "Code" + i.ToString();
Filter.ValuesExpressions.Add(ValueExpression);
}
Filters.Add(Filter);
return Filter;
}
示例3: AddIsNullFilter
public static IsNullFilter AddIsNullFilter(SelectQuery SelectQuery, string FieldName)
{
Filters Filters = SelectQuery.get_Items(0).Filters;
TableField Field = SelectQuery.get_Items(0).FromTable.Fields[FieldName];
IsNullFilter IsNullFilter = Filters.CreateIsNullFilter();
IsNullFilter.Code = FieldName;
IsNullFilter.KeyValue = FieldName;
string FromTableAlias = Filters.ParentSelect.FromTableAlias;
IsNullFilter.TestExpression = AddFieldExpression(Filters, IsNullFilter, Field, FromTableAlias);
Filters.Add(IsNullFilter);
return IsNullFilter;
}