CountRecords Method for a Business Component

The CountRecords method returns the number of records that the most recent call to the ExecuteQuery method returned.

Format

BusComp.CountRecords()

No arguments are available.

Used With

Server Script

Examples

The following example is in Siebel eScript:

function Service_PreInvokeMethod (MethodName, Inputs, Outputs)
{
   if (MethodName == "Call_eScript")
   {
      var bo = TheApplication().GetBusObject("Opportunity");
      var bc = bo.GetBusComp("Opportunity");
      with (bc)
      {
         ClearToQuery();
         SetSearchSpec ("Name", "A*");
         ExecuteQuery(ForwardBackward);
         var count = CountRecords();
      }

      // other code..

      bc = null;
      bo = null;

      return (CancelOperation);
   }

   return (ContinueOperation);
}