SI_ID Property

Applies To   See Also  

A number that uniquely identifies an object in the Crystal Enterprise system. Indexed. Read-Only.

Type

Long

Syntax

SELECT

    SI_ID

FROM

    [Categories]

WHERE

    SI_ID = ObjectID

The syntax has these parts:

Part Type Description

ObjectID

Long

A number that identifies the object you want to retrieve.

Used to access the property from a query result:

QueryResult.Item(Index).ID

Remarks

This property is used to uniquely identify an object. The number is assigned at creation time, and is never changed until the object is destroyed. You should never hard-code this number, however, since if the object is destroyed the number may be assigned to another object. No two objects have the same ID, even if they are different types of objects; that is, you will never find a report that has the same ID as a folder.

This example selects the name of a particular Report object using the ID to find it.


'Search report objects to retrieve the ID.

Result=InfoStore.Query("Select TOP 10 SI_ID, SI_NAME From CI_INFOOBJECTS where SI_PROGID='CrystalEnterprise.Report' and SI_INSTANCE=0")


'Retrieve the ID of the first report from the result.

ID=Result.Item(1).ID

'Retrieve the name of the report using the ID.

Result=InfoStore.Query("Select SI_NAME From CI_INFOOBJECTS Where SI_ID = " & CStr(ID))




Crystal Decisions, Inc.
http://www.crystaldecisions.com
Support services:
http://support.crystaldecisions.com