Bookshelf Home | Contents | Index | Search | PDF |
Siebel Object Interfaces Reference > Interfaces Reference > Property Set Methods >
GetFirstProperty
This method returns the name of the first property in a property set.
Syntax
oPropSet.GetFirstProperty()
Returns
A string representing the name of the first property in a property set
Usage
GetFirstProperty() retrieves the name of the first property, in order of definition, of a business service. Use GetFirstProperty and GetNextProperty to retrieve the name of a property. You can then use the retrieved name as an argument to GetProperty to retrieve the property value, or with SetProperty to assign property values.
Used With
Browser Script, Server Script, Web Client Automation Server, Mobile/Dedicated Web Client Automation Server, COM Data Control, COM Data Server, Java Data Bean
Example
This example uses GetFirstProperty to get the first property, then retrieves all subsequent properties using GetNextProperty. The loop terminates when GetNextProperty retrieves a null.
function Service_PreInvokeMethod (MethodName, Inputs, Outputs)
{
var propName = "";
var propVal = "";propName = Inputs.GetFirstProperty();
// stay in loop if the property name is not null
// or a null string
while ((propName != "") && (propName != null)) {
propVal = Inputs.GetProperty(propName);// if a property with the same name does not exist
// add the name value pair to the output
if (!Outputs.PropertyExists(propName)) {
Outputs.SetProperty(propName, propVal);
}propName = Inputs.GetNextProperty();
}
return (CancelOperation);
}See Also
Bookshelf Home | Contents | Index | Search | PDF |
Siebel Object Interfaces Reference Published: 18 June 2003 |