PictureObject 类
表示报表上的图片对象。
有关该类型所有成员的列表,参见 PictureObject 成员。
System.Object
CrystalDecisions.CrystalReports.Engine.EngineObjectBase
CrystalDecisions.CrystalReports.Engine.ReportObject
PictureObject
[Visual Basic]
Public Class PictureObject Inherits GraphicObject Implements IDisposable
[C#]
public class PictureObject : GraphicObject, IDisposable
备注
该类使您可以检索信息和设置从 GraphicObject 类继承的一般格式选项。
示例
通过 ReportObjects 集合的 Item 属性,按索引或按名称检索 ReportObject 对象,并将 ReportObject 转换为 PictureObject。
[VJ#] static private PictureObject getPictureObject (String reportObjectName) { PictureObject picture = null; try { picture = (PictureObject)Report.get_ReportDefinition() .get_ReportObjects().get_Item(reportObjectName); } catch (Exception e) { return NULL; } return picture; }
[Visual Basic] Private Function GetPictureObject _ (ByVal reportObjectName As String) As PictureObject Dim picture As PictureObject If TypeOf _ (Report.ReportDefinition.ReportObjects. _ Item(reportObjectName)) Is PictureObject Then picture = _ Report.ReportDefinition.ReportObjects. _ Item(reportObjectName) GetPictureObject = picture Else : GetPictureObject = Nothing End If End Function
[C#] private PictureObject GetPictureObject (string reportObjectName) { PictureObject picture; picture = Report.ReportDefinition.ReportObjects[reportObjectName] as PictureObject; return picture; }
要求
命名空间 CrystalDecisions.CrystalReports.Engine
程序集 CrystalDecisions.CrystalReports.Engine (CrystalDecisions.CrystalReports.Engine.dll)
请参见
PictureObject 成员 | CrystalDecisions.CrystalReports.Engine 命名空间
©2005 Business Objects SA 保留所有权利。
Business Objects SA http://www.china.businessobjects.com/ 支持服务 http://www.china.businessobjects.com/ |