Siebel Object Interfaces Reference > Interfaces Reference > Business Component Methods >

PreviousRecord Method


PreviousRecord moves the record pointer to the next record in the business component, making that the current record and invoking any associated script events.

Syntax

BusComp.PreviousRecord

Argument
Description

Not applicable

 

Returns

An integer in Siebel VB; a Boolean in Siebel eScript, COM, and ActiveX.

Usage

PreviousRecord may be used only on a business component that has been queried using the ForwardBackward CursorMode.

Used With

COM Data Control, COM Data Server, Java Data Bean, Mobile Web Client Automation Server, Server Script

Example

The following Siebel eScript example finds the next-to-last record in a query and does some manipulation with it:

with (this)

{

ActivateField("Name")

ClearToQuery();

SetSearchSpec("Name", "A*");

ExecuteQuery(ForwardBackward);

isRecord = FirstRecord();

while (isRecord)

{

// do some record manipulation

isRecord = NextRecord();

} // end while loop

nextToLastRecord = PreviousRecord();

if (nextToLastRecord) // verify that there is a penultimate record

{

// do some more record manipulation that applies only to next-to-last record

} // end if

} // end with

Related Topic

ExecuteQuery Method

Siebel Object Interfaces Reference Copyright © 2008, Oracle. All rights reserved.