DateTimeGroupOptions 类
使您可以获取和设置报表中日期时间组的日期和时间选项。
有关该类型所有成员的列表,参见 DateTimeGroupOptions 成员。
System.Object
CrystalDecisions.CrystalReports.Engine.EngineObjectBase
CrystalDecisions.CrystalReports.Engine.GroupOptions
DateTimeGroupOptions
[Visual Basic]
Public Class DateTimeGroupOptions Inherits GroupOptions Implements IDisposable
[C#]
public class DateTimeGroupOptions : GroupOptions, IDisposable
示例
下列示例通过 Group 对象的 GroupOptions 属性检索 GroupOptions 对象,并将其转换为 DateTimeGroupOptions 对象。
[VJ#] private DateTimeGroupOptions getDateTimeGroupOptions(int groupIndex) { Group group; DateTimeGroupOptions datetimeGroup = null; try { group = Report.get_DataDefinition() .get_Groups().get_Item(groupIndex); datetimeGroup = (DateTimeGroupOptions)group.get_GroupOptions(); } catch (Exception e) { return NULL; } return datetimeGroup; }
[Visual Basic] Private Function GetDateTimeGroupOptions _ (ByVal groupIndex As Integer) As DateTimeGroupOptions Dim group As Group Dim datetimeGroup As DateTimeGroupOptions group = Report.DataDefinition.Groups.Item(groupIndex) If TypeOf (group.GroupOptions) Is DateTimeGroupOptions Then datetimeGroup = group.GroupOptions GetDateTimeGroupOptions = datetimeGroup else GetDateTimeGroupOptions = nothing End If End Function
[C#] private DateTimeGroupOptions GetDateTimeGroupOptions(int groupIndex) { Group group; DateTimeGroupOptions datetimeGroup; group = Report.DataDefinition.Groups[groupIndex]; datetimeGroup = group.GroupOptions as DateTimeGroupOptions; return datetimeGroup; }
要求
命名空间 CrystalDecisions.CrystalReports.Engine
程序集 CrystalDecisions.CrystalReports.Engine (CrystalDecisions.CrystalReports.Engine.dll)
请参见
DateTimeGroupOptions 成员 | CrystalDecisions.CrystalReports.Engine 命名空间
©2005 Business Objects SA 保留所有权利。
Business Objects SA http://www.china.businessobjects.com/ 支持服务 http://www.china.businessobjects.com/ |