Documente Academic
Documente Profesional
Documente Cultură
MARCH 2000
Siebel Systems, Inc., 1855 South Grant St., San Mateo, CA 94402
Copyright 2000 Siebel Systems, Inc.
All rights reserved. Published 19992000
Printed in the United States of America
No part of this publication may be stored in a retrieval system, transmitted, or reproduced in any way, including
but not limited to photocopy, photographic, magnetic or other record, without the prior agreement and written
permission of Siebel Systems, Inc.
Target Account Selling Methodologies, Copyright 1996 Target Marketing International, Inc. All rights reserved.
The full text search capabilities of Siebel eBusiness Applications include technology used under license from
Fulcrum Technologies, Inc. and are the copyright of Fulcrum Technologies, Inc. and/or its licensors.
Siebel, the Siebel logo, ActiveBriefing, TrickleSync, TSQ, Universal Agent, and other Siebel product names
referenced herein are trademarks of Siebel Systems, Inc., and may be registered in certain jurisdictions.
Windows is a registered trademark of Microsoft Corporation.
All other product names, marks, logos, and symbols may be trademarks or registered trademarks of their
respective owners.
U.S. GOVERNMENT RESTRICTED RIGHTS. Programs, Ancillary Programs and Documentation, delivered
subject to the Department of Defense Federal Acquisition Regulation Supplement, are commercial computer
software as set forth in DFARS 227.7202, Commercial Computer Software and Commercial Computer Software
Documentation, and as such, any use, duplication and disclosure of the Programs, Ancillary Programs and
Documentation shall be subject to the restrictions contained in the applicable Siebel license agreement. All
other use, duplication and disclosure of the Programs, Ancillary Programs and Documentation by the U.S.
Government shall be subject to the applicable Siebel license agreement and the restrictions contained in
subsection (c) of FAR 52.227-19, Commercial Computer Software - Restricted Rights (June 1987), or
FAR 52.227-14, Rights in General Data Alternative III (June 1987), as applicable. Contractor/licensor is
Siebel Systems, Inc., 1855 South Grant Street, San Mateo, CA 94402.
Proprietary Information
Siebel Systems, Inc. considers information included in this documentation and
in Siebel eBusiness Applications Online Help to be Confidential Information.
Your access to and use of this Confidential Information are subject to the terms
and conditions of: (1) the applicable Siebel Systems software license
agreement, which has been executed and with which you agree to comply; and
(2) the proprietary and restricted rights notices included in this documentation.
Contents
Introduction
Who Should Use This Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-2
How This Guide Is Organized . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-2
Typographic Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-3
Whats New in This Release . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-4
Additional Documentation
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-5
Version 6.0
iii
Contents
Chapter 2. Programming
Chapter Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-3
Siebel Object Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-5
Siebel COM Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6
Siebel ActiveX Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-8
Siebel Java Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2-10
Siebel CORBA Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-11
Built-In Scripting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-14
Usage Evaluation Matrix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-14
Object Types Exposed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-15
Application Object Type. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-16
Business Object Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-16
Business Component Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-17
Business Service Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-17
Applet Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-18
Property Set Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-19
User Interface Control Object Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-19
Web Applet Object Type. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-20
iv
Version 6.0
Contents
Version 6.0
Contents
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-19
3-25
3-26
3-28
3-29
3-31
3-32
3-33
3-34
3-36
3-37
vi
3-38
3-39
3-40
3-42
3-43
3-44
3-46
Version 6.0
Contents
Application Methods
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-48
ActiveApplet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-48
ActiveBusComp. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-49
ActiveBusObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-50
ActiveControl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-51
ActiveViewName. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-53
CurrencyCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-54
EnableExceptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-55
FindApplet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-56
GetBusObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-57
GetLastErrCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-58
GetLastErrText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-59
GetProfileAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-60
GetService . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-61
GetSharedGlobal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-62
GotoApplet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-63
GotoView . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-64
InputBox. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-66
InvokeMethod. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-68
LoadObjects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-69
Login . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-70
LoginId. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-72
LoginName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-73
Logoff. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-74
MsgBox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-75
NewPropertySet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-78
PositionId . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-79
PositionName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-80
SetSharedGlobal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-82
SetProfileAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-83
ShowStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-84
Trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-85
TraceOff . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-87
TraceOn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-88
Version 6.0
vii
Contents
vii i
Version 6.0
Contents
NewRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
NextRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
NextSelected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
ParentBusComp. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Pick . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
PreviousRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
RefineQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetFormattedFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetNamedSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetSearchExpr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetSearchSpec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetSortSpec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetUserProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetViewMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SuppressNotification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
UndoRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
WriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3-134
3-136
3-137
3-138
3-139
3-141
3-142
3-143
3-145
3-147
3-148
3-150
3-154
3-156
3-157
3-159
3-160
3-161
Version 6.0
ix
Contents
BusComp_PreWriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
BusComp_Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
BusComp_SetFieldValue. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
BusComp_WriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3-181
3-182
3-184
3-185
Version 6.0
Contents
PropertyExists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
RemoveChild. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
RemoveProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetType. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
SetValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3-217
3-218
3-219
3-220
3-221
3-222
3-223
...
...
...
...
...
...
...
...
...
...
...
...
....
....
....
....
...
...
...
...
...
...
...
...
...
...
...
...
....
....
....
....
...
...
...
...
...
...
...
...
...
...
...
...
....
....
....
....
. .3-234
. 3-234
. 3-235
. 3-236
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-237
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-238
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-239
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-242
Version 6.0
xi
Contents
xii
Version 6.0
Contents
Version 6.0
x iii
Contents
Index
xiv
Version 6.0
Introduction
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Intro-5
Version 6.0
I n tr o - 1
Introduction
Who Should Use This Guide
Intro
This guide provides complete information about the methods that can be used to
access Siebel events and methods from both internal and external programming
environments. It also includes complete syntax information for the events and
methods themselves.
The audience for this guide consists of:
Siebel Application Persons who plan, implement, and configure Siebel applications,
Developers
possibly adding new functionality. A developer is typically
Intro
This book comprises three chapters and seven parallel appendices. The first chapter
describes the programming environment embedded in Siebel Tools. The second
details the interfaces available for accessing Siebel objects. The third explains each
of the Siebel events and methods, grouped by the type of object with which they
can be used. The appendices, one for each interface, provide quick references to the
syntax for Siebel events and methods.
In t ro - 2
Version 6.0
Introduction
Typographic Conventions
Typographic Conventions
Intro
Syntax Is
Arguments to statements or
functions
Version 6.0
I n tr o - 3
Introduction
Whats New in This Release
Intro
Version 6.0 of Siebel Tools has several important new features that are documented
in this guide.
Feature
Description
Business services
Property sets
Control properties
NOTE: Your Siebel implementation may not have all the features described in this
In t ro - 4
Version 6.0
Introduction
Additional Documentation
Additional Documentation
Intro
Version 6.0
I n tr o - 5
Introduction
Contacting Siebel Technical Support
For copies of these documents, please use Siebel Books Online, accessible via the
Worldwide Services tab on the Siebel Systems Web site (www.siebel.com). Through
Siebel Books Online, you can order additional Siebel documentation and copies of
the Bookshelf for Siebel eBusiness Applications CD-ROM.
Another source of information is the Siebel Online Help.
Intro
Do you know how to access Siebel Technical Support? It is crucial that you
understand the requirements for getting support. This will ensure the best
experience possible. If you have questions, please dont hesitate to contact us.
To ensure that you maximize your knowledge of Siebel products and your return on
investment:
In t ro - 6
Version 6.0
Introduction
Siebel Welcomes Your Comments
support@siebel.com
+44.1784.494.949
Tokyo:
+81.3.5469.3811(main number)
Munich:
+49.89.95718.400
Intro
Version 6.0
I n tr o - 7
Introduction
Siebel Welcomes Your Comments
In t ro - 8
Version 6.0
Version 6.0
1-1
Programming Tools
1-2
Version 6.0
Siebel Script Editor. An integrated editor used to create, view, edit, and save
custom program routines. The Siebel Editor is similar to the code editor that
accompanies Microsofts Visual Basic program. The Siebel Editor is described in
more detail in The Siebel Script Editor on page 1-9.
Version 6.0
Object Interfaces. A collection of selected objects that expose their data and
functionality to custom routines. The interface provides access to Siebel
business objects with defined methods, events, and associated data. The
object interfaces are the subject of this book.
1-3
The Siebel programming languages provide the ability to extend the behavior of the
Siebel application in specific ways. Supported extensions can be grouped into the
following:
The Siebel programming languages let you extend data validation beyond what
is already provided for in the standard Siebel application. The unique validation
requirements of a business can be satisfied by custom extension routines that
implement the specific business rules prior to performing record manipulation
operations, such as record write or record delete.
Data validation routines may incorporate validations based on data from sources
within or outside the Siebel application. For example, a validation routine may
verify that an opportunity revenue amount is greater than zero if the probability
of the opportunity is more than 20 percent using internal Siebel data. Alternatively,
an extension routine could verify the availability of a conference room prior to
inserting a new activity record by reading the information from another
applications database table.
The Siebel programming languages provide data manipulation capabilities that
can be used to modify data, such as updating, inserting, and deleting records.
For example, a custom routine can be used to set the value of one field based on
the value of another before a new record is created. A custom routine could thus
be used to set the value of opportunity probability based on a stage in the sales
cycle, simplifying data entry.
1-4
Version 6.0
The methods used to support data manipulation provide error notification. The
Siebel programming language is notified of the error and has access to information
to allow you to handle the error and take appropriate action.
All data manipulation methods in the Siebel programming languages conform to the
same visibility rules as the standard Siebel applications user interface. For example,
if a business object is readable but not editable because of visibility rules in the
Siebel applications user interface, the same will be true when you are accessing the
object through the Siebel languages. These languages cannot circumvent the
visibility rules or the security constraints enforced by the standard Siebel
applications.
With Siebel Applet Designer, you can add selected user interface objects to applets.
With the Siebel programming languages, you can associate behavior to the objects.
An example of this feature is placing a button on an applet which, when clicked,
launches another program such as Excel.
With the Siebel programming languages, you can update a particular field based on
the values of other fields in the system. An extension routine could enforce the
business rule that states, If the sales cycle is at or past the Quote Submitted stage,
do not allow the Revenue field to be modified. The feature can also be used to
support the user-specific data maintenance rule, by restricting updates to certain
fields based on the position of the current user.
Version 6.0
1-5
1-6
Version 6.0
Internal scripts are created in the Script Editor embedded in Siebel Tools. You can
enable either Siebel VB or Siebel eScript, but not both. To choose which language
will be active in Siebel Tools, you must make a change to the configuration file.
NOTE: The Siebel programming languages are not available on any of the Siebel Thin
Clients. The Siebel Thin Clients do not support any kind of scripting that involves
user interface objects, because scripts cannot be run on the clients.
2 Enter *.cfg as the search specification, and the drive on which your Siebel
application and Siebel Tools are located in the Look in: field. (If your Siebel
application and Siebel Tools are on different drives, repeat this procedure for
both drives.)
3 For every .cfg file in a Siebel\bin or siebdev\bin directory:
a Open the file in Notepad or another text editor.
b Search for the text ScriptingDLL.
c If you want to use Siebel eScript, change the value assigned to this key
to sscfjs.dll.
d If you want to use Siebel VB, change the value assigned to this key to
sscfbas.dll.
Version 6.0
1-7
The following procedure describes the steps required to add new business rules to
a business component.
3 Select the business component using the Object Explorer and Object List Editor.
4 Click the right mouse button to bring up the pop-up menu. Select Edit Scripts.
5 Select the event from the Proc pick list and add your Siebel script in the
code window.
6 Validate the Siebel script syntax by selecting Debug: Check Syntax.
7 Choose File
1-8
Version 6.0
The Siebel Script Editor is a simple window-based editor designed to create and
maintain Siebel VB or Siebel eScript programs.
When creating Siebel custom programs, note the following:
Check out or lock the project containing the object definitions being modified.
If the project is not locked, you will be unable to add any text in the Editor
window.
Choose Debug
Choose File
Save when you have finished entering and editing the custom
statements to save your work. Closing the Siebel Script Editor without saving
your work will discard the changes.
Before you run the application, you must compile the projects that you have
modified and generate a new .srf file. See the Siebel Tools Guide for information
on the Object Compiler.
Debug Start or clicking the Start button in the Debug toolbar. The Siebel
application executes with the new modifications incorporated.
You may inadvertently create programming errors that, when encountered, will
halt the execution of the extension routine. If you started Siebel applications in
debug mode (/H option on the command start-up line), a message box opens
indicating the nature of the error. You can then return to the Script Editor and
choose Debug Check Syntax. For further details, see Checking Syntax on
page 1-20.
Version 6.0
1-9
To access the Siebel Script Editor (shown in Figure 1-1), select an object definition
in the Object List Editor and click the right mouse button. If the editor is available
from that object type, you can select Edit Scripts from the dialog box. Siebel scripts
can be attached to the object types application, applet, and business component.
Figure 1-1.
1-10
Version 6.0
Once you are in the Siebel Script Editor, you can do the following:
Cut, copy, and paste the text from one location to another location within or
from outside the Editor.
Save. Saves a Siebel script. Be sure to save your scripts before exiting the editor.
The following are Edit menu options pertaining to the Siebel Editor:
Find. Displays the Find in Script dialog box. You can search for text or
white space.
Replace. Displays the Replace in Script dialog box. You can search and replace
Version 6.0
1-11
Some editing functions are available from the Edit toolbar. The Edit toolbar appears
in Figure 1-2.
Redo
Undo
Paste
Copy
Cut
Save All
Save
New
Figure 1-2.
Edit Toolbar
The toolbar icons perform the same functions as the comparably-named menu
options described previously.
Caution: For each of the Siebel script edit boxes, a limit of 16k
characters exists. Each subroutine or function has its own edit box
and therefore can be up to 16k. The same limit applies to the
(general) (declarations) section. If you are approaching this limit,
try the following hints to reduce the size of your script:
1-12
Version 6.0
Scripted Flag
For object types that can have a Siebel script attached to them (applet, application,
and business component), there is a property in the Object List Editor called
Scripted. This property indicates whether Siebel scripts are attached to the object
definition. A check mark indicates the presence of scripts; no check mark indicates
that the object definition has no scripts.
Figure 1-3.
Version 6.0
1-13
The following window features in this tabbed form apply to script editing:
Tab Width field. Defines the number of spaces for a tab character. The default is
four spaces.
Auto Indent field. When checked, each succeeding line is indented to the position
set by the current line.
Maximum Levels of Undo field. Specifies the number of changes that are saved and
can be undone.
1-14
Version 6.0
The Siebel Debugger assists in editing and removing errors from scripts written in
Siebel VB and Siebel eScript.
The Siebel Debugger uses the Siebel Script Editor window plus a diagnostic window
to display program variables and their values. The Debugger helps you locate and
correct execution errors in custom program routines. It allows you to slow or
suspend execution of the program routines so that the program flow and variable
contents can be examined.
The Siebel Debugger allows you to do the following:
Step over a line of code. If the current line is a call to a subroutine or function,
the Debugger stops at the next line in the current procedure (skipping the
subroutine).
Step into a subroutine of custom routine code. Step Into is used to execute one
line of code in the Debugger. If the current line is a call to a subroutine or
function, the Debugger stops at the first line of that function. Otherwise, the
Debugger stops at the next line of the current procedure.
View the value of custom routine variables. The Siebel Debugger includes a
window in which variables and their values are displayed. This window can be
used to monitor the values of specific variables as the custom routine executes.
Version 6.0
1-15
You can set breakpoints in the current routine and begin execution by clicking
the Start button. Execution is suspended when one of the lines that contains a
breakpoint is about to be executed. The Debugger is activated and it highlights
the line containing the breakpoint.
Step Over
Step Into
Calls
Watch
Toggle Breakpoint
End
Break
Start
Check Syntax
Figure 1-4.
Check Syntax button. Compiles the current Siebel script and verifies syntax.
Start button. Starts the application. A dialog box with start-up parameters is
also displayed.
1-16
Break button. Stops the execution of the currently running Siebel script. If a
Siebel script is not running, no operation is performed.
Version 6.0
End button. Stops the execution of the application and returns to the Siebel Script
Editor window.
Watch button. The Tools menu establishes variable watches, so you can monitor
Calls button. Displays the list of Siebel VB or Siebel eScript routine calls executed
Step Into button. Executes the next line of code. If this is a subroutine or
Version 6.0
Step Over button. Advances the application to the code line just after the current
subroutine or procedure. Execution remains at the level of the current procedure.
1-17
Figure 1-5.
Debugging Preferences
Adjust breakpoint to next valid line. When breakpoints are deleted on invalid lines,
Make debugger window active when debugging. The Siebel Debugger window
Always enter the debugger when an error occurs. The Siebel Debugger window
1-18
Version 6.0
Figure 1-6.
Run-Time Preferences
Command line. The command line to start the application. You can place the
Prompt for this information each time. The Preferences dialog box appears
Version 6.0
1-19
Checking Syntax
The debugger includes a syntax checker to ensure that your script will compile
properly. (Its up to you to see to it that the script does what you want it to do.)
Check Syntax.
Siebel Tools does a test compile. If you have made no errors, you get no
response. If there are errors in your script, a message box will appear, describing
the error. The message box has two buttons: Next Error and Go to Line. If there
is more than one error, its best to handle them one at a time.
2 Click Go to Line.
The cursor falls on the line of the script containing the error, with the line
highlighted.
5 Choose File Save to save your file. Close the Siebel application. Press F7 to
compile the .srf file. When the compilation is finished, click the Run button or
press F5 to restart the application.
Caution: The Check Syntax function checks only for syntax errors
and errors that stem from failure to properly initialize objects or
variables. It does not check other types of errors, and cannot trap
errors in logic that may cause run-time errors.
1-20
Version 6.0
At this point, your script should run. Test it to see if it gives you the desired results.
The following sections describe debugging tools to help you accomplish that end.
Caution: The Check Syntax command checks only the script in the
active object definition. If there are errors in other scripts, you will
not be able to compile the .srf file.
Breakpoints
A breakpoint is a marker on a line of Siebel code that tells the interpreter to suspend
execution at that line so that the state of the program can be examined using the
Debugger. There are two ways to set breakpoints on lines of Siebel code when
editing, and there is an additional way to set a breakpoint when debugging.
When editing, place the cursor on the line of code on which you wish to set a
breakpoint by clicking on that line with the mouse or using the arrow keys.
Then press the F9 function key or the toolbar icon to toggle the breakpoint. If
the line already had a breakpoint on it, pressing F9 or the toolbar icon will
clear the breakpoint.
Version 6.0
1-21
Variable Window
The variable window is used to examine the contents of the variables associated
with a Siebel script when debugging.
The Calls window contains a list of subroutine and function calls that were executed
prior to the current line. To access the Calls window, click the Calls button in the
Debugger toolbar when you are running the Debugger. A typical call window may
contain several lines, one for each subroutine entered into and not yet completed.
Selecting an entry in this list box will cause the interpreter to shift to that entry.
The Debugger window displays the line of code that made the call, and the Variable
window displays the variables that are associated with the procedure that made
the call.
1-22
Version 6.0
To invoke the Siebel Compiler and Run-time Engine, click the Compile button on
the Debugger toolbar, or press F7. You can also invoke it when compiling a project
containing object definitions with associated Siebel scripts. The Siebel Compiler
and Run-time Engine has no user interface of its own. When the compiler is
invoked, it compiles the custom routines and returns a message when completed
that indicates success or failure.
Whenever a Siebel object that has a Siebel VB script attached is instantiated, the
Run-time Engine creates a temporary file in the applications Temp directory (usually
C:\Siebel\Temp). These files have the extension .sbx. If multiple copies of an
object are instantiated through an external object, an equal number of .sbx files will
be created. These files are automatically deleted when the object is destroyed or the
Siebel application is terminated.
These temporary files are an internal implementation characteristic and cannot be
interpreted, modified, or debugged by the user.
Siebel eScript does not create these temporary files.
Version 6.0
1-23
If you have never programmed in Visual Basic before, it is recommended that you
start with the Siebel VB Language Reference. That manual includes a complete
reference to the internal VB program constructs, statements, and functions. You will
need to understand how these objects behave before you can program effectively
using the Siebel object methods and events.
Declare your variables. As a general rule, it is helpful to use the Option Explicit
statement, which forces you to declare all your variables (using the Dim statement)
before you use them. Doing so makes it easier for others to understand your code,
and for you to debug the code. You can declare a variable without giving it a data
type, but if you dont specify a data type, Siebel VB will assume the type Variant,
which requires 16 bytestwice as much memory as the next smallest data type. If
you can avoid Variant variables, you will reduce the amount of memory required by
your code, which may make execution faster. In Siebel VB, you place Option
commands in the (general) (declarations) window.
Use standardized naming conventions. Another way to improve the readability of your
1-24
Symbol
Example
String
sName
Integer
iReturn
Long integer
lBigCount
Single-precision number
si
siAllowance
Double-precision number
dBudget
Object
oBusComp
Currency
cAmtOwed
Version 6.0
You can also use suffix characters on your variable names. See the Siebel VB
Language Reference for details on these characters.
Use the Me object reference. The special object reference Me is a VB shorthand for
the current object. You should use it in place of references to active business
objects. For example, in a business component event handler, you should use Me in
place of ActiveBusComp, as shown in the following example. You can see other
examples of Me in ParentBusComp on page 3-138, SetViewMode on page 3-157,
BusComp_PreQuery on page 3-178, BusComp_PreWriteRecord on page 3-181, and
Applet on page 3-224.
Function BusComp_PreSetFieldValue(FieldName As String, FieldValue
As String) As Integer
If Val(Me.GetFieldValue(Rep %)) >75 Then
....
End If
BusComp_PreSetFieldValue = ContinueOperation
End Function
Trap run-time errors. The standard VB methods documented in the Siebel VB
NOTE: The GetLastErrText method is available only via interfaces external to Siebel
Tools. Therefore, you can use it in Microsoft VB, but not in Siebel VB.
Version 6.0
1-25
If you are working within the Siebel applications, especially in a LAN environment,
where you cannot be sure that a record hasnt been changed or deleted by another
user, its important to create routines that will keep the program from failing when
it meets an unexpected condition. You will find information about error-handling
routines in the Language Overview chapter of the Siebel VB Language Reference.
Make effective use of the Select Case construct. The Select Case construct allows the
program to choose among any number of alternatives you require, based on the
value of a single variable. It is greatly preferable to a series of nested If statements,
because it simplifies code maintenance, and also improves performance, because
the variable must be evaluated only once. For a full description, see the Siebel VB
Language Reference.
Use the With shortcut. The With statement (see the Siebel VB Language Reference)
allows you apply several methods to a single object. It makes the code easier to
read, reduces typing, and improves performance. Instead of a series of statements
such as
Set oBusComp = objBusObject.GetBusComp("Opportunity")
oBusComp.ClearToQuery
oBusComp.SetSearchSpec . . .
oBusComp.ExecuteQuery ForwardBackward
oBusComp.FirstRecord
oBusComp.NewRecord NewAfter
oBusComp.SetFieldValue "QuoteNumber", sQuoteId
oBusComp.SetFieldValue "Account", sAccount
. . .
sSolutionId(cSolution) = oBusComp.GetFieldValue( "Id" )
. . .
1-26
Version 6.0
Use extreme care when working with date variables. When working with date variables
extreme care has to be taken regarding the date format. GetFieldValue always
returns the date in the format "dd/mm/yyyy" (eventually followed by the time). As
a result, applying the CVDate() function, which expects the regional setting, to the
return value may cause an error. The GetFormattedFieldValue method uses the
regional settings of the user's operating system. The regional setting specifies the
year with two digits in most cases, thereby creating the possibility of Y2K noncompliance. For these reasons, you should use the following approach for
performing date arithmetic:
1 Retrieve the value of date fields with the GetFieldValue method (see page 3-115).
2 Convert it into a date variable using the DateSerial() function (see the Siebel VB
Language Reference).
3 Perform the required date arithmetic.
Here is an example:
Dim strDate as String, varDate as Variant
strDate = oBC.GetFieldValue("Date Field")
varDate = DateSerial(Mid(strDate,7,4), Left(strDate,2), _
Mid(strDate,4,2))
[any date arithmetic]
Destroy any objects you have created when you no longer need them. Although the
system will eventually clean up objects, you can do so more efficiently than the
system. Moreover, in some instances, failure to clean up after yourself can create a
serious drain on performance and resources.
To destroy an object in Siebel VB, set it to Nothing. The best practice is to destroy
objects in the order opposite to the order of creation. For example:
Set oApplet = Me
Set oBC = oApplet.BusComp
[ Your code here ]
Set oBC = Nothing
Set oApplet = Nothing
Version 6.0
1-27
There are some important differences between Siebel eScript and Siebel VB:
variables. Variables are declared implicitly as soon as they are used. However, Siebel
eScript requires you to declare variables with the var keyword. As a general rule, it
is helpful to declare all variables used in a module before you use them. Doing so
makes it easier for others to understand your code, and for you to debug the code.
There is one notable exception to this standard. Declaring a variable inside a loop
controller restricts the scope of that reference to within the loop. This prevents the
variable from persisting; it can therefore be declared again inside another loop.
Use the this object reference. The special object reference this is eScript shorthand
for the current object. You should use it in place of references to active business
objects and components. For example, in a business component event handler, you
should use this in place of ActiveBusComp, as shown in the following example.
1-28
Version 6.0
function BusComp_PreQuery ()
{
this.ActivateField("Account");
this.ActivateField("Account Location");
this.ClearToQuery();
this.SetSortSpec( "Account(DESCENDING)," +
" Account Location(DESCENDING)");
this.ExecuteQuery();
return (ContinueOperation);
}
Use the with shortcut. The with shortcut (see the Siebel eScript Language Reference)
allows you apply several methods to a single object. It makes the code easier to
read, reduces typing, and improves performance. Instead of a series of statements
such as:
var oBusComp = oBusObject.GetBusComp("Opportunity");
oBusComp.ClearToQuery();
oBusComp.SetSearchSpec( . . .);
oBusComp.ExecuteQuery(ForwardBackward)
oBusComp.FirstRecord();
oBusComp.NewRecord(NewAfter);
oBusComp.SetFieldValue("QuoteNumber", sQuoteId);
oBusComp.SetFieldValue("Account", sAccount)
. . .
sSolutionId(cSolution) = oBusComp.GetFieldValue( "Id" );
. . .
Version 6.0
1-29
Make effective use of the Switch construct. The Switch construct allows the program
to choose among any number of alternatives you require, based on the value of a
single variable. It is greatly preferable to a series of nested If statements, because it
simplifies code maintenance, and also improves performance, because the variable
must be evaluated only once. For a full description, see the Siebel eScript Language
Reference.
Destroy any objects you have created when you no longer need them. Although the
system will eventually clean up objects, you can do so more efficiently than the
system. Moreover, in some instances, failure to clean up after yourself can create a
serious drain on performance and resources.
To destroy an object in Siebel eScript, set it to null, or set the variable containing it
to another value. The best practice is to destroy objects in the order opposite to the
order of creation. For example:
var oApplet = me;
var oBC = oApplet.BusComp;
[ Your code here ]
oBC = null;
oApplet = null;
1-30
Version 6.0
Programming
Chapter Overview
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-3
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-5
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-18
. . . . . . . . . . . . . . . . . . . . . . . . 2-19
Version 6.0
2-1
Programming
. . . . . 2-60
. . . . . . . . . . . . . . . 2-71
2-2
Version 6.0
Programming
Chapter Overview
Chapter Overview
Siebel object interfaces provide robust, open interfaces into the Siebel applications,
supporting seamless integration between Siebel applications and external
applications.
Siebel object interfaces definitions are based on Siebel business objects and
declarative object definitions that can be configured and automatically upgraded to
successive releases using Siebel Tools, providing unparalleled ease of configuration
and maintenance.
Siebel object interfaces are available to developers through the following
technologies:
Version 6.0
2-3
Programming
Chapter Overview
The Siebel object interfaces are a collection of methods on Siebel objects that
expose their data and functions to custom routines written in Siebel VB, Siebel
eScript, and also to other languages external to the Siebel application. The
interfaces provide access to Siebel business objects with defined methods, events,
and data.
Caution: Your Siebel application is a high-performance web-based or
client/server application specifically designed to meet the most
rigorous sales and marketing information requirements of large
multinational corporations. Use caution when extending the Siebel
applications or accessing them through the interface described here;
these things should be done only by trained technical professionals.
Improper application configuration or use of these interfaces can
cause your configured Siebel application to be less reliable, or to
perform poorly. Always test your configured application thoroughly
before production rollout.
2-4
Version 6.0
Programming
Siebel Object Interfaces
Version 6.0
2-5
Programming
Siebel Object Interfaces
External Application
COM Data Server
Applicaton Object Manager
Application
Business Component
Data Manager
Business Object
Siebel Database
Figure 2-1.
2-6
Version 6.0
Programming
Siebel Object Interfaces
From an external programming language, with display of the user interface. This
mode is called the Siebel COM Automation Server. This mode allows Siebel to
run as it normally does when a user invokes the standard Siebel application, and
provides access by external applications to the same Siebel objects through the
Siebel object interfaces. The Siebel COM Automation Server can be used for
controlling and testing a Siebel applications user interface objects and
underlying business objects from an external application.
Figure 2-2 shows how the Siebel COM Automation Server is used by external
applications to control the Siebel application.
Client
Siebel Application
Application
User Interface
External
Application
Applet
Business Component
Business Object
Data Manager
Control
Siebel Database
Figure 2-2.
NOTE: The programming environment you use may impose limitations on the
functionality of COM servers. For example, code using the Data Server written in VB
should not be implemented as an NT service.
Version 6.0
2-7
Programming
Siebel Object Interfaces
You can expect differences in performance between the Siebel COM Data Server and
the Siebel COM Automation Server. This is due in part to the fact that the Data
Server is a DLL running in the same address space as the calling program, while the
Automation Server is an executable that runs in its own address space.
You should also be aware that the COM Automation server will cause updates to the
user interface, which will affect performance. You can overcome this effect by using
the SuppressNotification method. See SuppressNotification on page 3-159
for details.
The Siebel ActiveX interfaces enable external applications to access Siebel business
objects. Using ActiveX-based interfaces, accessing Siebel business objects can be
accomplished in the following ways:
2-8
Version 6.0
Programming
Siebel Object Interfaces
Any external application that uses the Siebel ActiveX interfaces will connect and
communicate with the Siebel Application Object Manager, which could be running
on a remote Siebel Server. Siebel Application Object Manager is a multi-threaded,
multi-process application server that hosts Siebel business objects and supports
session-based connections by clients.
Figure 2-3 shows how external applications use the ActiveX Application Control and
ActiveX Data Control to communicate with the Siebel application.
C lie nt
C lie n t
E x te rn a l A p p lic ation
A p p lic ation
A pp le t
B u sine ss C o m p o n e nt
B u s in e ss O b je ct
C o n tro l
A p p lica tio n
B u sin e ss C o m p o n e n t
B u sin es s O b je ct
D ata C o n tro l
TCP/IP
S ie b e l O b je ct M an a g e r
A p p lic ation O b je ct
M an a g e r
S ie b e l S e rve r
D a ta M a n ag e r
S ieb e l D a tab a se
Figure 2-3.
Version 6.0
Using the Siebel ActiveX Application Control and Siebel ActiveX Data Control
2-9
Programming
Siebel Object Interfaces
The Siebel Java Data Bean enables external applications to access Siebel objects
without having to display the Siebel user interface. These objects are made available
through the Siebel Java Data Bean, which can be used by an external application or
Java applet. The Java Data Bean provides functional access to the Siebel
applications for both reading and writing data. The set of interfaces exposed
through this interface is similar to that exposed by the Siebel ActiveX Data Control.
Any external application that uses the Siebel Java Data Bean will connect and
communicate with the Siebel Client Administration Manager, which could be
running on a remote Siebel Server. Siebel Client Administration Manager is a multithreaded, multi-process application server that hosts Siebel objects and supports
session-based connections by clients.
2-10
Version 6.0
Programming
Siebel Object Interfaces
S ie b e l C O R B A O b je ct M a n a g e r
C O R B A In te rfa ce
A p p lica tio n
O b je ct M a n a g e r
C O R B A C lie n t
A p p lica tio n
A p p lica tio n F a cto ry
B u sin e ss C o m p o n e n t
B u sin e ss O b je ct
D a ta M a n a g e r
S ie b e l D a ta b a se
Figure 2-4.
Version 6.0
2-11
Programming
Siebel Object Interfaces
a Choose Start
2-12
Version 6.0
Programming
Siebel Object Interfaces
c To the end of the value in the Value field, add the following:
;C:\Siebel;C:\sieb60\bin;C:\CORBAOM
If these are not the names you used for the indicated directories, change the
text to reflect whats on the hard drive.
d Click OK.
In Windows 95 or 98:
a Choose Start
Run.
Version 6.0
2-13
Programming
Siebel Object Interfaces
Built-In Scripting
You can access Siebel methods and events from within the Siebel application
through Siebel VB or Siebel eScript. Both languages are complete procedural
programming languages that allow you to write custom extensions that access and
control Siebel objects via the Siebel object interfaces.
Table 2-1 is intended to help you determine which types of Siebel object interfaces
to use.
Table 2-1.
Usage Evaluation
Siebel COM
Automation
Server
Usage
Siebel COM
Data Server
Siebel CORBA
Interfaces
Objects execute on a
Siebel Server
2-14
Siebel Java
Data Bean
(if hosted)
Access Siebel
business objects
without Siebel user
interface
Siebel ActiveX
Data Control
Siebel ActiveX
Application
Control
Version 6.0
Programming
Object Types Exposed
Siebel object interfaces provide access to Siebel business objects. The exposed types
of objects are:
Version 6.0
2-15
Programming
Object Types Exposed
The application object represents the Siebel application that is currently active and
is an instance of the Application object type. An application object is created when
a Siebel software application is started. This object contains the properties and
events that interact with Siebel software as a whole. An instance of a Siebel
application always has exactly one application object.
Siebel Application Control and Siebel Data Control are the names of the Application
Objects available through the Siebel ActiveX Application Control and Siebel ActiveX
Data Control, respectively.
NOTE: The Siebel Application Control and Siebel Data Control are provided in the
2-16
Version 6.0
Programming
Object Types Exposed
A business component defines the structure, the behavior, and the information
displayed by a particular subject such as a product, contact, or account. Siebel
business components are logical abstractions of one or more database tables. The
information stored in a business component is usually specific to a particular
subject and is typically not dependent on other business components. Business
components can be used in one or more business objects.
Business component objects have associated data structured as records, they have
properties, and they contain data units called fields. In the object interfaces, fields
are accessed through business components. The business component object
supports getting and setting field values, moving backward and forward through
data in a business component object, and filtering changes to data it manages. This
object type is available to all interfaces.
Business service objects are objects that can be used to implement reusable
business logic within the Object Manager and the Siebel dedicated client. They
include:
Built-in business services, which are defined in Siebel Tools and stored in the
repository
Run-time business services, which are defined in the run-time client and stored
in the application database.
There are two types of built-in business services:
Standard, which are based on the class CSSService and can be scripted or
modified.
Version 6.0
2-17
Programming
Object Types Exposed
Built-in services cannot be modified at run time, nor can they be overridden by runtime scripts.
User-created services can be created by adding a new record to the Business Service
list applet in Siebel Tools. They can also be defined by administrators at run time
by using views in the Siebel client. They can have whatever properties are needed
to accomplish a particular task. They can be called either from scripts or from object
interfaces.
Because they are reusable and can be set to persist throughout a session, business
service objects can be used to simulate global procedures.
2-18
Version 6.0
Programming
Object Types Exposed
Property set objects are collections of properties, which can be used for storing data.
They may have child property sets assigned to them to form a hierarchical data
structure. Property sets are used primarily for inputs and outputs to business
services.
A user interface control object, or simply a control, is a visual object with which
the user can directly interact, such as a button or text box. Control objects have
properties that can be accessed by Siebel object interfaces. Since control objects are
part of the user interface, they are not accessible through the Siebel COM Data
Server, Siebel ActiveX Data Control, and the Siebel CORBA Object Manager.
Controls are the visible building blocks of applets. Each control exists only in a
single applet; that is, each control is unique. Only controls on the active (currently
visible) applet are available to Siebel object interfaces. Each control has a unique
name within its containing applet, but control names need not be unique across
all applets.
The control object supports getting and setting values and customized behavior
when used in conjunction with Siebel object interfaces.
Version 6.0
2-19
Programming
Object Types Exposed
Supported only in Siebel CORBA Object Manager Interfaces, the Siebel Application
Factory object is the externally visible object. To access the other objects, a bind to
the Siebel Application Factory object has to be made.
2-20
Version 6.0
Programming
Object Types Exposed
Object
Type
Siebel COM
Automation
Server
Applet
SiebelApplet
Application
SiebelApplication
Siebel COM
Data Server
Siebel ActiveX
Application
Control
Siebel ActiveX
Data Control
Siebel Java
Data Bean
Siebel CORBA
Interfaces
SiebelDataControl
SiebelDataControl
SiebelApplication
SiebelApplet
SiebelApplication
SiebelApplication
Control
Application
Factory
SiebelAppFactory
Business
Component
SiebelBusComp
SiebelBusComp
SiebelBusComp
SiebelBusComp
SiebelBusComp
SiebelBusComp
Business
Object
SiebelBusObject
SiebelBusObject
SiebelBusObject
SiebelBusObject
SiebelBusObject
SiebelBusObject
Business
Service
SiebelService
SiebelService
SiebelService
SiebelService
SiebelService
SiebelService
Property
Set
SiebelPropertySet
SiebelPropertySet
SiebelPropertySet
SiebelPropertySet
SiebelPropertySet
SiebelPropertySet
User
Interface
Control
SiebelControl
Version 6.0
SiebelControl
2-21
Programming
Siebel Object Interface Method Syntax
The ActiveX, Java, and CORBA syntax is very similar to that of COM, with the
exception of login, object type names, and error handling.
The following conventions are used in this guide to describe methods, arguments,
and return values:
ObjectType.MethodName(arg1[, arg2, ..., argn])
Syntax
Returns
Argument
Description
arg1
Description of arg1
arg2
Description of arg2
argn
Description of argn
MethodName is the name of the method that is being invoked. A method can
be a subroutine that does not return a value, such as SetViewMode, or a function
that returns a value, such as GetFieldValue.
2-22
Version 6.0
Programming
Siebel Object Interface Method Syntax
If a method does not return a value or if you are using it in a manner that does not
return a value, then the arguments should not be enclosed in parentheses in Siebel
VB. (In Siebel eScript, all arguments must be enclosed in parentheses.)
When the Siebel object interfaces are used through COM, an additional argument,
errCode, is always included as the last argument.
Usage
Syntax
The usage syntax for a method is different under Siebel VB, Siebel eScript, and COM
and is described below. The description uses the following terms in addition to the
ones defined above:
Siebel VB
If there is a return value,
returnValue = ObjectReference.MethodName(arg1, arg2, ..., argn)
Examples
acctName = acctBC.GetFieldValue("Name")
acctBC = acctApplet.GetBusComp
acctBC.SetViewMode AllView
Version 6.0
2-23
Programming
Siebel Object Interface Method Syntax
Siebel eScript
If there is a return value,
returnValue = ObjectReference.MethodName(arg1, arg2, ..., argn);
Examples
acctName = acctBC.GetFieldValue("Name");
acctBC = acctApplet.GetBusComp();
acctBC.SetViewMode(AllView);
COM
The usage depends on the language being used to call the COM Interfaces. For
Microsoft Visual Basic and equivalent languages, the usage is similar to that for
Siebel VB, except for the fact that an error code is passed as the final argument.
2-24
Version 6.0
Programming
Siebel Object Interface Method Syntax
To use the Siebel COM interfaces, you must set the EnableOLEAutomation flag in
the .cfg file to TRUE. For Siebel Interface methods through COM, use the object
browser of your COM programming tool to determine the correct method syntax.
Figure 2-5 displays an example of an object browser in Microsoft Visual Basic 5.0.
Syntax window
Figure 2-5.
Version 6.0
2-25
Programming
Siebel Object Interface Method Syntax
This section presents a series of steps to build a simple COM client in Visual C++
and the Microsoft Foundation Class (MFC) library, which accesses the Siebel Data
Server. This will allow you to build real-time interfaces to Siebel using C++ for
integration purposes.
New Project.
2-26
Version 6.0
Programming
Siebel Object Interface Method Syntax
Version 6.0
2-27
Programming
Siebel Object Interface Method Syntax
6 Click Finish. You will be presented with a Project Information dialog box, as
shown. Click OK.
The Application Wizard generates the standard MFC code that will serve as the
skeleton for this project. All headers and libraries necessary to support COM
automation will be included. (Refer to the Microsoft Visual Studio [MSDN]
documentation for a detailed description of the MFC libraries.)
2-28
Version 6.0
Programming
Siebel Object Interface Method Syntax
7 You will see the workspace with a newly created dialog box. You can resize the
box and change the text in the label by editing its properties. (Right-click the
label in the dialog box to edit its properties.) Modify the dialog box so that it
looks something like this:
Version 6.0
2-29
Programming
Siebel Object Interface Method Syntax
10 In the Confirm Classes dialog box, make sure all five Siebel classes are selected,
and click OK. Click OK again to close the Class Wizard.
2-30
Version 6.0
Programming
Siebel Object Interface Method Syntax
FileView tab
Version 6.0
2-31
Programming
Siebel Object Interface Method Syntax
2-32
Version 6.0
Programming
Siebel Object Interface Method Syntax
d Enter the code that is highlighted in boldface in Figure 2-6 on page 2-34 into
the SiebelCOMDlg.h file.
e Choose File Open and select the SiebelCOMDlg.cpp file. Add the code
that is highlighted in boldface in Figure 2-7 on page 2-35 to the
OnInitDialog procedure.
Version 6.0
2-33
Programming
Siebel Object Interface Method Syntax
In the same file, Add the code that is highlighted in boldface in Figure 2-8 on
page 2-36 and Figure 2-9 on page 2-37 to the OnOKDialog procedure. Make sure
that the line beginning with sApp.LoadObjects points to the location of the .cfg
file you intend to use. In the line beginning with sApp.Login, make sure that you
have entered a valid logon name and password.
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "sobjsrv.h"
class CSiebelCOMDlgAutoProxy;
//////////////////////////////////////////////////////////////
// CSiebelCOMDlg dialog
class CSiebelCOMDlg : public CDialog{
DECLARE_DYNAMIC(CSiebelCOMDlg);
friend class CSiebelCOMDlgAutoProxy;
SiebelApplication sApp;
//declare Siebel object
// Construction
public:
CSiebelCOMDlg(CWnd* pParent = NULL);// standard constructor
virtual ~CSiebelCOMDlg();
Figure 2-6.
2-34
Version 6.0
Programming
Siebel Object Interface Method Syntax
{
CDialog::OnInitDialog();
// Add "About..." menu item to system menu.
// IDM_ABOUTBOX must be in the system command range.
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);
CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}
// Set the icon for this dialog. The framework does this
// automatically when the application's main window
// is not a dialog
SetIcon(m_hIcon, TRUE);
// Set big icon
SetIcon(m_hIcon, FALSE);
// Set small icon
// TODO: Add extra initialization here
// Start the Siebel Data Server
if (!sApp.CreateDispatch(_T("SiebelDataServer.ApplicationObject")))
{
AfxMessageBox("Cannot start Siebel Data Server.");
EndDialog(-1); //fail
} else
{
AfxMessageBox("Siebel Data Server initialized.");
}
return TRUE;
// return TRUE
Figure 2-7.
Version 6.0
2-35
Programming
Siebel Object Interface Method Syntax
short sErr;
//Load Configuration File
// Make sure that The following line points to the configuration
// file you intend to use!
sApp.LoadObjects("C:\\siebel\\bin\\siebel.cfg", &sErr);
if(sErr)
{
AfxMessageBox("LoadObjects failed.");
return;
} else
{
AfxMessageBox("CFG file loaded.");
}
//Login as Sadmin
sApp.Login("SADMIN", "SADMIN", &sErr);
if (sErr)
{
AfxMessageBox("Login failed.");
return;
} else
{
AfxMessageBox("Logged into Siebel database.");
}
//Get Account BusObject
LPDISPATCH lpdBo;
lpdBo = sApp.GetBusObject("Account", &sErr);
if (sErr)
{
AfxMessageBox("GetBusObject failed.");
return;
} else
{
AfxMessageBox("Account BusObject retrieved.");
}
SiebelBusObject Bo(lpdBo);
Figure 2-8.
2-36
Version 6.0
Programming
Siebel Object Interface Method Syntax
Figure 2-9.
Version 6.0
2-37
Programming
Siebel Object Interface Method Syntax
Once you have finished creating your program, you must test it to ensure that it
works properly.
A message box should display the message Siebel Data Server initialized.
7 You should see a series of message boxes, with the following messages:
a CFG file loaded.
b Logged into Siebel database.
c Account BusObject retrieved.
d Account BusComp retrieved.
e The name of the first account in the All Accounts view.
2-38
Version 6.0
Programming
Siebel Object Interface Method Syntax
For Siebel Interface methods through ActiveX, use the object browser of your
ActiveX programming tool to determine the correct method syntax. Figure 2-10
displays an example of an object browser using Microsoft Visual Basic 6.0.
Syntax window
Figure 2-10. Determining the Correct Syntax for ActiveX Interfaces in Microsoft Visual Basic
Version 6.0
2-39
Programming
Siebel Object Interface Method Syntax
References.
5 In the list box, highlight (but do not check) Siebel BusObject Interfaces Type
Library. Near the bottom of the dialog box, note the directory in which the file
sstchca.dll resides, as shown below. (It should be the C:\Program
Files\Siebel\tclient\bin directory subsidiary to the thin client install
directory.)
6 If the location is the same as that of the .cfg file, check the box and click OK.
If the location is not the same, proceed to Step 7.
7 In the Windows Explorer, open the directory containing the .cfg file to use. By
default, the .cfg files should be in the bin directory.
8 Double-click the file sstchca.dll. Repeat Step 5 and Step 6.
9 Open the Object Browser, as shown in Figure 2-10 on page 2-39, to verify that
you can see the Siebel objects.
2-40
Version 6.0
Programming
Siebel Object Interface Method Syntax
Login Method
The syntax of the Login method is the same as that explained in Login Differences
on page 2-41.
Error Handling
See Error-Handling Differences on page 2-45 for information concerning CORBA
error handling.
Automation Server and Data Server, all parameters, including optional ones if they
are being used, must be specified.
Login Differences
COM Automation Server. The Siebel COM Automation Server does not support login,
since it connects to the existing Siebel application.
Application Control, ActiveX Data Control, Java Data Bean, and CORBA Object
Manager.
The Login method that is available through the ActiveX Application Control and
Data Control and CORBA objects has a different syntax from those in the Siebel
COM interfaces. It takes three parameters:
Version 6.0
2-41
Programming
Siebel Object Interface Method Syntax
The connect string is a URL containing all the information needed to connect to any
Siebel Server component. It specifies both the protocol and the details of the Client
Application Manager service in the Siebel Servers to which the client will connect.
The generic form of the syntax for the connect string is:
siebel[[.transport][.[encryption][.[compression]]]]://
host[:port]/EnterpriseServer/AppObjMgr[/SiebelServer]
Note that the entire protocol string is optional. You may specify the transport
protocol alone, separating it from siebel with a single period; however, if you
specify any of the other protocols, a period must be used as a placeholder for each
protocol not specified, for example:
siebel...pkware://host/siebel/AppObjMgr
Protocols that are not specified receive their default values, as shown in Table 2-3
on page 2-43.
2-42
Version 6.0
Programming
Siebel Object Interface Method Syntax
In Place Of
Insert
transport
(Sheet 1 of 2)
none
zlib (the default)
pkware
loadbalanced
Version 6.0
host
port
The gateway port; by default 2320. This will change only if the Siebel
Adminster has changed the default during installation
EnterpriseServer
2-43
Programming
Siebel Object Interface Method Syntax
Table 2-3.
(Sheet 2 of 2)
In Place Of
Insert
AppObjMgr
The name of the defined Application Object Manager that you want the
thin client to access; this can be a user-defined component or one of
these predefined components:
SCCObjMgr
SSEObjMgr
ISSObjMgr
SSVObjMgr
(For more information, see the Siebel System Administration Guide.)
SiebelServer
See Login on page 3-70 for more detailed information about this method.
2-44
Version 6.0
Programming
Siebel Object Interface Method Syntax
Error-Handling Differences
Version 6.0
2-45
Programming
Siebel Object Interface Method Syntax
It is used as follows:
...
import com.siebel.common.common.SiebelException;
...
try
{
// do any operations that can raise the SiebelException
exception
SiebelDataControl m_dataControl = new SiebelDataControl ();
m_dataControl.login ("SOMSERVER, somsiebel, AppObjMgr,
SOMSERVER", "CCONWAY", "CCONWAY");
}
{
.
.
.
}
catch (SiebelException e)
{
// any errors in the preceding try block are handled here
System.out.println (e.getErrorMessage ());
}
2-46
Version 6.0
Programming
Siebel Object Interface Method Syntax
EnableExceptions Method
EnableExceptions(enable as integer)
The EnableExceptions method enables applications to use the native COM errorhandling technique. If the method is about to fail due to error, then a COM exception
will be generated and the method will not return. The COM host will receive the
control instead. However, it may display the error message (this is default for
Microsoft Internet Explorer or VB), but it can be changed by scripting.
Version 6.0
2-47
Programming
Getting Started with the Siebel Object Interfaces
Directions follow for connecting to the COM Servers, ActiveX Controls, or ORBs:
The Siebel COM Automation Server accesses the server object instantiated by the
Siebel eBusiness Application. Once you have this object, you can obtain other Siebel
objects and execute Siebel object interface methods through those objects. Calls
made to the Siebel COM Automation Server are out of process. If you create a DLL
that is run in process with the Siebel application, the calls made from the DLL to
the Siebel COM Automation Server are still out of process.
The mechanism for instantiating COM servers depends on the programming tool or
language being used.
If you are using Microsoft Visual Basic 5.0 or later, the required support file must
be in the same directory as the .cfg file you are using for your Siebel application, or
the COM Automation Server will not work. Take the following steps to ensure that
you are referencing the correct library.
2-48
References.
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
4 In the list box, highlight (but do not check) Siebel BusObject Interfaces. Near the
bottom of the dialog box, note the directory in which the file sappsrv.tlb
resides, as shown below.
5 If the location is the same as that of the .cfg file, check the box and click OK.
If the location is not the same, proceed to Step 6.
6 In Windows Explorer, open the directory containing the .cfg file to use. By
default, the .cfg files should be in the bin directory.
7 Double-click the file sapptlb.reg. Repeat Step 4 and Step 5.
Caution: Do not attempt to use sobjsrv.tlb together with
Version 6.0
2-49
Programming
Getting Started with the Siebel Object Interfaces
The following examples show how to use Microsoft Visual Basic 6.0 to interface
with Siebel COM Automation Server.
The following is sample code for the Siebel COM Automation Server:
Private Sub SiebAppServ_Click()
Dim SiebelApp As Object
Dim CurrentBC As Object
Dim theName As String
Dim errCode As Integer
Set SiebelApp = GetObject("", _
"SiebelAppServer.ApplicationObject")
theName = SiebelApp.LoginName(errCode)
MsgBox "You are logged in as " & theName
Set CurrentBC = SiebelApp.ActiveBusComp(errCode)
If Not CurrentBC Is Nothing Then
MsgBox "The current active Business Component is " & _
CurrentBC.Name(errCode)
End If
End Sub
Because the Siebel COM Data Server acts without the regular Siebel eBusiness
Application User Interface, you must use the Login method to set up your Data
Server object. Also, you cannot use methods that retrieve active Siebel objects,
because there are no current active Siebel objects. You must instantiate your own
Siebel objects. Calls made to the Siebel COM Data Server are in process.
Caution: Any variables that are set in the Application_Start event
will not be available to methods invoked by the COM Data Server,
because when you run a COM Data Server, no Siebel client exists.
Therefore, the Application_Start event is never invoked.
2-50
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
If you are using Microsoft Visual Basic 5.0 or later, the required support file,
sobjsrv.tlb, must be in the same directory as the .cfg file you are using for your
Siebel application, or the COM Data Server will not work. Take the following steps
to ensure that you are referencing the correct library.
To set up Microsoft Visual Basic to access the Siebel COM Data Server
1 Start Microsoft Visual Basic.
2 Select Standard EXE.
3 Choose Project
References.
4 In the list box, highlight (but do not check) Siebel Data BusObject Interfaces.
Near the bottom of the dialog box, note the directory in which the file sobjsrv.tlb
resides, as shown below.
5 If the location is the same as that of the .cfg file, check the box and click OK.
If the location is not the same, proceed to Step 6.
Version 6.0
2-51
Programming
Getting Started with the Siebel Object Interfaces
6 In Windows Explorer, open the directory containing the .cfg file to use. By
default, the .cfg files should be in the bin directory.
7 Double-click the file sobjtlb.reg. Repeat Step 4 on page 2-51 and Step 5 on
page 2-51.
Caution: Do not attempt to use sobjsrv.tlb together with
2-52
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
The following is sample code for the Siebel ActiveX Application Control:
Sub Login_Click()
SiebelApplicationControl1.Login "host=""siebel//:host/
EnterpriseServer/AppObjMgr/SiebelServer""", "CCONWAY", "CCONWAY"
If SiebelApplicationControl1.GetLastErrCode() Then
MsgBox ("Login error")
End If
SiebelApplicationControl1.GotoView "Account List View", Nothing
End Sub
See Table 2-3 on page 2-43 for values to substitute for the placeholders in the login
string.
Version 6.0
2-53
Programming
Getting Started with the Siebel Object Interfaces
User interface methods are normally not relevant on the thin client because they are
processed on either the Windows Object Manager or the Unix Object Manager,
neither of which has a user interface. However, the ActiveX Thin Client embedded
in Internet Explorer can be manipulated by client-side JavaScript. Therefore, you
can use any ActiveX application controls using client-side JavaScript.
The following code demonstrates the use of client-side JavaScript to access
application controls via a thin client. This example uses the sample database. You
must log on with one of the sample IDs: SADMIN, CCONWAY, and so on. See
Table 2-3 on page 2-43 for values to substitute for the placeholders in the login
string.
<html>
<head><script language="JavaScript">
<!-function wndLoad()
{
}
function navigate()
{
name = SiebelApplicationControl1.LoginName();
position = SiebelApplicationControl1.PositionName();
alert ("Using JavaScript to navigate " + name + ", " +
position + ", to the last record on All Account List View");
Obj = SiebelApplicationControl1.GetBusObject ("Account")
SiebelApplicationControl1.GotoView('All Account List View', Obj);
comp = SiebelApplicationControl1.ActiveBusComp();
comp.LastRecord();
}
-->
</script>
<title>Siebel Thin Client</title>
</head>
2-54
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
To instantiate and use the Siebel ActiveX Data Control, you must use the
CreateObject and Login methods. You cannot use methods that retrieve active Siebel
objects, because there are no current active Siebel objects. You must instantiate all
of your own Siebel objects. Calls made to the Siebel ActiveX Data Control are also
in-process.
The following is the sample code for the Siebel ActiveX Data Control.
Sub CreateDataControl()
Dim errCode As Integer
Set SiebelApplication =
CreateObject("SiebelDataControl.SiebelDataControl.1")
SiebelApplication.Login "host=""siebel//:host/EnterpriseServer/
AppObjMgr/SiebelServer""", "CCONWAY","CCONWAY"
Version 6.0
2-55
Programming
Getting Started with the Siebel Object Interfaces
errCode = SiebelApplication.GetLastErrCode()
If errCode <> 0 Then
ErrText = SiebelApplication.GetLastErrText
MsgBox ErrText
Exit Sub
End If
set OpptyB0 = SiebelApplication.GetBusObject("Opportunity",errCode)
set OpptyBC = OpptyBO.GetBusComp("Opportunity", errCode)
End Sub
See Table 2-3 on page 2-43 for values to substitute for the placeholders in the login
string.
Here is sample code for instantiating the ActiveX Data Control from a server-side
ASP script. For full details, see the Siebel Client Installation and Administration
Guide.
NOTE: The symbols <% and %> are used within HTML script to set off an ASP script.
<%
Dim SiebelApplication, BO, BC, ConnStr, logstat
Dim strLastName, strFirstName, errCode, errText
Set SiebelApplication =
CreateObject("SiebelDataControl.SiebelDataControl.1")
' Test to see if object is created
If IsObject(SiebelApplication) = False then
Response.Write "Unable to initiate Siebel Session.
Else
ConnStr = "host = " & Chr(34) & "siebel//:host/
EnterpriseServer/AppObjMgr/SiebelServer" & Chr(34) & " Lang = " &
Chr(34) & "ENU" & Chr(34)
logstat = SiebelApplication.Login ConnStr, "SADMIN",
"SADMIN"
response.write(Login Status: & logstat)
Set BO = SiebelApplication.GetBusObject("EMPLOYEE")
Set BC = SBusObj.GetBusComp("EMPLOYEE")
End If
%>
2-56
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
To instantiate and use the Siebel Java Data Bean, you must instantiate a new
SiebelDataBean Java object and call its login method. You cannot use methods that
retrieve active Siebel objects, because there are no current active Siebel objects. You
must instantiate all of your own Siebel objects.
The following is the sample code for the Siebel Java Data Bean.
import com.siebel.data.*;
import com.siebel.data.SiebelException;
public class DataBeanDemo
{
private SiebelDataBean m_dataBean = null;
private SiebelBusObject
m_busObject = null;
private SiebelBusComp
m_busComp = null;
public static void main(String[] args)
{
DataBeanDemo demo = new DataBeanDemo();
}
public DataBeanDemo()
{
try
{
// instantiate the Siebel Data Bean
m_dataBean = new SiebelDataBean();
// login to the server
m_dataBean.login("SOMSERVER, somsiebel, AppObjMgr,
SOMSERVER", "CCONWAY", "CCONWAY");
// get the business object
m_busObject = m_dataBean.getBusObject("Opportunity");
// get the business component
m_busComp = m_busObject.getBusComp("Opportunity");
// logoff
m_dataBean.logoff();
}
catch (SiebelException e)
{
System.out.println(e.getErrorMessage());
}
}
}
Version 6.0
2-57
Programming
Getting Started with the Siebel Object Interfaces
To initialize and start running the client application, a bind operation has to be
performed to bind the client application to the Application factory object in the
Siebel CORBA Application Object Manager. The bind operation creates a separate
Siebel CORBA Application Object Manager thread. After binding to the factory
object, the Siebel Application Object can be created and initialized. The name of the
host machine is optionally included as an argument to the bind call. If the host
machine is a local machine, the host machine name need not be passed as an
argument to the bind operation. The SiebelObjectFactory is the name of the factory
object. The name of the server specified in the bind call (for example,
SiebelCorbaServer in the sample code below) should be the same as the server
name provided when you configured the Siebel CORBA Application Object
Manager.
The bind operation returns a reference to the Siebel Application Factory Object.
NOTE: See the Siebel System Requirements and Supported Platforms document for
2-58
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
After the bind and creation of the Siebel Application Object, the application must
log on to the Siebel Application Object Manager to access the Siebel business
objects. At the end of the session, the client can log off the session using the Logoff
method.
The sample code below illustrates the invocation of the Login and GetBusObject
methods to communicate with the Siebel Application Object Manager.
try {
// call the login method to access the Siebel application
appObj->Login("CCONWAY", "CCONWAY");
// Get the reference to the Accounts business object
pBusObj = appObj->GetBusObject("Account");
} catch (SiebelException& excep) {
cerr << "Error code : " << excep.id << endl;
cerr << "Error text : " << excep.desc << endl;
return;
}
Version 6.0
2-59
Programming
Getting Started with the Siebel Object Interfaces
When using Inprise's Visibroker ORB, the client application must bind to the Siebel
Application Factory object as the Orbix clients do. However, the name of the host
machine need not be passed on as an additional argument to the bind call.
NOTE: See the Siebel System Requirements and Supported Platforms document for
2-60
Version 6.0
Programming
Getting Started with the Siebel Object Interfaces
After the bind and creation of the Siebel Application Object, the application must
log on to the Siebel Application Object Manager to access the Siebel business
objects. At the end of the session, the client can log off the session using the Logoff
method.
The sample code below illustrates the invocation of the Login and GetBusObject
methods to communicate with the Siebel Application Object Manager.
try {
// call the login method to access the Siebel application
appObj->Login("CCONWAY", "CCONWAY");
// Get the reference to the Accounts business object
pBusObj = appObj->GetBusObject("Account");
} catch (SiebelException& excep) {
cerr << "Error code : " << excep.id << endl;
cerr << "Error text : " << excep.desc << endl;
return;
}
Any variables that are set in the Application_Start event will not be visible to
methods invoked by the COM Data Server. This is because running a COM Data
Server means by definition that no Siebel client exists and therefore the
Application_Start event is never invoked.
Version 6.0
2-61
Programming
Siebel Object Interface Methods
Locating objects. These are methods that enable the user to locate instances of
objects so that they can be manipulated by other methods.
Accessing business components. These are methods that provide the ability to
Navigation. These are methods that provide a way to control the flow of the
application as it is presented to the user by explicitly setting the focus of the
application to the desired view, applet, or control. These methods are useful only
when accessing the Siebel object interfaces from Siebel VB, when accessing
Siebel as a COM Automation Server, or through the Siebel ActiveX Application
Control, in which cases Siebel presents its user interface. When Siebel is
accessed through the COM Data Server, ActiveX Data Control, Java Data Bean,
or CORBA Application Object Manager, no Siebel user interface is present.
Manipulating controls. These are the methods that set or get the value of a control.
These methods are useful only when accessing the Siebel object interfaces from
Siebel VB, when accessing Siebel as a COM Automation Server, or through the
Siebel ActiveX Application Control, in which cases Siebel presents its user
interface.
Global state properties and functions. These are methods that enable you to get
User interaction. These are methods that provide user interface elements similar
Creating a Siebel application in CORBA. There is one method that is used to create
2-62
Version 6.0
Programming
Siebel Object Interface Methods
Locating Objects
This set of methods allows the user to locate instances of objects within Siebel
applications so they can be used by other methods. Active objects are instances of
objects that currently have focus. The active control is the control that currently has
the user interface focus. The active applet is the applet that contains the active
control. The active business component is the business component associated with
the active applet. Once located, an object can be used or manipulated by Siebel
object interfaces.
The following methods are used for locating objects.
ActiveControl on page 3-25
Version 6.0
2-63
Programming
Siebel Object Interface Methods
BusComp.LastRecord
BusComp.PreviousRecord
BusComp.NextSelected
BusComp.FirstRecord
BusComp.DeleteRecord
(DeleteRecord commits
automatically, since it moves the
cursor to another record.)
2-64
Version 6.0
Programming
Siebel Object Interface Methods
The next example shows how to instantiate your own BusObject and BusComp.
This example uses the PreSetFieldValue event of the Opportunity BusComp. If the
Sales Stage is updated to 07 - Verbal Agreement, a decision maker must be
associated with the opportunity. Otherwise, it will be reset to the previous value.
The Contacts for the selected opportunity will be searched to see if any vice
president or president is associated with the opportunity.
Version 6.0
2-65
Programming
Siebel Object Interface Methods
2-66
Version 6.0
Programming
Siebel Object Interface Methods
Sales
Cycle to Verbal Agreement.")
RetValue = CancelOperation
Else
MsgBox("A decision maker was found")
End If
End With
End If
End Select
BusComp_PreSetFieldValue = RetValue
End Function
Version 6.0
2-67
Programming
Siebel Object Interface Methods
2-68
Version 6.0
Programming
Siebel Object Interface Methods
Navigation
The navigation methods set the focus for user interaction to the named view.
Table 2-4 identifies the navigation methods.
NOTE: Properties for Siebel objects such as business component applets and
business components are stored in the repository and cannot be changed at run
time using Siebel VB methods.
Table 2-4.
Navigation Methods
Method
Drilldown on page 3-29
GotoControl on page 3-33
GotoApplet on page 3-63
GotoView on page 3-64
User Interaction
The following methods allow the Siebel extension routines to interact directly with
the user through traditional user interface techniques. These methods are similar to
the standard procedures available to Windows programs. User interaction methods
are listed in Table 2-5.
Table 2-5.
Method
InputBox on page 3-66
MsgBox on page 3-75
ShowStatus on page 3-84
Version 6.0
2-69
Programming
Siebel Object Interface Methods
Manipulating Controls
The following methods are provided to interact with controls. These methods take
the control as the first argument and return information about the control or change
the state of the control. Control manipulation methods are listed in Table 2-6.
Table 2-6.
Method
PostChanges on page 3-37
GetProperty on page 3-227
SetProperty on page 3-231
The application object provides a set of properties and functions that return
information about the current state of the system. This information is useful when
you are processing rows of data or generating query criteria. Global state methods
are listed in Table 2-7.
Table 2-7.
Method
CurrencyCode on page 3-54
EnableExceptions on page 3-55
GetLastErrCode on page 3-58
GetLastErrText on page 3-59
LoginId on page 3-72
LoginName on page 3-73
Logoff on page 3-74
NewPropertySet on page 3-78
PositionName on page 3-80
2-70
Version 6.0
Programming
Siebel Object Interface Methods
The method in Table 2-8 provides a way to create a Siebel application object in
CORBA.
Table 2-8.
Method
CreateSiebelAppObject on page 3-245
Version 6.0
2-71
Programming
Variable Scoping for Siebel Script Variables
Local Variables
Local variables defined within a Siebel script are the lowest level of variable
scoping. These variables are declared using the Dim statement in Siebel VB or the
var statement in Siebel eScript, and their values are accessible only within the script
in which they were defined.
VB example:
Sub Applet_GotFocus
Dim localStr as String
End Sub
eScript example:
function Applet_GotFocus ()
{
var localStr;
{
Module Variables
Module variables defined in the (general) (declarations) section of a Siebel object
(such as an applet or business component) are the next level of variable scoping.
These variables are available as long as the object is instantiated and the values are
accessible to all scripts in the same object or module. Use Dim statements (for VB)
or var statements (for eScript) in the (general) (declarations) section to declare
module variables.
VB example:
(general) (declarations)
Dim ContactId as String
2-72
Version 6.0
Programming
Variable Scoping for Siebel Script Variables
Global Variables
At the highest level are the global variables. These variables must be declared in
every module that needs to access their values. They are declared with the Global
statement. Avoid using global variables to store Siebel objects such as BusComp and
BusObject. If this is necessary, always set these variables to Nothing whenever the
objects are no longer required, or at least in the Application_Close event. Failure to
do so may cause memory problems because the objects being referenced cannot be
freed from memory while they are still being referenced. If you must create a global
variable for a business component, make sure there is a global variable for the
business object; otherwise the business component will be out of scope.
Example:
(general)(declarations)
Option Explicit
'for every module that uses this variable
Global gVar as Integer
Version 6.0
2-73
Programming
Variable Scoping for Siebel Script Variables
Siebel provides two sets of methods to send values for variables back and forth
between the Siebel application and external applications. Inter-application
communication methods are listed in Table 2-9.
Table 2-9.
Method
GetUserProperty on page 3-128
SetUserProperty on page 3-156
GetLastErrCode on page 3-58
SetSharedGlobal on page 3-82
Tracing
Application event methods for controlling debug tracing include those in Table 2-10.
Table 2-10.
Method
Trace on page 3-85
TraceOff on page 3-87
TraceOn on page 3-88
2-74
Version 6.0
Programming
Siebel Object Interface Events and Siebel Extension Events
Available only for Siebel VB and Siebel eScript, selected events within the Siebel
applications allow the association of extension routines that extend the base
behavior of the application. When the Siebel application fires or activates the event,
the user-specified procedures will be invoked along with the standard Siebel
procedures. The event names listed under Siebel Business Component Events on
page 2-81 or User Interface Control Events on page 2-82 refer to the tag or entry
point used to tie the extension routine to a particular action or event.
For each event in these sections, the following information is provided:
ObjectReference is the variable name of the object on which the event is invoked.
Version 6.0
2-75
Programming
Siebel Object Interface Events and Siebel Extension Events
You can take advantage of preoperation events to alter standard Siebel behavior.
For example, the PreDeleteRecord event can be used to perform additional,
customer-specific validation on the record about to be deleted, and if the validations
fail, the DeleteRecord operation can be canceled.
Postoperation events are useful when the event relies on data that may have
been updated in the course of executing the standard Siebel event.
For every Siebel operation event handler, there is also a preoperation event handler.
Generally, scripts are placed in the preoperation event. You can alter the effect of an
event by attaching a script to the preoperation event handler. The events with the
most far-reaching effects are the PreInvokeMethod events. In a PreInvokeMethod
event, you can call a method that substitutes for the internal Siebel code.
2-76
Version 6.0
Programming
Siebel Object Interface Events and Siebel Extension Events
As Figure 2-12 illustrates, you can change the outcome of an event by specifying the
return value on the preoperation events. The standard return value for preoperation
events is ContinueOperation, which tells the calling Siebel object to continue
processing the remaining operations associated with the event (Step 2).
S te p 1
PreInvokeMethod
Event fires to run VB or
eScript code
CancelOperation
ContinueOperation
S te p 2
S te p 3
InvokeMethod
Stop
Stop
If you wish to create an alternative to an existing routine, simply change the return
value in your custom event handler to CancelOperation. This tells Siebel to cancel
the remaining operations associated with the event. If, for example, the validation
in the PreDeleteRecord event fails, set the return value for the event to
CancelOperation. If you wish to do some preprocessing before the default event
method executes, use the return value ContinueOperation.
Version 6.0
2-77
Programming
Siebel Object Interface Events and Siebel Extension Events
The post-event handler is rarely scripted, but may be used for such post-operation
events as posting a notice to a log when the event completes successfully.
The following Siebel VB example sets up a validation routine in which a specific
field is queried to determine whether the event should fire.
Function BusComp_PreSetFieldValue (FieldName As String,
FieldValue As String) As Integer
' Routine to check if a quote discount > 20%
'
if it is, notify user and cancel the operation
Dim value as Integer
Dim msgtext as String
If FieldName = "Discount" then
value = Val(FieldValue)
If value > 20 then
msgtext = "Discounts greater than 20% must be approved"
msgbox (msgtext)
BusComp_PreSetFieldValue = CancelOperation
Else
BusComp_PreSetFieldValue = ContinueOperation
End if
End If
End Function
Within this structure, the custom routine is executed only if the condition is true. If
the condition is true, the custom routine substitutes for the built-in routine. If it is
not true, the built-in routine is executed because the event handler returns
ContinueOperation.
2-78
Version 6.0
Programming
Siebel Object Interface Events and Siebel Extension Events
Note that in PreInvokeMethod events, the condition should always be a test for the
method name; for example,
if (methodName = "PushOpportunity")
Alternatively, especially if more than one method may be invoked, you may find it
more efficient to use a Select structure (in VB) or a switch structure (in eScript). In
Siebel VB:
Dim iReturn As Integer
iReturn = ContinueOperation
Select Case methodName
Case "PushOpportunity"
[custom routine]
iReturn = CancelOperation
Case "Stage3"
[custom routine]
iReturn = CancelOperation
End Select
object_PreInvokeMethod = iReturn
Version 6.0
2-79
Programming
Siebel Object Interface Events and Siebel Extension Events
In Siebel eScript:
var iReturn;
switch methodName
{
case "PushOpportunity":
[custom routine]
iReturn = CancelOperation;
break;
case "Stage3":
[custom routine]
iReturn = CancelOperation;
break;
default:
iReturn = ContinueOperation;
}
object_PreInvokeMethod() = iReturn;
To make your code easier to read and maintain, you can create the custom routines
as sub-programs or functions in the (general) (declarations) section.
There is no simple way to determine when various events occur, as many different
events can occur when a view becomes current or when an object is invoked. The
only reliable way to find out the exact order of events is to place a line of code of
the following form in each event handler (including the Pre event handlers) for the
view or object, including insert, delete, write, business component, and any others
that may apply:
MsgBox "Event_Name fired."
Then do some simple inserts, updates, and deletes, and make a note of each
message as it appears. You will then have a list of the order in which events fire on
that view or for that object.
With applet events, the Applet_GotFocus event fires as soon as the applet receives
focus, whether or not it is active.
2-80
Version 6.0
Programming
Siebel Object Interface Events and Siebel Extension Events
Events can be invoked from data operations on business components. These are
defined on a per-business component basis. Events can be invoked before or after
the specified standard behavior.
If you want to trap for modifications to a multi-value field, be aware that
PreSetFieldValue and SetFieldValue events for the parent business component will
be called only if the multi-value field is modified without popping up the multivalue group applet. (In some cases, the user will be prevented from making changes
to the field in this manner, in which case the PreSetFieldValue event on the parent
business component will be called, and then the user will be forced to edit the field
using the MVG applet.) If the user makes changes to the multi-value field through
the MVG applet, then only the events on the MVG business component will be
called; no events on the parent business component will be called.
BusComp events are listed in Table 2-11.
Table 2-11.
BusComp Events
(Sheet 1 of 2)
Method
BusComp_Associate on page 3-164
BusComp_ChangeRecord on page 3-165
BusComp_PreCopyRecord on page 3-172
BusComp_CopyRecord on page 3-167
BusComp_InvokeMethod on page 3-169
BusComp_NewRecord on page 3-170
BusComp_PreAssociate on page 3-171
BusComp_PreDeleteRecord on page 3-173
BusComp_PreGetFieldValue on page 3-175
BusComp_PreInvokeMethod on page 3-176
BusComp_PreNewRecord on page 3-177
BusComp_PreQuery on page 3-178
Version 6.0
2-81
Programming
Siebel Object Interface Events and Siebel Extension Events
Table 2-11.
BusComp Events
(Sheet 2 of 2)
Method
BusComp_PreSetFieldValue on page 3-179
BusComp_PreWriteRecord on page 3-181
BusComp_Query on page 3-182
BusComp_SetFieldValue on page 3-184
BusComp_WriteRecord on page 3-185
Events are invoked in response to user interactions. These can be managed on a percontrol basis. User interface events are listed in Table 2-12.
Table 2-12.
(Sheet 1 of 2)
Method
Applet_ChangeFieldValue on page 3-38
Applet_ChangeFieldValue on page 3-38
Applet_ChangeRecord on page 3-39
Applet_InvokeMethod on page 3-42
Applet_Load on page 3-43
Applet_LostFocus on page 3-44
Applet_PreInvokeMethod on page 3-46
Application_Close on page 3-91
Application_InvokeMethod on page 3-92
Application_PreInvokeMethod on page 3-94
Application_Start on page 3-96
ControlName_Click on page 3-247
2-82
Version 6.0
Programming
Siebel Object Interface Events and Siebel Extension Events
Table 2-12.
(Sheet 2 of 2)
Method
WebApplet_InvokeMethod on page 3-237
WebApplet_PreInvokeMethod on page 3-238
WebApplet_ShowControl on page 3-239
WebApplet_ShowListColumn on page 3-242
Version 6.0
2-83
Programming
Siebel Object Interface Events and Siebel Extension Events
2-84
Version 6.0
Interfaces Reference
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-23
Version 6.0
3-1
Interfaces Reference
3-2
Version 6.0
Interfaces Reference
Trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-85
TraceOff . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-87
TraceOn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-88
Application Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-91
Application_Close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-91
Application_InvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-92
Application_PreClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-93
Application_PreInvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-94
Application_Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-96
Business Component Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-98
ActivateField . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-98
AllowNotification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-100
Associate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-101
BusObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-103
ClearToQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-104
DeactivateFields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-105
DeleteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-106
ExecuteQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-107
ExecuteQuery2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-110
FirstRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-111
FirstSelected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-112
GetAssocBusComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-113
GetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-115
GetFormattedFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-117
GetLastErrCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-119
GetLastErrText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-120
GetMVGBusComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-121
GetNamedSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-123
GetPicklistBusComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-124
GetSearchExpr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-126
GetSearchSpec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-127
Version 6.0
3-3
Interfaces Reference
GetUserProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-128
GetViewMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-129
InvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-130
LastRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-132
Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-133
NewRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-134
NextRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-136
NextSelected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-137
ParentBusComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-138
Pick . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-139
PreviousRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-141
RefineQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-142
SetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-143
SetFormattedFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-145
SetNamedSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-147
SetSearchExpr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-148
SetSearchSpec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-150
SetSortSpec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-154
SetUserProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-156
SetViewMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-157
SuppressNotification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-159
UndoRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-160
WriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-161
Business Component Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-164
BusComp_Associate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-164
BusComp_ChangeRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-165
BusComp_CopyRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-167
BusComp_DeleteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-168
BusComp_InvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-169
BusComp_NewRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-170
BusComp_PreAssociate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-171
3-4
Version 6.0
Interfaces Reference
BusComp_PreCopyRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-172
BusComp_PreDeleteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-173
BusComp_PreGetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-175
BusComp_PreInvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-176
BusComp_PreNewRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-177
BusComp_PreQuery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-178
BusComp_PreSetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-179
BusComp_PreWriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-181
BusComp_Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-182
BusComp_SetFieldValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-184
BusComp_WriteRecord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-185
Business Object Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-186
GetBusComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-186
GetLastErrCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-187
GetLastErrText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-188
Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-189
Business Service Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-190
GetFirstProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-190
GetNextProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-191
GetProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-192
InvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-193
Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-195
PropertyExists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-196
RemoveProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-197
SetProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3-198
Business Service Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-199
Service_InvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-199
Service_PreInvokeMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-200
Version 6.0
3-5
Interfaces Reference
3-6
Version 6.0
Interfaces Reference
Version 6.0
3-7
Interfaces Reference
Object Interface Methods Tables
Table 3-1 lists the Siebel interface methods, grouped by object interface type.
Table 3-1.
Interface
Method
Applet
ActiveControl
(Sheet 1 of 6)
Siebel
VB
Siebel
eScript
Siebel
COM
Automation
Server
BusComp
BusObject
Drilldown
FindActiveXControl
FindControl
GotoControl
InvokeMethod
Name
PostChanges
Application/
Data Control
ActiveApplet
ActiveBusComp
ActiveBusObject
ActiveControl
ActiveViewName
CurrencyCode
Siebel
COM
Data
Server
GetBusObject
3-8
Siebel
ActiveX
Data
Control
Java
Data
Bean
Siebel
CORBA
Object
Manager
EnableExceptions
FindApplet
Siebel
ActiveX
App.
Control
1
Version 6.0
Interfaces Reference
Object Interface Methods Tables
Table 3-1.
Interface
Method
Application/
Data Control
()
GetLastErrCode
GetLastErrText
GetProfileAttr
GetSharedGlobal
GetService
GotoApplet
GotoView
InputBox
InvokeMethod
(Sheet 2 of 6)
Siebel
VB
Siebel
eScript
Siebel
COM
Automation
Server
LoadObjects
Login
LoginId
LoginName
Siebel
COM
Data
Server
Logoff
MsgBox
NewPropertySet
PositionId
PositionName
SetProfileAttr
SetSharedGlobal
ShowStatus
Trace
TraceOff
TraceOn
Version 6.0
Siebel
ActiveX
App.
Control
Siebel
ActiveX
Data
Control
Java
Data
Bean
Siebel
CORBA
Object
Manager
1
1
1
3-9
Interfaces Reference
Object Interface Methods Tables
Table 3-1.
Interface
Method
Business
Component
ActivateField
AllowNotification
Associate
BusObject
ClearToQuery
DeactivateFields
DeleteRecord
ExecuteQuery
ExecuteQuery2
FirstRecord
FirstSelected
GetAssocBusComp
GetFieldValue
GetFormattedFieldValue
(Sheet 3 of 6)
Siebel
COM
Automation
Server
Siebel
COM
Data
Server
Siebel
ActiveX
App.
Control
Siebel
ActiveX
Data
Control
Java
Data
Bean
1
1
Siebel
VB
Siebel
eScript
GetLastErrCode
GetLastErrText
GetMVGBusComp
GetNamedSearch
GetPicklistBusComp
GetSearchExpr
GetSearchSpec
GetUserProperty
3-10
Siebel
CORBA
Object
Manager
Version 6.0
Interfaces Reference
Object Interface Methods Tables
Table 3-1.
Interface
Method
Business
Component
()
GetViewMode
InvokeMethod
LastRecord
Name
NewRecord
NextRecord
NextSelected
ParentBusComp
Pick
PreviousRecord
RefineQuery
SetFieldValue
SetFormattedFieldValue
SetNamedSearch
SetSearchExpr
SetSearchSpec
SetSortSpec
SetUserProperty
SetViewMode
SuppressNotification
UndoRecord
WriteRecord
Version 6.0
(Sheet 4 of 6)
Siebel
VB
Siebel
eScript
Siebel
COM
Automation
Server
Siebel
COM
Data
Server
Siebel
ActiveX
App.
Control
Siebel
ActiveX
Data
Control
Java
Data
Bean
Siebel
CORBA
Object
Manager
1
1
1
1
3-11
Interfaces Reference
Object Interface Methods Tables
Table 3-1.
Interface
Method
Business
Object
GetBusComp
(Sheet 5 of 6)
Siebel
VB
Siebel
eScript
Siebel
COM
Automation
Server
Siebel
COM
Data
Server
Siebel
ActiveX
App.
Control
Siebel
ActiveX
Data
Control
GetLastErrCode
GetLastErrText
Name
Business
Service
GetFirstProperty
GetNextProperty
GetProperty
InvokeMethod
Name
PropertyExists
RemoveProperty
SetProperty
PropertySet
AddChild
Copy
GetChild
GetChildCount
GetFirstProperty
GetNextProperty
GetProperty
GetType
GetValue
InsertChildAt
3-12
Java
Data
Bean
Siebel
CORBA
Object
Manager
1
1
Version 6.0
Interfaces Reference
Object Interface Methods Tables
Table 3-1.
Interface
Method
PropertySet
()
PropertyExists
RemoveChild
RemoveProperty
Reset
SetProperty
SetType
SetValue
Control
Applet
BusComp
BusObject
GetProperty
GetValue
Name
SetProperty
SetValue
WebApplet
BusComp
BusObject
InvokeMethod
Name
SiebelAppFactory
CreateSiebelAppObject
Miscellaneous
theApplication
ControlName_Click
getErrorCode
getErrorMessage
Version 6.0
(Sheet 6 of 6)
Siebel
VB
Siebel
eScript
Siebel
COM
Automation
Server
Siebel
COM
Data
Server
Siebel
ActiveX
App.
Control
Siebel
ActiveX
Data
Control
Java
Data
Bean
Siebel
CORBA
Object
Manager
Siebel Object Interfaces Reference
3-13
Interfaces Reference
Object Interface Methods Tables
1. Implemented as an attribute. (In CORBA, a method that takes no argument is called an attribute.)
Table 3-2 shows the interfaces and methods supported in the Siebel Thin Clients.
This includes the Windows Thin Client, the Java Thin Client, and the HTML Thin
Client. User interface methods are not relevant on the thin client because they are
processed on either the Windows Object Manager or the UNIX Object Manager,
which have no user interface. However, see Accessing Siebel ActiveX Application
Controls on a Thin Client through JavaScript on page 2-54 for a work-around.
Table 3-2.
(Sheet 1 of 5)
Interface
Method
CurrencyCode
EnableExceptions
GetBusObject
GetLastErrCode
GetLastErrText
GetSharedGlobal
GetService
InvokeMethod
LoadObjects
Login
LoginId
LoginName
Logoff
NewPropertySet
PositionId
PositionName
3-14
Version 6.0
Interfaces Reference
Object Interface Methods Tables
Table 3-2.
(Sheet 2 of 5)
Interface
Method
SetSharedGlobal
Trace
TraceOff
TraceOn
Business Component
ActivateField
AllowNotification
Associate
BusObject
ClearToQuery
DeactivateField
DeleteRecord
ExecuteQuery
ExecuteQuery2
FirstRecord
FirstSelected
GetAssocBusComp
GetFieldValue
GetFormattedFieldValue
GetLastErrCode
GetLastErrText
GetMVGBusComp
GetNamedSearch
GetPickListBusComp
GetSearchExpr
Version 6.0
3-15
Interfaces Reference
Object Interface Methods Tables
Table 3-2.
(Sheet 3 of 5)
Interface
Method
Business Component
(Continued)
GetSearchSpec
GetUserProperty
GetViewMode
InvokeMethod
LastRecord
Name
NewRecord
NextRecord
NextSelected
ParentBusComp
Pick
PreviousRecord
RefineQuery
SetFieldValue
SetFormattedFieldValue
SetNamedSearch
SetSearchExp
SetSearchSpec
SetSortSpec
SetUserProperty
SetViewMode
SuppressNotification
UndoRecord
WriteRecord
3-16
Version 6.0
Interfaces Reference
Object Interface Methods Tables
Table 3-2.
(Sheet 4 of 5)
Interface
Method
Business Object
GetBusComp
GetLastErrCode
GetLastErrText
Name
Business Service
GetFirstProperty
GetNextProperty
GetProperty
InvokeMethod
PropertyExists
RemoveProperty
SetProperty
PropertySet
AddChild
Copy
GetChild
GetChildCount
GetFirstProperty
GetNextProperty
GetProperty
GetType
GetValue
InsertChildAt
PropertyExists
RemoveChild
RemoveProperty
Version 6.0
3-17
Interfaces Reference
Object Interface Methods Tables
Table 3-2.
Interface
Method
PropertySet ()
Reset
(Sheet 5 of 5)
SetProperty
SetType
SetValue
WebApplet
BusComp
BusObject
InvokeMethod
Name
3-18
Version 6.0
Interfaces Reference
Object Interface Events
The object interface events are available only in Siebel VB or Siebel eScript within
Siebel Tools. Table 3-3 lists the Siebel interface events, grouped by object interface
type.
Table 3-3.
(Sheet 1 of 2)
Interface
Event
Applet
ChangeRecord
ChangeFieldValue
ChangeRecord
GotFocus
InvokeMethod
Load
LostFocus
PreInvokeMethod
Application/Data Control
Close
InvokeMethod
PreClose
PreInvokeMethod
Start
Business Component
Associate
ChangeRecord
CopyRecord
DeleteRecord
InvokeMethod
NewRecord
Version 6.0
Siebel VB
Siebel eScript
3-19
Interfaces Reference
Object Interface Events
Table 3-3.
Interface
Event
Business Component
()
PreAssociate
(Sheet 2 of 2)
PreCopyRecord
PreDeleteRecord
PreGetFieldValue
PreInvokeMethod
PreNewRecord
PreQuery
PreSetFieldValue
PreWriteRecord
Query
SetFieldValue
WriteRecord
Service
InvokeMethod
PreInvokeMethod
Web Applet
InvokeMethod
PreInvokeMethod
ShowControl
ShowListColumn
Miscellaneous
3-20
Click
Siebel VB
Siebel eScript
Version 6.0
Interfaces Reference
Object Interface Events
Table 3-4 lists the event handlers supported in the Siebel Thin Clients. For
UNIX-based and Windows-based Client Applications Managers, business
component event handlers are all supported and run on the Client Applications
Manager, as are external DLL files and shell functions. Applet and control event
handlers don't run, because client-side scripting is not supported on the thin clients.
(Web controls are supported in the HTML thin client.) However, you can
simulate events such as a button click using the Method Invoked property and
the BusComp_PreInvokeMethod.
Table 3-4.
(Sheet 1 of 2)
Interface
Event
Application/Data Control
Application_Close
Application_InvokeMethod
Application_PreInvokeMethod
Application_Start
Business Component
BusComp_Associate
BusComp_ChangeRecord
BusComp_CopyRecord
BusComp_DeleteRecord
BusComp_InvokeMethod
BusComp_NewRecord
BusComp_PreAssociate
BusComp_PreDeleteRecord
BusComp_PreGetFieldValue
BusComp_PreInvokeMethod
BusComp_PreNewRecord
BusComp_PreQuery
BusComp_PreSetFieldValue
BusComp_PreWriteRecord
Version 6.0
3-21
Interfaces Reference
Object Interface Events
Table 3-4.
(Sheet 2 of 2)
Interface
Event
Business Component
()
BusComp_Query
BusComp_SetFieldValue
BusComp_WriteRecord
Business Service
Service_InvokeMethod
Service_PreInvokeMethod
Web Applet
WebApplet_InvokeMethod
WebApplet_PreInvokeMethod
WebApplet_ShowControl
WebApplet_ShowListColumn
3-22
Version 6.0
Interfaces Reference
Siebel Constants
Siebel Constants
Version 6.0
Siebel Constants
(Sheet 1 of 2)
Used With
Constant Name
Integer Value
MsgBox Method
mbOKOnly
mbOKCancel
mbAbortRetryIgnore
mbYesNoCancel
mbYesNo
mbRetryCancel
mbCritical
16
mbQuestion
32
mbExclamation
48
mbInformation
64
mbDefaultButton1
000
mbDefaultButton2
256
mbDefaultButton3
512
mbApplicationModal
mbSystemModal
4096
mbOK
mbCancel
3-23
Interfaces Reference
Siebel Constants
Table 3-5.
Siebel Constants
(Sheet 2 of 2)
Used With
Constant Name
Integer Value
MsgBox Method
()
mbAbort
mbRetry
mbIgnore
mbYes
mbNo
ContinueOperation
CancelOperation
OperationComplete1
ForwardBackward
ForwardOnly
NewBefore
NewAfter
NewBeforeCopy
NewAfterCopy
SalesRepView
ManagerView
PersonalView
AllView
NoneSetView
Search Methods
NewRecord Method
SiebelViewMode Methods
3-24
Version 6.0
Interfaces Reference
Applet Methods
Applet Methods
In the following methods, the placeholder oApplet in the syntax refers to a variable
representing a specific applet.
ActiveControl
ActiveControl returns the control that currently has the input focus within the
applet.
Syntax
oApplet.ActiveControl
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
In Siebel VB:
Dim
Dim
set
set
oCtrlObj as Object
oSa as Applet
oSa = theApplication.ActiveApplet()
oCtrlObj = sa.ActiveControl()
In Siebel eScript:
var sa = TheApplication().ActiveApplet();
var ctrlObj = sa.ActiveControl();
Version 6.0
3-25
Interfaces Reference
Applet Methods
BusComp
BusComp returns the business component that is associated with the applet.
oApplet.BusComp
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
This COM example creates a macro that uses the Siebel Automation Server to add
Account records using the data in the Excel spreadsheet cells.
Dim TheApplication As SiebelApplicationServer.SiebelApplication
Dim SiebelBC As SiebelBusComp
Dim SiebelApplet As SiebelApplet
Dim errCode As Integer
On Error GoTo DisplayError
Set TheApplication = GetObject("", _
"SiebelAppServer.ApplicationObject")
With TheApplication
.GotoView "Account List View", Nothing, errCode
On errCode GoTo DisplayError ' will raise VB error if > 255
Set SiebelApplet = .FindApplet("Account List Applet", errCode)
On errCode GoTo DisplayError
.GotoApplet SiebelApplet, errCode
On errCode GoTo DisplayError
End With
Set SiebelBC = SiebelApplet.BusComp(errCode)
On errCode GoTo DisplayError
3-26
Version 6.0
Interfaces Reference
Applet Methods
With SiebelBC
.NewRecord NewAfter, errCode
.SetFieldValue "Name", CStr(ActiveSheet.Cells(8, 1).Value), _
errCode
.WriteRecord errCode
.NewRecord NewAfter, errCode
.SetFieldValue "Name", CStr(ActiveSheet.Cells(9, 1).Value), _
errCode
.WriteRecord errCode
End With
Set SiebelBC = Nothing
Set TheApplication = Nothing
Exit Sub
DisplayError:
Dim ErrText As String
If errCode <> 0 Then
' Siebel error
ErrText = TheApplication.GetLastErrText
MsgBox ErrText
Else
' is Non-Siebel error
MsgBox Err.Description & " VB Error " & Err.Number
End If
Set SiebelBC = Nothing
Set TheApplication = Nothing
Exit Sub
Version 6.0
3-27
Interfaces Reference
Applet Methods
BusObject
BusObject returns the business object for the business component for the applet.
oApplet.BusObject
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
In Siebel VB:
Dim oApplet as Applet
Dim oBusObject as BusObject
Dim oBusComp as BusComp
Set oBusObject = oApplet.oBusObject()
3-28
Version 6.0
Interfaces Reference
Applet Methods
Drilldown
oApplet.Drilldown(drilldown_object)
Argument
Description
drilldown_object
Returns
Not applicable
Usage
A Drilldown object is a child object of applet, used primarily in list applets. It allows
the user to navigate from a cell in a List view to a view that is specific to the cell
the user clicks in. The hyperlinked field and the destination view are defined in the
Drilldown objects properties. Refer to the Siebel Tools Guide for the list of Drilldown
object properties.
NOTE: This functionally can also be implemented through configuring a dynamic
drill-down in Siebel Tools. For details, see the Siebel Tools Guide.
Used With
Version 6.0
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
3-29
Interfaces Reference
Applet Methods
Example
3-30
Version 6.0
Interfaces Reference
Applet Methods
FindActiveXControl
oApplet.FindActiveXControl(controlName)
Argument
Description
controlName
Literal string or string variable containing the name of the desired control
Returns
Used With
Example
In Siebel VB:
Dim oCal as Object
Dim oApplet as Applet
set oCal = oApplet.FindActiveXControl(Calendar1)
oCal.day = 10
oCal.month = 5
Version 6.0
3-31
Interfaces Reference
Applet Methods
FindControl
FindControl returns the control whose name is specified in the argument. This
applet must be part of the displayed view.
oApplet.FindControl(controlName)
Syntax
Argument
Description
controlName
Literal string or string variable containing the name of the desired control
Returns
Usage
FindControl will not find controls for MVG applets, Pick applets, Associate applets,
or detail applets that are not on the views applet list.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
3-32
Version 6.0
Interfaces Reference
Applet Methods
GotoControl
oApplet.GoToControl(controlObject)
Argument
Description
controlObject
A control object
Returns
Not applicable
Usage
The control argument for GotoControl must first be obtained via FindControl or
ActiveControl. For an applet object, the first control in the defined tab order gets
focus. Note that only applets and controls in the current (actively visible) view are
available. Applets called through a toggle are not accessible. For these reasons, this
method cannot be used within an Applet_GotFocus event.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
See Also
Version 6.0
3-33
Interfaces Reference
Applet Methods
InvokeMethod
The InvokeMethod method calls the specialized method specified in its argument.
VB Syntax
oApplet.InvokeMethod(methodName, methodArgs)
Argument
Description
methodName
methodArgs
eScript
Syntax
Argument
Description
methodName
Returns
Usage
InvokeMethod allows you to call methods on an applet object that are not exposed
through the applet interface. You can add an additional argument to the function
call; for example:
Dim Arguments(3) as String
Applet.InvokeMethod (MethodName, Arguments)
You can use InvokeMethod to call the following specialized methods in certain
applets: RunCallScript, ScriptCallFinish, CallScriptCancel. Usage of the these
methods is described in the Siebel SmartScript Guide.
This method should be used only with supported methods.
Used With
3-34
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
Interfaces Reference
Applet Methods
Example
Version 6.0
3-35
Interfaces Reference
Applet Methods
Name
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
3-36
Version 6.0
Interfaces Reference
Applet Methods
PostChanges
oApplet.PostChanges
Argument
Description
Not applicable
Returns
Usage
Use PostChanges to flush any uncommitted input in the active control back to the
BusComp, as occurs when a user tabs out of the field. PostChanges does not commit
the entire row of data to the database, only the user input in one of the active
controls. Call PostChanges to ensure that the users input has been validated (for
example, satisfies a bounded picklist) before performing another operation such as
GetFieldValue. If PostChanges is not called, GetFieldValue returns the original value,
not the value that the user entered.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
3-37
Interfaces Reference
Applet Events
Applet Events
Applet_ChangeFieldValue
Syntax
Parameter
Description
FieldName
FieldValue
Returns
Not applicable
Usage
ChangeFieldValue is fired when the data in a field changes, but not when a user
moves to a different record without changing a value in the previous record. If a
user changes the value in a field and other dependent fields, such as calculated
fields, change as a result, the event is fired once for each field whose value is
changed.
Used With
Example
See Also
3-38
Version 6.0
Interfaces Reference
Applet Events
Applet_ChangeRecord
The ChangeRecord event is called when the user moves to a different row.
Syntax
Applet_ChangeRecord
Parameter
Description
Not applicable
Returns
Not applicable
Used With
Example
See Also
Version 6.0
3-39
Interfaces Reference
Applet Events
Applet_GotFocus
The GotFocus event is called when an applet gets the focus. An applet gets the focus
when one of the following occurs: (1) the user navigates to a view in which the
applet is the default applet, (2) the user clicks on a control in the applet while
another applet is active, (3) a Pick applet, an MVG applet, a detail applet, or an
association dialog, invoked in the applet, is closed.
Applet_GotFocus
Syntax
Argument
Description
Not applicable
The GotFocus event is called any time the focus is moved to the applet from any
other applet, regardless of whether the other applet is another sector applet of the
same view, an applet from a different view, or a dialog box (such as a Pick applet,
an MVG applet, a Detail applet, or an Association dialog box).
Usage
The applet that receives focus in the Applet_GotFocus script does not become the
active applet until the Applet_GotFocus script has finished executing. Therefore,
you cannot call functions that assume the applet is active (such as GoToControl or
GoToApplet) within an Applet_GotFocus script.
NOTE: A static picklist that is auto-generated at run time is considered a control
embedded in the applet on which it resides, and opening it does not change the
focus.
Returns
Not applicable
Used With
3-40
Version 6.0
Interfaces Reference
Applet Events
Example
Version 6.0
3-41
Interfaces Reference
Applet Events
Applet_InvokeMethod
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
See Also
3-42
Version 6.0
Interfaces Reference
Applet Events
Applet_Load
Applet_Load
Parameter
Description
Not applicable
Returns
Not applicable
Usage
You can use this event for purposes such as hiding a few controls on the applet or
defining the business component search specification.
Used With
Version 6.0
3-43
Interfaces Reference
Applet Events
Applet_LostFocus
The LostFocus event is called when an applet loses focus. An applet loses focus
when one of the following occurs: (1) the user navigates to another view, (2) the
user clicks on a control in another applet, (3) a Pick applet, an MVG applet, a Detail
applet, or an Association dialog box is displayed, (4) a user exits the Siebel
application.
Applet_LostFocus
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
The LostFocus event is called any time the focus is moved away from the applet to
any other applet, regardless of whether the other applet is another sector applet of
the same view, an applet from a different view, or a dialog box applet (such as a
Pick applet, an MVG applet, a Detail applet, or an association dialog box).
Applet_LostFocus is triggered as soon as the user clicks a field containing such an
applet.
NOTE: A static picklist that is auto-generated at run time is considered a control
embedded in the applet on which it resides, and opening it does not change
the focus.
Used With
3-44
Version 6.0
Interfaces Reference
Applet Events
Example
Version 6.0
3-45
Interfaces Reference
Applet Events
Applet_PreInvokeMethod
Syntax
Argument
Description
methodName
Returns
ContinueOperation or CancelOperation
Usage
Used With
3-46
Version 6.0
Interfaces Reference
Applet Events
Example
See Also
Version 6.0
3-47
Interfaces Reference
Application Methods
Application Methods
ActiveApplet
ActiveApplet returns the name of the applet that has input focus.
Application.ActiveApplet
Syntax
Argument
Description
Not applicable
Returns
Usage
Use this method to determine which applet currently has focus. The applet typically
has a red border to show that it is active. (This property can be changed through
configuration in Siebel Tools.) An external application can verify the active applet.
Do not use ActiveApplet in any event handler that may be initiated by the COM Data
Server or ActiveX Data Server.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
3-48
Version 6.0
Interfaces Reference
Application Methods
ActiveBusComp
ActiveBusComp returns the business component associated with the active applet.
Syntax
Application.ActiveBusComp
Argument
Description
Not applicable
Returns
Usage
Do not use ActiveBusComp in any event handler that may be initiated by the COM
Data Server or ActiveX Data Server.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
Version 6.0
3-49
Interfaces Reference
Application Methods
ActiveBusObject
ActiveBusObject returns the business object for the business component for the
active applet.
Application.ActiveBusObject
Syntax
Argument
Description
Not applicable
Returns
The business object that contains the business component associated with the
active applet.
Usage
Do not use ActiveBusObject in any event handler that may be initiated by the COM
Data Server or ActiveX Data Server.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
3-50
Version 6.0
Interfaces Reference
Application Methods
ActiveControl
ActiveControl returns the control that has the input focus. Input focus is set when
(1) the end user clicks the control with the mouse or navigates to the control using
the keyboard, or (2) a program navigates to the control via a call to GotoControl.
Syntax
Application.ActiveControl
Argument
Description
Not applicable
Returns
Usage
Do not use ActiveControl in any event handler that may be initiated by the COM
Data Server or ActiveX Data Server.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
3-51
Interfaces Reference
Application Methods
Example
SBusObject = Nothing
SBusComp = Nothing
SApplet = Nothing
SControl = Nothing
3-52
Version 6.0
Interfaces Reference
Application Methods
ActiveViewName
Application.ActiveViewName
Argument
Description
Not applicable
Usage
Do not use ActiveViewName in any event handler that may be initiated by the COM
Data Server or ActiveX Data Server.
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
3-53
Interfaces Reference
Application Methods
CurrencyCode
CurrencyCode returns the operating currency code associated with the division to
which the users position has been assigned.
Application.CurrencyCode
Syntax
Argument
Description
Not applicable
Returns
A string containing the currency code; for example, USD for U.S. dollars, EUR for
the Euro, JPY for the Japanese Yen.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
* Implemented as an attribute.
3-54
Version 6.0
Interfaces Reference
Application Methods
EnableExceptions
ApplicationControl.EnableExceptions(bEnable)
Argument
Description
bEnable
Returns
Not applicable
Usage
Setting the argument to TRUE enables native COM error handling. This allows
applications to intercept and display the exception ID and description. Native COM
error handling is disabled by default.
Used With
Version 6.0
3-55
Interfaces Reference
Application Methods
FindApplet
Syntax
Argument
Description
appletName
Returns
Usage
The only applets available are applets in the active view (including applets
accessible only through a Toggle operation).
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
See Also
3-56
Version 6.0
Interfaces Reference
Application Methods
GetBusObject
GetBusObject method instantiates and returns a new instance of the business object
specified in its argument.
Syntax
Application.GetBusObject(busObjectName)
Argument
Description
busObjectName
Returns
Usage
Set the business object to Nothing to destroy the instantiated business object after
it is no longer needed.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Version 6.0
3-57
Interfaces Reference
Application Methods
GetLastErrCode
Syntax
Argument
Description
Not applicable
Returns
Usage
Used With
Example
See Also
3-58
Version 6.0
Interfaces Reference
Application Methods
GetLastErrText
Application.GetLastErrText
Argument
Description
Not applicable
Returns
Used With
COM Automation Server, COM Data Server, ActiveX Application Control, ActiveX
Data Control, CORBA Object Manager
Example
See Also
Version 6.0
3-59
Interfaces Reference
Application Methods
GetProfileAttr
Syntax
Parameter
Description
name
Returns
Usage
Used With
See Also
Example
This example checks if the Profile Attribute Hobby has been set. If it has not been
set, it asks the user and sets the Profile Attribute to the input value. For an
equivalent example in Siebel eScript, see SetProfileAttr on page 3-83.
Sub Button1_Click
Dim Hobby As String
Hobby = TheApplication.GetProfileAttr("Hobby")
If Hobby = "" Then
Hobby = InputBox("Please enter your favorite hobby")
theApplication.SetProfileAttr "Hobby", Hobby
End If
End Sub
3-60
Version 6.0
Interfaces Reference
Application Methods
GetService
The GetService method returns a specified service. If the service is not already
running, it will be constructed.
Syntax
Application.GetService(serviceName)
Parameter
Description
serviceName
Returns
Not applicable
Usage
This method finds the business service indicated by serviceName; it constructs the
service if it is not already running. It first searches through the built-in services that
are stored in the repository. If the service is not found, GetService searches through
services defined in the run-time Business Services table.
A business service is normally deleted from memory as soon as all references to it,
such as local or global variables, are cleared by setting them to another value.
However, if the Cache flag on the business service is set, the service remains in
memory as long as the Siebel application is running.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Version 6.0
3-61
Interfaces Reference
Application Methods
GetSharedGlobal
Syntax
Returns
Usage
Argument
Description
varName
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA Object
Manager*
Example
See Also
3-62
Version 6.0
Interfaces Reference
Application Methods
GotoApplet
Application.GotoApplet(AppletObject)
Argument
Description
AppletObject
Returns
Not applicable
Usage
The first control in the defined tab order gets focus. Note that only applets actively
visible on the current view are available. Applets called through a toggle are not
accessible, nor are pop-up applets such as pick applets, MVG applets, detail applets,
or association applets.
NOTE: This method cannot be used within an Applet_GotFocus event.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
See Also
Example
Version 6.0
3-63
Interfaces Reference
Application Methods
GotoView
GotoView activates the named view and its BusObject. As a side effect, this method
activates the views primary applet and its BusComp and activates the primary
applets first tab sequence control. Further, this method deactivates any BusObject,
BusComp, applet, or control objects that were active prior to this method call.
Application.GotoView(ViewName[, BusinessObjectName])
Syntax
Argument
Description
ViewName
BusinessObjectName
Returns
Not applicable
Usage
If a business object has not been instantiated, BusinessObjectName should have the
value Nothing.
An example use of the GotoView method is to programmatically navigate to the
Opportunity List view.
theApplication.GotoView "Opportunity List View", Nothing
When this method is used from an external program (a COM Automation Server),
the usage is as follows:
ObjectReference.GotoView("Opportunity List View", Nothing,
errCode)
Alternatively, if your application has already instantiated an Opportunity object
with the object reference of objOppty, the appropriate usage in Siebel VB is:
theApplication.GotoView("Opportunity List View", objOppty)
3-64
Version 6.0
Interfaces Reference
Application Methods
When this method is used from an external program (a COM Automation Server),
the usage is as follows:
ObjectReference.GotoView("Opportunity List View",
OpptyObj, errCode)
NOTE: When this method is used in a Siebel VB or eScript script, regardless of where
it appears in the script, it is executed last. However, when GoToView is invoked
from an external program, it is executed immediately. The GoToView method goes
to a new screen, with the result that the screen in which the method is executing is
destroyed, and the executing script along with it, causing a crash. To avoid this
behavior, make the call to GoToView the last executable statement in the script.
This method cannot be used in an Applet_GotFocus event.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
Version 6.0
3-65
Interfaces Reference
Application Methods
InputBox
The InputBox method prompts the user for input and is similar to the Microsoft
Visual Basic InputBox method. For compatibility with Siebel VB, InputBox can also
be accessed as a global method.
VB Syntax
eScript
Syntax
Description
variableName
Application
prompt
title
default
xpos
ypos
Returns
A string containing the user input or, if the user typed no input, the default
input value.
Used With
3-66
Version 6.0
Interfaces Reference
Application Methods
Example
Version 6.0
3-67
Interfaces Reference
Application Methods
InvokeMethod
Application.InvokeMethod(methodName, methodArgs)
Argument
Description
methodName
methodArgs
eScript
Syntax
Argument
Description
methodName
Returns
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
3-68
Version 6.0
Interfaces Reference
Application Methods
LoadObjects
The LoadObjects method is used to start the COM Data Server object, and returns
a reference to the Application object. This method must be the first call to the COM
Data Server.
Syntax
Application.LoadObjects(pathName\CFGfileName)
Argument
Description
pathName
CFGfileName
Returns
Usage
Prior to calling LoadObjects, you must change the current directory to the
Siebel\bin directory.
Used With
Example
Version 6.0
3-69
Interfaces Reference
Application Methods
Login
The Login method allows external applications to log in to the COM Data Server,
ActiveX Control, Java Data Bean, or CORBA Object Manager and access the Siebel
objects. The Login method allows the end user to invoke the Siebel application
without being prompted for a login and password. The Login method determines
the privileges that will be granted, and the role and responsibility of the end user
for that session.
Application.Login([connectString,] userName, password)
Syntax
Returns
Argument
Description
connectString*
userName
password
Usage
Verify that the Siebel\bin directory is the current directory. To access the Data
Control, make sure the default Data Source points to the database that you wish to
access and set EnableOLEAutomation to TRUE in your .cfg file (this is the default
value for the parameter). To access the CORBA Object Manager, EnableCORBA must
be set to TRUE.
Used With
COM Data Server, ActiveX Automation Control, ActiveX Data Control, Java Data
Bean, CORBA Object Manager
Example
The Connect string for the ActiveX controls is token-based; for example:
host = "siebel//:my_computer/SIEBEL/objsrvr/my_computer" lang =
"ENU"
3-70
Version 6.0
Interfaces Reference
Application Methods
Since most languages use quotes to enclose text strings, you must use quotes inside
quotes; for example:
To use the ActiveX controls in Visual Basic:
Login("host=""siebel//my_computer/SIEBEL/objsvr/my_computer"_
"lang=""ENU"", "user", "password")
The following code sample illustrates how to log in to the server and check
for errors.
Call SiebelAppControl.Login("host=""siebel//:SOMQA/somsiebel/
ssu""", "", "")
//Check for errors
If SiebelAppControl.GetLastErrCode <> 0 Then
frmMain.txtStatus.Text = SiebelAppControl.GetLasErrText
Else
frmMain.txtStatus.Text = "Connected successfully..."
End If
Version 6.0
3-71
Interfaces Reference
Application Methods
LoginId
The LoginId method returns the login ID of the user who started the Siebel
application.
Application.LoginId
Syntax
Argument
Description
Not applicable
Returns
Usage
The login ID is the row ID of the users login in the Employee table. Once obtained,
the login ID can be conveniently used as a search specification.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
3-72
Version 6.0
Interfaces Reference
Application Methods
LoginName
The LoginName method returns the login name of the user who started the Siebel
application (the name typed in the login dialog box).
Syntax
Application.LoginName
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
For examples, see ExecuteQuery on page 3-107 and theApplication on page 3-249.
See Also
Version 6.0
3-73
Interfaces Reference
Application Methods
Logoff
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
For clients with user interfaces, Logoff destroys all windows except for the topmost
window. Logoff also deletes all objects, except for the topmost object, on both client
and server. Logoff is usually used to disconnect from the server and then reconnect
as a different user.
Logoff is called automatically if you destroy the main object.
Used With
3-74
ActiveX Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager
Version 6.0
Interfaces Reference
Application Methods
MsgBox
The MsgBox method displays a message box and is similar to the Microsoft Visual
Basic MsgBox method. For compatibility with Microsoft Visual Basic, MsgBox can
also be accessed as a global method in Siebel VB.
VB Syntax
eScript
Syntax
Description
prompt
buttons
An integer that represents the button type, the displayed icon, the default
button, and the modality. The integer is the sum of type + icon + default
button + modality. Choose the values from Table 3-6.
title
Table 3-6.
Button Type
Icon
Version 6.0
MsgBox Constants
(Sheet 1 of 2)
Constant Name
Integer Value
Meaning
mbOKOnly
OK button
mbOKCancel
mbAbortRetryIgnore
mbYesNoCancel
mbYesNo
Yes, No buttons
mbRetryCancel
mbCritical
16
Critical STOP
mbQuestion
32
Question (?)
mbExclamation
48
Warning (!)
mbInformation
64
Info (i)
3-75
Interfaces Reference
Application Methods
Table 3-6.
MsgBox Constants
Default Button
Modality
Returns
(Sheet 2 of 2)
Constant Name
Integer Value
Meaning
mbDefaultButton1
000
mbDefaultButton2
256
mbDefaultButton3
512
mbApplicationModal
mbSystemModal
4096
An integer value representing the user response. (MsgBox can also be called
without assigning its return value to a variable.)
Return Value
Constant Name
Button Chosen
mbOK
OK
mbCancel
Cancel
mbAbort
Abort
mbRetry
Retry
mbIgnore
Ignore
mbYes
Yes
mbNo
No
Usage
In each group of constants for the buttons argument, the one with the value of
zero (0) is the default. If the buttons argument is omitted, a single OK button
is displayed; however, if the title argument is used, a buttons argument must also
be used.
Used With
3-76
Version 6.0
Interfaces Reference
Application Methods
Example
Version 6.0
3-77
Interfaces Reference
Application Methods
NewPropertySet
Syntax
Parameter
Description
Not applicable
Returns
A property set
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
3-78
Version 6.0
Interfaces Reference
Application Methods
PositionId
The PositionId property returns the position ID (ROW_ID from S_POSTN) of the
users current position. This is set by default when the Siebel application is started
and may be changed (via Edit Change Position) if the user belongs to more than
one position.
Syntax
Application.PositionId
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
* Implemented as an attribute.
Version 6.0
3-79
Interfaces Reference
Application Methods
PositionName
The PositionName property returns the position name of the users current position.
This is set by default when the Siebel application is started and may be changed
(via Edit Change Position) if the user belongs to more than one position.
Application.PositionName
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
* Implemented as an attribute.
3-80
Version 6.0
Interfaces Reference
Application Methods
Example
This Siebel VB example checks for the position of a user changing the sales stage,
and prevents changes if the user is not of the appropriate position to do so.
Function BusComp_PreSetFieldValue (FieldName As String, FieldValue
As String) As Integer
Dim sPosName As String sMsgText As String
Dim iReturn As Integer
iReturn = ContinueOperation
Select Case FieldName
Case "Sales Stage"
If FieldValue = "Approved" Then
' Do not allow the sales cycle to be changed to
' this value if the User is not a manager or VP.
sPosName = TheApplication.PositionName
If ((PosName like "*Manager*") or (PosName like "*VP*"))Then
MsgBox("Pipeline Item Approved")
Else
sMsgText = "Only a Manager or Vice President can approve _
a Pipeline Item. Please notify your Manager that you _
want to have this Pipeline item approved."
MsgBox sMsgText
iReturn = CancelOperation
End If
BusComp_PreSetFieldValue = iReturn
End Select
End Function
Version 6.0
3-81
Interfaces Reference
Application Methods
SetSharedGlobal
Syntax
Argument
Description
varName
String variable or literal containing the name of the shared global variable to
set
value
String variable or literal containing the value to set the variable to set
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA
Object Manager*
Example
In Siebel VB:
theApplication.SetSharedGlobal "myVar", "FOO"
myVar2 = theApplication.GetSharedGlobal("myVar")
In COM:
comVar = SiebelApplication.GetSharedGlobal("myVar", errCode)
SiebelApplication.SetSharedGlobal "myVar", "BLAH", errCode
See Also
3-82
Version 6.0
Interfaces Reference
Application Methods
SetProfileAttr
Description
name
value
Returns
Not applicable
Usage
SetProfileAttr assigns the value value to the attribute in a user profile indicated by
name.
Used With
See Also
Example
This Siebel eScript example checks if the Profile Attribute Hobby has been set. If it
has not been set, it asks the user and sets the Profile Attribute to the input value.
For an equivalent Siebel VB example, see GetProfileAttr on page 3-60.
function Button1_Click ()
{
var Hobby = TheApplication.GetProfileAttr("Hobby");
if( Hobby == "")
{
Hobby = TheApplication().InputBox(
"Please enter your favorite hobby");
TheApplication().SetProfileAttr("Hobby", Hobby);
}
}
Version 6.0
3-83
Interfaces Reference
Application Methods
ShowStatus
ShowStatus displays a message string in the status bar at the bottom of the window.
Application.ShowStatus(message)
Syntax
Argument
Description
message
String variable or literal containing the text to display in the status bar
Returns
Not applicable
Usage
This method is useful for errors that do not require a pop-up dialog box, and for
context messages during navigation. If the message is omitted or empty, the status
display is cleared.
NOTE: The status bar is a shared area, and the application itself may overwrite your
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
3-84
Version 6.0
Interfaces Reference
Application Methods
Trace
The Trace method appends a message to the trace file. Trace is useful for debugging
SQL query execution.
Syntax
Application.Trace(message)
Argument
Description
message
String variable or literal containing message text to append to the trace file
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, Siebel ActiveX
Application Control, Siebel ActiveX Data Control, CORBA Object Manager
Example
Version 6.0
3-85
Interfaces Reference
Application Methods
See Also
3-86
Version 6.0
Interfaces Reference
Application Methods
TraceOff
Application.TraceOff
Argument
Description
Not applicable
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA Object
Manager
Example
This Siebel VB example set the value in the Sales Stage field to the default, that is,
to the first value in the fields picklist, and uses tracing to track the result.
Sub BusComp_NewRecord
TheApplication.TraceOn "C:\lvpick.doc", "SQL", ""
Dim oBC as BusComp
set oBC = me.GetPickListBusComp("Sales Stage")
With oBC
.SetViewMode AllView
.ClearToQuery
.ActivateField "Sales Stage Order"
.SetSortSpec "Sales Stage Order"
.ExecuteQuery ForwardOnly
if .FirstRecord then
.Pick
end if
End With
set oBC = Nothing
TheApplication.TraceOff
End Sub
Version 6.0
3-87
Interfaces Reference
Application Methods
TraceOn
Syntax
Argument
Description
filename
type
Specifies the type of tracing to start. This can have the following values:
Indicates which Siebel objects should be traced for the Allocation trace type.
This argument should be "" if the trace type is SQL.
Returns
Not applicable
Usage
Always remember to issue TraceOff to turn off tracing. If you attempt to call TraceOn
with a different filename without calling TraceOff first, all trace information will be
written to the new trace filename. You can issue multiple TraceOn statements to the
same trace file.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA Object
Manager
3-88
Version 6.0
Interfaces Reference
Application Methods
Example
Version 6.0
3-89
Interfaces Reference
Application Methods
See Also
3-90
Version 6.0
Interfaces Reference
Application Events
Application Events
Application_Close
The Close event is called before the application exits. This allows Basic scripts to
perform last-minute cleanup (such as cleaning up a connection to a COM server).
It is called when the application is notified by Windows that it should close, but not
if the process is terminated directly.
Syntax
Application_Close
Argument
Description
Not applicable
Returns
Not applicable
Used With
Version 6.0
3-91
Interfaces Reference
Application Events
Application_InvokeMethod
Syntax
Argument
Description
methodName
The InvokeMethod event is called just after a specialized method is invoked on the
application.
Usage
If you are implementing a new method (not defined by the built-in functions), the
script should return CancelOperation to avoid invoking an Unknown Method
Name error.
Returns
Not applicable
Used With
See Also
3-92
Version 6.0
Interfaces Reference
Application Events
Application_PreClose
The PreClose event is called when the user exits the application.
Syntax
Application_PreClose
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
Used With
Version 6.0
3-93
Interfaces Reference
Application Events
Application_PreInvokeMethod
Syntax
Argument
Description
methodName
Returns
CancelOperation or ContinueOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
3-94
Version 6.0
Interfaces Reference
Application Events
Example
Here is the equivalent sample in Siebel eScript. Note that for this script to run, the
entire Clib.system statement must appear on a single line in the Editor.
function Application_PreInvokeMethod (MethodName)
var iReturn = ContinueOperation;
switch (MethodName)
{
case "LaunchWord":
Clib.system(""C:\\Program Files\\Microsoft Office
\\Office\\WINWORD.EXE,"" 1");
iReturn = CancelOperation;
break;
case "LaunchExcel":
Clib.system("C:\\Program Files\\Microsoft Office
\\Office\\EXCEL.EXE",1)
iReturn = CancelOperation;
}
return (iReturn)
}
See Also
Version 6.0
3-95
Interfaces Reference
Application Events
Application_Start
The Start event is called when the client starts and the user interface is first
displayed.
Application_Start(commandline)
Syntax
Argument
Description
commandline
Text of the command line with which the Siebel application was started
Returns
Not applicable
Used With
3-96
Version 6.0
Interfaces Reference
Application Events
Example
This Siebel VB code should be placed in the Application_Start procedure for the
application of your choice. This example displays the first and last name of the user
logging into the Siebel application in a message box.
Sub Application_Start(CommandLine As String)
Dim oEmpBusComp as BusComp
Dim sLoginName as String
Dim sUserName as String
sLoginName = TheApplication.LoginName
Set oEmpBusComp = oEmpBusObj.GetBusComp("Employee")
With oEmpBusComp
.ActivateField("Login Name")
.ActivateField("First Name")
.ActivateField("Last Name")
.ClearToQuery
.SetSearchSpec "Login Name", sLoginName
.ExecuteQuery
If .FirstRecord Then
sUserName = .GetFieldValue("First Name")
sUserName = sUserName + " " + _
.GetFieldValue("Last Name")
TheApplication.MsgBox "Hi there, " + SUserName + "!"
Else
MsgBox("Record not found")
End If
End With
Set oEmpBusComp = Nothing
Set oEmpBusObj = Nothing
End Sub
Version 6.0
3-97
Interfaces Reference
Business Component Methods
ActivateField
Syntax
Argument
Description
FieldName
Returns
Not applicable
Usage
FieldName must be enclosed in double quotes and must be spelled exactly as the
field name appears in Siebel Tools, using the same case. You must activate fields
using ActivateField prior to executing a query for the business component.
By default, all fields are inactive except when:
They are displayed on the applet and the business component is the instance on
which the applet is based
They are System fields (which include Id, Created, Created By, Updated, and
Updated By)
3-98
Version 6.0
Interfaces Reference
Business Component Methods
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
Version 6.0
3-99
Interfaces Reference
Business Component Methods
AllowNotification
The AllowNotification method enables update of the user interface when there are
changes to the business component. User interface updates are enabled until a
matching call to SuppressNotification.
BusComp.AllowNotification
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control,
ActiveX Data Control, Java Data Bean
See Also
3-100
Version 6.0
Interfaces Reference
Business Component Methods
Associate
The Associate method creates a new many-to-many relationship for the parent
object through an association business component (see GetAssocBusComp).
Syntax
BusComp.Associate(whereIndicator)
Argument
Description
whereIndicator
Returns
Not applicable
Usage
To set field values on a child record that has been associated to a parent record,
use the context of the MVGBusComp.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
Version 6.0
3-101
Interfaces Reference
Business Component Methods
Example
The following VB example adds the position CEO to the current record of the parent
business component, and updates the Opportunity Assignment Type field. The
parent business component can be any business component that includes the Sales
Rep multi-value group.
Dim oParentBC as BusComp
Dim oMvgBC as BusComp
Dim oAssocBC as BusComp
Set oParentBC = me.BusComp
Set oMvgBC = OpBC.GetMVGBusComp("Sales Rep")
Set oAssocBC = oMvgBC.GetAssocBusComp
With oAssocBC
.SetSearchSpec "Id", newPosId
.ExecuteQuery
.Associate NewAfter
End With
oMvgBC.SetFieldValue "Opportunity Assignment Type", NewType
Set oAssocBC = Nothing
Set oMvgBC = Nothing
Set oParentBC = Nothing
3-102
Version 6.0
Interfaces Reference
Business Component Methods
BusObject
The BusObject method returns the business object that contains the business
component.
Syntax
BusComp.BusObject
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
See Also
Version 6.0
3-103
Interfaces Reference
Business Component Methods
ClearToQuery
The ClearToQuery method clears the current query and sort specifications on
the BusComp.
BusComp.ClearToQuery
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
3-104
Version 6.0
Interfaces Reference
Business Component Methods
DeactivateFields
DeactivateFields deactivates all the fields that are currently active from a business
component SQL query statement.
Syntax
BusComp.DeactivateFields
Argument
Description
Not applicable
Returns
Not applicable
Usage
You must activate fields using ActivateField prior to executing a query for the
business component.
By default, all fields are inactive except when:
They are displayed on the applet and the business component is the instance on
which the applet is based
They are System fields (which include Id, Created, Created By, Updated, and
Updated By)
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
Version 6.0
3-105
Interfaces Reference
Business Component Methods
DeleteRecord
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
This Siebel VB example illustrates how to delete all accounts with a status
of "Inactive".
Sub DeleteInactiveAccounts()
Dim objBO as BusObject
Dim objBC as BusComp
Set objBO = theApplication.GetBusObject("Account")
Set objBC = objBO.GetBusComp("Account")
With objBC
.ClearToQuery
.SetSearchSpec "Status", "Inactive"
.ExecuteQuery ForwardBackward
Do While .FirstRecord
.DeleteRecord
Loop
End With
Set objBC = Nothing
Set objBO = Nothing
End Sub
3-106
Version 6.0
Interfaces Reference
Business Component Methods
ExecuteQuery
ExecuteQuery returns a set of BusComp records using the criteria established with
methods such as SetSearchSpec.
Syntax
Description
cursorMode
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
3-107
Interfaces Reference
Business Component Methods
Example
This Siebel VB example sets up and executes a query to find the primary on the
account team. Only the primary can change the primary address. For other
examples, see Applet_PreInvokeMethod on page 3-46, GotoView on page 3-64, and
ClearToQuery on page 3-104.
(general) (declarations)
Option Explicit
Function BusComp_PreSetFieldValue (FieldName As String,
FieldValue As String) As Integer
Dim iReturn As Integer, i As Integer
Dim iFoundP As Integer ' 1 = found (TRUE), 0 = not found (FALSE)
Dim oMVGBC as BusComp
iReturn = ContinueOperation
iFoundP = FALSE
Select Case FieldName
Case "SSA Primary Field"
set oMVGBC = me.ParentBusComp.GetMVGBusComp("Sales Rep")
With oMVGBC ' this is the position BC
.ClearToQuery
.ActivateField "Active Login Name"
.ExecuteQuery ForwardBackward
i = .FirstRecord
Do While i <> 0
if .GetFieldValue("SSA Primary Field") = "Y" then
iFoundP = TRUE 'mark that found a primary
if.GetFieldValue("Active Login Name") <> _
TheApplication.LoginName then
MsgBox("You cannot change the Primary address " & _
"since you are not the Primary on the Account Team")
iReturn = CancelOperation
end if
Exit Do
else
i = .NextRecord
end if
Loop
if iFoundP = FALSE then
.FirstRecord
MsgBox("No Primary Found - Contact an Administrator")
end if
End With
End Select
3-108
Version 6.0
Interfaces Reference
Business Component Methods
Otherwise return a 0.
if (pBusComp->FirstRecord())
{
id = pBusComp->GetFieldValue("Id");
return 1;
}
else
{
return 0;
}
}
See Also
Version 6.0
3-109
Interfaces Reference
Business Component Methods
ExecuteQuery2
ExecuteQuery2 returns a set of BusComp records using the criteria established with
methods such as SetSearchSpec.
BusComp.ExecuteQuery2 (cursorMode, ignoreMaxCursorSize)
Syntax
Argument
Description
cursorMode
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-110
Version 6.0
Interfaces Reference
Business Component Methods
FirstRecord
FirstRecord moves the record pointer to the first record in a business component,
making that record current and invoking any associated script events.
Syntax
BusComp.FirstRecord
Argument
Description
Not applicable
Returns
An integer in Siebel VB: 1 or non-zero if there was a first record (the query returned
results) and 0 if there are no records; a Boolean in Siebel eScript, COM, ActiveX,
and CORBA.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Here is a Siebel VB example. For the equivalent eScript example, see NextRecord on
page 3-136.
Function BusComp_PreQuery () As Integer
Dim I As Integer
Dim isRecord As Integer
I = 0
With me
.ClearToQuery
.SetSearchSpec "Name", "*"
.ExecuteQuery ForwardBackward
isRecord = .FirstRecord
Do While isRecord
I = I + 1
isRecord = .NextRecord
Loop
End With
MsgBox I & " records."
BusComp_PreQuery = ContinueOperation
End Function
See Also
Version 6.0
3-111
Interfaces Reference
Business Component Methods
FirstSelected
FirstSelected moves the focus to the first record of the multiple selection in the
business component, invoking any associated Basic events.
BusComp.FirstSelected
Syntax
Argument
Description
Not applicable
Returns
An integer in Siebel VB: 1 or non-zero if there was a first record (the query returned
results) and 0 if there are no records; a Boolean in Siebel eScript, COM, ActiveX,
and CORBA.
Used With
Example
This Siebel VB example calls the email client upon the click of a button. It uses a
function, Email, that is not shown.
Sub Button1_Click
Dim oAccounts as BusComp
Dim oCurrAcct As BusComp, sName as String
Dim sSendList As String, sDescription as String
'Get the current business object
Set oCurrAcct = TheApplication.ActiveBusComp
With oCurrAcct
If .FirstSelected <> 0 then
sName = .GetFieldValue("Email Address")
Set oAccounts = oCurrAcct
If .FirstSelected <> 0 then
sSendList = .GetFieldValue("Email Address")
do while .NextSelected <> 0
sDescription = .GetFieldValue("Email Address")
sSendList = sSendList + ";" + sDescription
MsgBox(SDescription)
loop
end if
end if
End With
CallEmail(sSendList)
End Sub
3-112
Version 6.0
Interfaces Reference
Business Component Methods
GetAssocBusComp
BusComp.GetAssocBusComp
Argument
Description
Not applicable
Returns
Usage
This method and the Associate method make sense only for many-to-many
relationships, which are based on intersection tables, for example Account and
Industry. In the context of a many-to-many relationship, you can use Siebel VB to
either Add a new record, that is, associate a new child record, or Insert a record,
that is, create a brand-new record in the child business component. To Add a record,
use GetAssocBusComp and the Associate method. To Insert a record, use
GetMVGBusComp and the NewRecord method. The GetAssocBusComp should
be set to Nothing after use.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
3-113
Interfaces Reference
Business Component Methods
Example
The following Siebel VB sample code using GetAssocBusComp adds a new industry
to an account record:
Dim oAssocBC As BusComp
Set oAssocBC = oMainBc.GetMVGBusComp("Industry").GetAssocBusComp
With oAssocBC
.ActivateField "SIC Code"
.SetSearchExpr "[SIC Code] = ""5734"" "
.ExecuteQuery ForwardOnly
If .FirstRecord Then .Associate NewBefore
End With
Set oAssocBC = Nothing
See Also
3-114
Version 6.0
Interfaces Reference
Business Component Methods
GetFieldValue
GetFieldValue returns the value for the field specified in its argument for the current
record of the business component. Use this method to access a field value.
Syntax
BusComp.GetFieldValue(FieldName)
Argument
Description
FieldName
Returns
A string containing the field value of the field identified in FieldName, or an empty
string ("") if the field is inactive or empty.
Usage
Only fields that were active at the time of the BusComp query will contain values.
See ActivateField on page 3-98 for more details. If this method is used on fields that
are not active, or on fields that are empty, an empty string ("") will be returned.
Caution: If a value from a business component that is a child of the
current business component is desired, the Link Specification
property for that field must be set to TRUE in Siebel Tools.
Otherwise, the parent business component cannot access the value
in the child business component. For further information, see the
Siebel Object Types Reference.
The FieldName must be enclosed in double quotes and must be spelled exactly as
the field name appears in Siebel Tools, with the correct case; for example,
GetFieldValue("ActivityCreatedByName")
The name "Person who created the activity", as shown in the status bar,
will not work; nor will the column head "Created By".
Used With
Version 6.0
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-115
Interfaces Reference
Business Component Methods
Example
See Also
3-116
Version 6.0
Interfaces Reference
Business Component Methods
GetFormattedFieldValue
GetFormattedFieldValue returns the field value in the current local format; it returns
values in the same format as the Siebel UI.
Syntax
BusComp.GetFormattedFieldValue(FieldName)
Argument
Description
FieldName
String variable or literal containing the name of the field to obtain the value
from
Returns
A string containing the value of the requested field, in the same format as displayed
in the user interface, or an empty string ("") if the field is inactive or empty.
Usage
Version 6.0
3-117
Interfaces Reference
Business Component Methods
DTYPE_DATE. When used on fields of DTYPE_DATE, these methods are the same as
GetFieldValue/SetFieldValue, except that the result is in the format of the Regional
Setting.
Dates:
Times:
Date-times:
mm/dd/yyyy
hh:nn:ss
mm/dd/yyyy hh:nn:ss
If you attempt to use SetFieldValue and your Regional Setting format is different,
you will receive an error like this:
Error: The value '31-Dec-99' can not be converted to a date
time value.
This error can be avoided by using the GetFormattedFieldValue and
SetFormattedFieldValue methods.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
3-118
Version 6.0
Interfaces Reference
Business Component Methods
GetLastErrCode
BusComp.GetLastErrCode
Argument
Description
Not applicable
Returns
Usage
Used With
See Also
Version 6.0
3-119
Interfaces Reference
Business Component Methods
GetLastErrText
Syntax
Argument
Description
Not applicable
Returns
Usage
Used With
See Also
3-120
Version 6.0
Interfaces Reference
Business Component Methods
GetMVGBusComp
BusComp.GetMVGBusComp(FieldName)
Argument
Description
FieldName
Name of the field with a Multi-Value Group attached, used to obtain the
Multi-Value Group business component
Returns
The multi-value group business component of the current business component and
identified field.
Usage
A Multi-Value Group is a set of detail records attached to the current record in the
business component that holds the corresponding multi-value field.
The GetMVGBusComp should be set to Nothing after use.
NOTE: In the context of a many-to-many relationship, you can use Siebel VB to
either add a new record, that is, associate a new child record, or insert a record, that
is, create a brand-new record in the child business component. To add a record, use
GetAssocBusComp and the Associate method. To insert a record, use
GetMVGBusComp and the NewRecord method.
Used With
Version 6.0
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-121
Interfaces Reference
Business Component Methods
Example
The following sample code using GetMVGBusComp adds a new address to the
Hong Kong Flower Shop account record. For other examples, see ExecuteQuery
on page 3-107 and GetAssocBusComp on page 3-113.
Dim
Dim
Dim
Set
Set
AccntBO as BusObject
AccntBC as BusComp
AddrBC as BusComp
AccntBO = theApplication.GetBusObject("Account")
AccntBC = AccntBO.GetBusComp("Account")
With AccntBC
.SetViewMode SalesRepView
.ActivateField "Name"
.ClearToQuery
.SetSearchSpec "Name", "Hong Kong Flower Shop"
.ExecuteQuery
Set AddrBC = .GetMVGBusComp("Street Address")
End With
With AddrBC
.NewRecord NewAfter
.SetFieldValue "City", "Denver"
.WriteRecord
End With
Set AccntBO = Nothing
Set AccntBC = Nothing
Set AddrBC = Nothing
See Also
3-122
Version 6.0
Interfaces Reference
Business Component Methods
GetNamedSearch
BusComp.GetNamedSearch(searchName)
Argument
Description
searchName
Returns
Usage
The search specification uses the same syntax as that used in predefined queries.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
Version 6.0
3-123
Interfaces Reference
Business Component Methods
GetPicklistBusComp
Syntax
Argument
Description
FieldName
Name of the field with a picklist specified; used to obtain the pick business
component
Returns
Usage
The returned pick business component can be used to operate on the picklist. The
GetPickListBusComp should be destroyed after use by using the Nothing function.
3-124
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Business Component Methods
Example
See Also
Version 6.0
3-125
Interfaces Reference
Business Component Methods
GetSearchExpr
GetSearchExpr returns the current search expression for the business component.
BusComp.GetSearchExpr
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
3-126
Version 6.0
Interfaces Reference
Business Component Methods
GetSearchSpec
GetSearchSpec returns the search specification for the field specified by the
FieldName argument.
Syntax
BusComp.GetSearchSpec(FieldName)
Argument
Description
FieldName
Contains the name of the field from which to obtain the associated search
specification
Returns
A string containing the search specification for the field identified in FieldName. An
example of a returned search specification string is "> 10000".
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
Version 6.0
3-127
Interfaces Reference
Business Component Methods
GetUserProperty
Syntax
Argument
Description
propertyName
Returns
Usage
The value of a user property is set using SetUserProperty. The user properties act
like instance variables of a business component. The advantage of user properties
is that they can be accessed from anywhere in the code (even from other
applications via COM) using GetUserProperty. An instance variable, on the other
hand, can be accessed only from within Siebel VB from the same object on which
the variable is declared.
The value of the property is reset every time you instantiate a new business
component.
Used With
Example
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA
Object Manager
Sub BusComp_SetFieldValue (FieldName As String)
Dim msgText as String
msgText = me.GetUserProperty("Pecuniary Orientation")
MsgBox value
End Sub
See Also
3-128
Version 6.0
Interfaces Reference
Business Component Methods
GetViewMode
GetViewMode returns the current visibility mode for the business component. This
affects which records are returned by queries according to the visibility rules. See
SetViewMode on page 3-157 for more information.
Syntax
BusComp.GetViewMode
Argument
Description
Not applicable
Returns
SalesRepView
ManagerView
PersonalView
AllView
NoneSetView
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
* Implemented as an attribute.
See Also
Version 6.0
3-129
Interfaces Reference
Business Component Methods
InvokeMethod
Description
methodName
methodArgs
eScript
Syntax
Argument
Description
methodName
Returns
Usage
InvokeMethod enables you to call methods on a business component object that are
not exposed directly through the object interface.
Specialized methods are typically methods implemented in applet or business
component classes other than CSSFrame and CSSBusComp, respectively, that is,
specialized classes.
You can use InvokeMethod to call only the following specialized methods in certain
business components: CreateFile, GetFile, PutFile. Usage of these methods is
described in Siebel Technical Note #198.
Used With
3-130
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Business Component Methods
Example
Version 6.0
3-131
Interfaces Reference
Business Component Methods
LastRecord
Syntax
Argument
Description
Not applicable
Returns
An integer in Siebel VB; a Boolean in Siebel eScript, COM, ActiveX, and CORBA: 1
or non-zero if there was a last record (the query returned results) and 0 if there are
no records.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
3-132
Version 6.0
Interfaces Reference
Business Component Methods
Name
oBusComp.Name
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
Version 6.0
3-133
Interfaces Reference
Business Component Methods
NewRecord
Syntax
Argument
Description
whereIndicator
0 (or NewBefore)
1 (or NewAfter)
2 (or NewBeforeCopy)
3 (or NewAfterCopy)
Returns
Not applicable
Usage
This new row becomes the current row. The constants are provided in all available
environments.
You can use NewRecord to copy a record. To do so, use
Object.NewRecord NewBeforeCopy
to place the copy before the original record, or
Object.NewRecord NewAfterCopy
to place the copy after the original record.
Used With
3-134
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Business Component Methods
Example
Version 6.0
3-135
Interfaces Reference
Business Component Methods
NextRecord
NextRecord moves the record pointer to the next record in the business component,
making that the current record and invoking any associated script events.
oBusComp.NextRecord
Syntax
Argument
Description
Not applicable
Returns
An integer in Siebel VB; a Boolean in Siebel eScript, COM, and ActiveX: 1 if the
current record was moved to the next record, 0 if the current record was already the
last record.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Here is a Siebel eScript example. For the equivalent Siebel VB example, see
FirstRecord on page 3-111.
var i = 0;
var isRecord;
with (this)
{
ClearToQuery();
SetSearchSpec("Name", "*");
ExecuteQuery(ForwardBackward);
isRecord = FirstRecord();
}
while (isRecord)
{
i++;
isRecord = BusComp.NextRecord();
}
TheApplication().MsgBox(i + " records.");
See Also
3-136
Version 6.0
Interfaces Reference
Business Component Methods
NextSelected
NextSelected moves the focus to the next record of the current multiple selection.
Syntax
oBusComp.NextSelected
Argument
Description
Not applicable
Returns
Used With
Example
For examples, see InvokeMethod on page 3-68 and FirstSelected on page 3-112.
Version 6.0
3-137
Interfaces Reference
Business Component Methods
ParentBusComp
ParentBusComp returns the parent (master) business component when given the
child (detail) business component of a Link.
oBusComp.ParentBusComp
Syntax
Argument
Description
Not applicable
Returns
Usage
ParentBusComp enables you to write code in the child business component that
accesses field values and performs actions on the parent business component using
the normal business component mechanisms.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Here is a Siebel VB example. For another example, see ExecuteQuery on page 3-107.
Dim strParentName as String
...
strParentName = Me.ParentBusComp.GetFieldValue("Name")
3-138
Version 6.0
Interfaces Reference
Business Component Methods
Pick
The Pick method places the currently selected record in a picklist business
component (see GetPicklistBusComp) into the appropriate fields of the parent
business component.
Syntax
oBusComp.Pick
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
3-139
Interfaces Reference
Business Component Methods
Example
This Siebel VB example sorts the values in the Sales Stage field.
Sub BusComp_NewRecord
Dim oBC as BusComp
set oBC = me.GetPickListBusComp("Sales Stage")
With oBC
.ClearToQuery
.ActivateField "Sales Stage Order"
.SetSortSpec "Sales Stage Order"
.ExecuteQuery ForwardOnly
if .FirstRecord then .Pick
End With
set oBC = Nothing
End Sub
See Also
3-140
Version 6.0
Interfaces Reference
Business Component Methods
PreviousRecord
oBusComp.PreviousRecord
Argument
Description
Not applicable
Returns
An integer in Siebel VB; Siebel eScript, a Boolean in COM, ActiveX, and CORBA: 1
or non-zero if the current record was moved to the previous record, 0 if the current
record was already the first record.
Usage
PreviousRecord may be used only on a business component that has been queried
using the FowardBackward CursorMode.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
Version 6.0
3-141
Interfaces Reference
Business Component Methods
RefineQuery
This method refines a query after the query has been executed.
oBusComp.RefineQuery
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
The following Siebel VB code fragment shows how RefineQuery might be used:
me.ActivateField "Status"
me.SetSearchSpec "Status", "Open"
me.ClearToQuery
me.ExecuteQuery
me.RefineQuery
me.SetSearchSpec "Substatus", "Assigned"
me.ExecuteQuery
See Also
3-142
Version 6.0
Interfaces Reference
Business Component Methods
SetFieldValue
SetFieldValue assigns the new value to the named field for the current row of the
business component.
Syntax
Description
FieldName
FieldValue
Returns
Not applicable
Usage
This method can be used only on fields that are active. See ActivateField on
page 3-98 for details.
FieldName must be enclosed in double quotes, and must be spelled exactly as the
field name appears in Siebel Tools (not in the status line of the application or the
column head), with the correct case; for example,
SetFieldValue "Name", "Acme"
NOTE: When calling SetFieldValue from a COM application, to set a field to an empty
string you must use the syntax
Used With
Version 6.0
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-143
Interfaces Reference
Business Component Methods
Example
See Also
3-144
Version 6.0
Interfaces Reference
Business Component Methods
SetFormattedFieldValue
SetFormattedFieldValue assigns the new value to the named field for the current
row of the business component. SetFormattedFieldValue accepts the field value in
the current local format.
Syntax
Description
FieldName
FieldValue
Returns
Not applicable
Usage
This method is useful when you write code for a Siebel configuration that will be
used in multiple countries with different currency, date, and number formats. This
method can be used only on fields that have been activated using ActivateField.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
This Siebel VB example is a fragment from a program designed to track the velocity
of an opportunity through its sales stages.
(general) (declarations)
Option Explicit
Dim
Dim
Dim
Dim
Dim
Dim
Version 6.0
3-145
Interfaces Reference
Business Component Methods
With SalesStageBC
.SetViewMode AllView
.ClearToQuery
.SetSearchSpec "Sales Cycle Stage", StagePrev
.ExecuteQuery ForwardOnly
.FirstRecord
StageId = .GetFieldValue("Id")
End With
'Instantiate stage BC
Set StageBC = OpportunityBO.GetBusComp("Opportunity Stage")
'Check that we do not already have a record for the stage
With StageBC
.SetViewMode AllView
.ClearToQuery
.SetSearchSpec "Sales Stage Id", StageId
.ExecuteQuery ForwardOnly
'Proceed further only if we do not already have record
'opportunity sales stage
If (.FirstRecord = 0) Then
'Create a new stage record and write it out
.NewRecord 1
'Record Id for future use
OppStageId = .GetFieldValue("Id")
.SetFieldValue "Opportunity Id", OppId
.SetFieldValue "Sales Stage Id", StageId
.SetFieldValue "Sales Rep", SalesRep
.SetFormattedFieldValue "Entered Date", StageDatePrev
.SetFormattedFieldValue "Left Date", StageDate
Dx = DateValue (StageDatePrev)
Dy = DateValue (StageDate)
Diff = Dy - Dx
DiffStr = Str(Diff)
.SetFieldValue "Days In Stage", DiffStr
.WriteRecord
End If
End With
See Also
3-146
Version 6.0
Interfaces Reference
Business Component Methods
SetNamedSearch
Description
searchName
searchSpec
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
Version 6.0
3-147
Interfaces Reference
Business Component Methods
SetSearchExpr
oBusComp.SetSearchExpr searchSpec
Argument
Description
searchSpec
Returns
Not applicable
Usage
If field values have search keywords such as NOT, AND, and OR, you must use two
pairs of double quotes around the field value. For example, if a field Sub-Status can
have the string "Not an Issue" as a field value, you must use the following syntax
in order to avoid an SQL error:
substatus = GetFieldValue("Sub-Status")
searchst = "[Value] = """ & substatus & """""
BC.SetSearchExpr searchst
3-148
Version 6.0
Interfaces Reference
Business Component Methods
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
See Also
Version 6.0
3-149
Interfaces Reference
Business Component Methods
SetSearchSpec
SetSearchSpec sets the search specification for a particular field. This method must
be called before ExecuteQuery.
Syntax
Description
FieldName
String containing the name of the field on which to set the search
specification
searchSpec
Returns
Not applicable
Usage
characters:
= > < ( ) , ~ " ' [
it must be enclosed in quotes. This rule applies to operators that are part of the
search expression as well as text to search for. If the search expression contains
quotes, those quotes must be doubled. For example, in the preceding line of code,
notice that the entire search specification is enclosed in double quotes, whereas
fields and values referred to within the specification each have single quotes.
3-150
Version 6.0
Interfaces Reference
Business Component Methods
If the search object includes a single double quote, that quote must be doubled; for
example, if you wanted to search for text containing
"We must
so that the initial quote is doubled, and the string containing it is placed within
single quotes, and the entire expression, including the single quotes, is placed
within double quotes.
If the search specification includes single quotes (including apostrophes), the
expression must be placed within single quotes, apostrophes must be doubled, and
double quotes must be placed around the entire string. Thus, for example, if you
wanted to search for Phillies Cheese Steaks in the Name field, you would have
to enter the specification as follows:
SetSearchSpec "Name", "'Phillie''s Cheese Steaks'"
Searching for text in non-text fields. If the search expression queries a field of any type
other than text, or if it is an expression other than a field-level query, text must be
placed within quotes if it contains any characters other than the following:
ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz _ ?
\ " ' [
As with text field search expressions, quotes must be doubled.
Retrieving all records. To retrieve all records efficiently, use ClearToQuery followed
by ExecuteQuery, without using SetSearchSpec.
Searching for a null field. To search for null fields, use the following form:
SetSearchSpec "Account", "is NULL"
Version 6.0
3-151
Interfaces Reference
Business Component Methods
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Example
This code enables you to search for a contact by name and then navigate to the
record displayed in a view.
(general) (declarations)
Option Explicit
Sub Button1_Click
Dim
Dim
Dim
Dim
Dim
Dim
theCurrComp As BusComp
TargetView As String
TargetBusObj As String
TargetBusComp As String
NewBusObj As BusObject
NewComp As BusComp
3-152
Version 6.0
Interfaces Reference
Business Component Methods
See Also
Version 6.0
3-153
Interfaces Reference
Business Component Methods
SetSortSpec
Syntax
Argument
Description
sortSpec
Returns
Not applicable
Usage
Used With
3-154
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Business Component Methods
Example
This Siebel VB example sorts the Opportunity list first by Account in reverse order,
then in alphabetical order by Site. Note that the column names in the Opportunity
list applet are not the same as those in the underlying business component.
NOTE: This example merely demonstrates how to sort in ascending and descending
order. In actual practice you should not sort in both directions in a single sort
specification, as it degrades performance considerably.
See Also
Version 6.0
3-155
Interfaces Reference
Business Component Methods
SetUserProperty
Sets the value of a named business component user property. The user properties
are similar to instance variables of a BusComp.
oBusComp.SetUserProperty propertyName, newValue
Syntax
Argument
Description
propertyName
newValue
Returns
Not applicable
Usage
The advantage of user properties is that they can be accessed from anywhere in the
code (including from other applications via COM) using GetUserProperty. An
instance variable, on the other hand, can be accessed only from within Siebel VB
from the same object on which the variable is declared.
Note that the value of the property is reset every time you instantiate a new business
component.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, CORBA
Object Manager
Example
3-156
Version 6.0
Interfaces Reference
Business Component Methods
See Also
SetViewMode
oBusComp.SetViewMode mode
Argument
Description
mode
0 (or SalesRepView)
1 (or ManagerView)
2 (or PersonalView)
3 (or AllView)
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
See Also
Version 6.0
3-157
Interfaces Reference
Business Component Methods
Example
3-158
Version 6.0
Interfaces Reference
Business Component Methods
SuppressNotification
SuppressNotification disables the updates to the user interface that result from
changes to the business component.
Syntax
oBusComp.SuppressNotification
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control,
ActiveX Data Control, Java Data Bean
See Also
Version 6.0
3-159
Interfaces Reference
Business Component Methods
UndoRecord
UndoRecord reverses any changes made to the record that are not committed. This
includes reversing uncommitted modifications to any and all fields, as well as
deleting an active record that has not yet been committed to the database.
oBusComp.UndoRecord
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
If you are using UndoRecord to delete a new record, it is useful only after
NewRecord has been called and before the new record has been committed. If you
are using UndoRecord to reverse changes made to field values, it is useful only
before the changes have been committed through a call to WriteRecord, or before
the user has stepped off the record through the user interface. UndoRecord will
reverse all uncommitted changes to a record. Therefore, if you wish to have a
fine degree of control over which changes are reversed, place the code in the
PreNewRecord, PreSetFieldValue, or PreWriteRecord event, and issue a
CancelOperation to cancel the change invoked by the particular event.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
3-160
Version 6.0
Interfaces Reference
Business Component Methods
WriteRecord
oBusComp.WriteRecord
Argument
Description
Not applicable
Returns
Not applicable
Usage
After creating new records and assigning values to fields, call WriteRecord to
commit the new record to the database.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
This Siebel VB example inserts an activity if the Sales Stage field is set to 02. For
other examples, see GetMVGBusComp on page 3-121 and NewRecord on
page 3-134.
(general) (declarations)
Option Explicit
Sub BusComp_SetFieldValue (FieldName As String)
' Run this code from the Opportunities Activities view.
' Opportunity is presumed to be the parent business component.
Select Case FieldName
Case "Sales Stage"
if Me.GetFieldValue(FieldName) LIKE "02*" Then
' reference the Action business component
Dim oBCact as BusComp
Set oBCact = me.BusObject.GetBusComp("Action")
With oBCact
.NewRecord NewAfter
.SetFieldValue "Type", "Event"
.SetFieldValue "Description", "THRU SVB, Stage _
changed to 02"
.SetFieldValue "Done", Format(Now(), _
"mm/dd/yyyy hh:mm:ss")
Version 6.0
3-161
Interfaces Reference
Business Component Methods
This CORBA example adds a new customer record. The error-handling routines
have been omitted for clarity.
int customer::addCustomer(char* fName, char* lName, char* street,
char* city, char* state, char* zip, SiebelApplication* pSeblApp) {
SiebelBusObject* pBusObj;
SiebelBusComp_ptr pBusComp;
short err = 0;
pBusObj = pSeblApp->GetBusObject("Contact");
pBusComp = pBusObj->GetBusComp("Contact");
//Activate necessary fields for customer look-up
try
{
pBusComp->ActivateField("First Name");
pBusComp->ActivateField("Last Name");
pBusComp->ActivateField("Personal Street Address");
pBusComp->ActivateField("Personal City");
pBusComp->ActivateField("Personal State");
pBusComp->ActivateField("Personal Postal Code");
}
//Create new record
try
{
pBusComp->NewRecord(0);
}
//Set field values
try
3-162
Version 6.0
Interfaces Reference
Business Component Methods
{
pBusComp->SetFieldValue("First Name", fName);
pBusComp->SetFieldValue("Last Name", lName);
pBusComp->SetFieldValue("Personal Street Address", street);
pBusComp->SetFieldValue("Personal City", city);
pBusComp->SetFieldValue("Personal State", state);
pBusComp->SetFieldValue("Personal Postal Code", zip);
}
//Commit record
try
{
pBusComp->WriteRecord();
}
return 1;
}
Version 6.0
3-163
Interfaces Reference
Business Component Events
BusComp_Associate
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
Used With
See Also
3-164
Version 6.0
Interfaces Reference
Business Component Events
BusComp_ChangeRecord
The ChangeRecord event is called after a record becomes the current row in the
business component.
Syntax
BusComp_ChangeRecord
Argument
Description
Not applicable
Returns
Not applicable
Usage
Code in the ChangeRecord event handler is executed each time that the focus
changes to another record. Avoid lengthy operations in this event handler to enable
smooth scrolling in list applets.
Used With
Example
Version 6.0
3-165
Interfaces Reference
Business Component Events
With ActionBC
.ActivateField "Activity SR Id"
.ActivateField "Description"
.ActivateField "Private"
.ActivateField "Service request id"
.ActivateField "Type"
.NewRecord NewAfter
.SetFieldValue
.SetFieldValue
.SetFieldValue
.SetFieldValue
.WriteRecord
End With
End Sub
"Activity SR Id",
theSRNumber
"Description",
ChangedText
"Private","Y"
"Type",
"Administration"
Sub InitializeOldValues
OldClosedDate = GetFieldValue("Closed Date")
OldOwner = GetFieldValue("Owner")
OldSeverity = GetFieldValue("Severity")
If GetFieldValue("Severity") <> OldSeverity Then
NewValue = GetFieldValue("Severity")
ChangedText = "Changed Priority from " + OldSeverity + _
" to " + NewValue
CreateAuditRecord "Severity", NewValue, OldSeverity, _
ChangedText
End If
End Sub
Sub BusComp_ChangeRecord
InitializeOldValues
End Sub
3-166
Version 6.0
Interfaces Reference
Business Component Events
BusComp_CopyRecord
The CopyRecord event is called after a row has been copied in the business
component and that row has been made active.
Syntax
BusComp_CopyRecord
Argument
Description
Not applicable
Returns
Not applicable
Usage
Version 6.0
3-167
Interfaces Reference
Business Component Events
BusComp_DeleteRecord
The DeleteRecord event is called after a row is deleted. The current context is a
different row (the Fields of the just-deleted row are no longer available).
BusComp_DeleteRecord
Syntax
Argument
Description
Not applicable
Usage
When a user reads and deletes an existing record or creates and undoes a new
record, the system invokes DeleteRecord. This invocation causes any associated
scripts to be executed.
Returns
Not applicable
Used With
3-168
Version 6.0
Interfaces Reference
Business Component Events
BusComp_InvokeMethod
BusComp_InvokeMethod(methodName)
Argument
Description
methodName
Returns
Not applicable
Usage
Used With
Version 6.0
3-169
Interfaces Reference
Business Component Events
BusComp_NewRecord
The NewRecord event is called after a new row has been created in the business
component and that row has been made active. The event may be used to set up
default values for Fields.
BusComp_NewRecord
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Usage
BusComp_NewRecord is called when a new record is created unless the new record
was created:
Example
3-170
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreAssociate
BusComp_PreAssociate
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Version 6.0
3-171
Interfaces Reference
Business Component Events
BusComp_PreCopyRecord
The PreCopyRecord event is called before a new row is copied in the business
component. The event may be used to perform pre-copy validation.
BusComp_PreNewRecord
Syntax
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
3-172
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreDeleteRecord
BusComp_PreDeleteRecord
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
This event is called after the user has confirmed the deletion of the record,
but before the record is deleted from the database.
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Version 6.0
3-173
Interfaces Reference
Business Component Events
Example
This Siebel VB example prevents the deletion of an account that has associated
opportunities.
(general) (declarations)
Option Explicit
Function BusComp_PreDeleteRecord As Integer
Dim iReturn as integer
Dim oBC as BusComp
Dim oBO as BusObject
Dim sAcctRowId as string
iReturn = ContinueOperation
sAcctRowId = me.GetFieldValue("Id")
set oBO = TheApplication.GetBusObject("Opportunity")
set oBC = oBO.GetBusComp("Opportunity")
With oBC
.SetViewMode AllView
.ActivateField "Account Id"
.ClearToQuery
.SetSearchSpec "Account Id", sAcctRowId
.ExecuteQuery ForwardOnly
If (.FirstRecord) = 1 Then
MsgBox("Opportunities exist for the Account - _
Delete is not allowed")
iReturn = CancelOperation
End If
End With
BusComp_PreDeleteRecord = iReturn
Set oBC = Nothing
Set oBO = Nothing
End Function
3-174
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreGetFieldValue
The PreGetFieldValue event is called when the value of a business component field
is accessed.
Syntax
BusComp_PreGetFieldValue(FieldName, FieldValue)
Argument
Description
FieldName
FieldValue
Returns
ContinueOperation or CancelOperation
Usage
PreGetFieldValue will be called at least once for each user interface element that
displays the BusComp field value, and it may also be called as a result of other
internal uses.
NOTE: PreGetFieldValue is called every time the user interface is updated to re-paint
fields on the screen. Therefore, a script attached to this event runs very frequently,
which may cause the system to appear to be frozen.
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Version 6.0
3-175
Interfaces Reference
Business Component Events
BusComp_PreInvokeMethod
Syntax
Argument
Description
methodName
Returns
ContinueOperation or CancelOperation
Usage
Used With
3-176
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreNewRecord
The PreNewRecord event is called before a new row is created in the business
component. The event may be used to perform pre-insert validation.
Syntax
BusComp_PreNewRecord
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Version 6.0
3-177
Interfaces Reference
Business Component Events
BusComp_PreQuery
Syntax
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
This event may be used to modify the search criteria or to restrict the execution
of certain queries.
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Example
3-178
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreSetFieldValue
The PreSetFieldValue event is called before a value is pushed down into the
business component from the user interface or through a call to SetFieldValue.
Syntax
BusComp_PreSetFieldValue(FieldName, FieldValue)
Argument
Description
FieldName
FieldValue
Returns
ContinueOperation or CancelOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Version 6.0
3-179
Interfaces Reference
Business Component Events
Example
This Siebel VB example uses the PreSetFieldValue event to check if a quote discount
is greater than 20 percent, and to take appropriate action if it is. For other examples
of BusComp_PreSetFieldValue, see LoginId on page 3-72, and ExecuteQuery on
page 3-107.
Function BusComp_PreSetFieldValue (FieldName As String,
FieldValue As String) As Integer
Dim value as Integer, iReturn as Integer
Dim msgtext as String
iReturn = ContinueOperation
If FieldName = "Discount" then
value = Val(FieldValue)
If value > 20 then
msgtext = "Discounts greater than 20% must be approved"
msgbox msgtext
iReturn = CancelOperation
Else
iReturn = ContinueOperation
End if
End If
BusComp_PreSetFieldValue = iReturn
End Function
3-180
Version 6.0
Interfaces Reference
Business Component Events
BusComp_PreWriteRecord
The PreWriteRecord event is called before a row is written out to the database. The
event may perform any final validation necessary before the actual save occurs.
Syntax
BusComp_PreWriteRecord
Argument
Description
Not applicable
Returns
ContinueOperation or CancelOperation
Usage
CancelOperation stops the execution of the underlying Siebel code associated with
the event. However, if there is code in the same script following CancelOperation,
that code will run regardless of the CancelOperation.
Used With
Example
Version 6.0
3-181
Interfaces Reference
Business Component Events
BusComp_Query
The Query event is called just after the query is complete and all the rows have been
retrieved, but before the rows are actually displayed.
BusComp_Query
Syntax
Argument
Description
Not applicable
Returns
Not applicable
Used With
3-182
Version 6.0
Interfaces Reference
Business Component Events
Example
Version 6.0
3-183
Interfaces Reference
Business Component Events
BusComp_SetFieldValue
The SetFieldValue event is called when a value is pushed down into the business
component from the user interface or through a call to SetFieldValue.
BusComp_SetFieldValue(FieldName)
Syntax
Argument
Description
FieldName
Returns
Not applicable
Used With
Example
3-184
Version 6.0
Interfaces Reference
Business Component Events
BusComp_WriteRecord
The WriteRecord event is called after a row is written out to the database.
Syntax
BusComp_WriteRecord
Argument
Description
Not applicable
Returns
Not applicable
Used With
Version 6.0
3-185
Interfaces Reference
Business Object Methods
In the descriptions that follow, the term oBusObj indicates a variable containing a
BusObject.
GetBusComp
Syntax
Argument
Description
BusCompName
Returns
Usage
BusCompName is case sensitive, and must match in case the form of the name as it
appears in Siebel Tools. If an instance of BusCompName already exists, that instance
will be returned. Siebel will instantiate and return a new instance of a business
component using BusCompName if one does not already exist.
The Nothing function should be used to destroy the instantiated business
component when it is no longer necessary.
Used With
3-186
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Business Object Methods
GetLastErrCode
oBusObj.GetLastErrCode
Argument
Description
Not applicable
Returns
Usage
Used With
See Also
Version 6.0
3-187
Interfaces Reference
Business Object Methods
GetLastErrText
Syntax
Argument
Description
Not applicable
Returns
Usage
Used With
See Also
3-188
Version 6.0
Interfaces Reference
Business Object Methods
Name
oBusObj.Name
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
For an example, see the business component method Name on page 3-133.
* Implemented as an attribute.
Version 6.0
3-189
Interfaces Reference
Business Service Methods
GetFirstProperty
This method retrieves the name of the first property of a business service.
oService.GetFirstProperty()
Syntax
Parameter
Description
Not applicable
Returns
A string containing the name of the first property of the business service.
Usage
This method 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
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
See Also
3-190
Version 6.0
Interfaces Reference
Business Service Methods
GetNextProperty
Once the name of the first property has been retrieved, this method retrieves the
name of the next property of a business service.
Syntax
oService.GetNextProperty()
Parameter
Description
Not applicable
Returns
A string containing the name of the next property of a business service, or a null
string ("") if no more properties exist.
Usage
After retrieving the name of the first property with GetFirstProperty, the
GetNextProperty method should be used in a loop, to be terminated when a null
string ("") is returned. When property names have been retrieved, they can be used
as parameters to GetProperty in order to retrieve the property value, or with
SetProperty to assign property values.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
See Also
Version 6.0
3-191
Interfaces Reference
Business Service Methods
GetProperty
The GetProperty method returns the value of the property whose name is specified
in its argument.
oService.GetProperty(propName)
Syntax
Parameter
Description
propName
Returns
Usage
You must know the name of a property to retrieve its value. To retrieve property
names, use the GetFirstProperty and GetNextProperty methods.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
See Also
3-192
Version 6.0
Interfaces Reference
Business Service Methods
InvokeMethod
The InvokeMethod method calls a method on the business service. This can be a
documented specialized method or a user-created method.
Syntax
Description
methodName
InputArguments
OutputArguments
Returns
Not applicable
Usage
Built-in business services work the same way as business component invoke
methods. That is, you can call specialized methods on the service that are not
exposed directly through the object interface.
Run-time business services can hold user-defined methods, which must be
implemented in scripts written in Siebel VB or Siebel eScript. The scripts must be
written in these languages within Siebel Tools; however, they can be called through
external interfaces.
Although the InvokeMethod function does not return a value, the properties in the
OutputArguments property set may have been modified.
Used With
Version 6.0
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-193
Interfaces Reference
Business Service Methods
Example
This Siebel VB example invokes the Shipping Engine business service created in
Service_PreInvokeMethod on page 3-200. It gets values from the keyboard via input
boxes, passes a property set to the service, and gets return values by means of
another property set. One possible result appears in the illustration following the
code.
Sub Shipping_Click
Dim
Dim
Dim
Dim
Dim
oBS As Service
Inputs As PropertySet, Outputs As PropertySet
sShipper As String, sShipMethod As String
sWeight As String, sSize As String, sCost As String
sZone As String, DelDate As Variant
3-194
Version 6.0
Interfaces Reference
Business Service Methods
See Also
Name
oService.Name
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager*
Example
Version 6.0
3-195
Interfaces Reference
Business Service Methods
PropertyExists
This method returns a Boolean value indicating whether a specified property exists.
oService.PropertyExists(propName)
Syntax
Parameter
Description
propName
Returns
In Siebel VB, an integer (0 for false, 1 for true); in all other interfaces, a Boolean.
Usage
Since GetProperty returns a null string ("") for all nonexistent properties, you
should use PropertyExists() in an if statement to determine whether a specific
property has been set.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
3-196
Version 6.0
Interfaces Reference
Business Service Methods
RemoveProperty
oService.RemoveProperty(propName)
Parameter
Description
propName
Returns
Not applicable
Usage
This method removes the property propName from the business service oService. As
a result, subsequent calls to PropertyExists for that property will return FALSE.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
See Also
Version 6.0
3-197
Interfaces Reference
Business Service Methods
SetProperty
Syntax
Parameter
Description
propName
propValue
Returns
Not applicable
Usage
SetProperty is used to set the value of a property of the business service from one
of the methods of the service or from an external method. SetProperty may be used
to set properties in the Outputs property set.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
Example
See Also
3-198
Version 6.0
Interfaces Reference
Business Service Events
Service_InvokeMethod
Description
methodName
InputArguments
OutputArguments
Returns
Not applicable
Usage
Although this event does not return a value, it may add properties to, or alter the
values of the properties in, the property set OutputArguments.
The InvokeMethod event is called after a specialized or user-defined method called
by Service_PreInvokeMethod has completed.This event is generally used less often
than Service_PreInvokeMethod, because it is called after any built-in Siebel code
may have executed, whereas the PreInvokeMethod is called before the built-in code,
and may supplant it if Service_PreInvokeMethod returns CancelOperation.
Used With
See Also
Version 6.0
3-199
Interfaces Reference
Business Service Events
Service_PreInvokeMethod
Returns
3-200
Description
methodName
InputArguments
OutputArguments
CancelOperation or ContinueOperation
Version 6.0
Interfaces Reference
Business Service Events
Usage
S te p 1
PreInvokeMethod
Event fires to run VB or
eScript code
CancelOperation
ContinueOperation
S te p 2
S te p 3
Figure 3-1.
InvokeMethod
Raises an "Unknown
method name" error
Stop
Stop
Version 6.0
3-201
Interfaces Reference
Business Service Events
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, CORBA Object Manager
Example
iReturn = ContinueOperation
sShipper = Inputs.GetProperty("Shipping Company")
sShipMethod = Inputs.GetProperty("Ship Method")
dWeight = Val(Inputs.GetProperty("Weight"))
dSize = Val(Inputs.GetProperty("Total Dimensions"))
iZone = Val(Inputs.GetProperty("Zone"))
DelDate = DateValue(Now)
Select Case sShipper
Case "GlobalEx"
Select Case sShipMethod
Case "Next-Day Air"
dCost = 14 + dWeight
DelDate = DelDate + 1
Case "Second-Day Air"
dCost = 11 + (dWeight * .54)
DelDate = DelDate + 2
End Select
Case "Airline"
Select Case sShipMethod
Case "Next-Day Air"
dCost = 5 + (dWeight * .3) + (dSize * .33) + _
(Val(sZone) * .5)
DelDate = DelDate + 1
Case "Second-Day Air"
dCost = 4 + (dWeight * .3) + (dSize * .2) + _
(Val(sZone) * .3)
DelDate = DelDate + 2
3-202
Version 6.0
Interfaces Reference
Business Service Events
Case "Ground"
dCost = 3 + (dWeight * .18) + (dSize * .1) + _
(Val(sZone) * .1)
DelDate = DelDate + 2 + Int(Val(sZone) * .8)
End Select
End Select
sCost = Format(dCost, "Currency")
Outputs.SetProperty "Cost", sCost
Outputs.SetProperty "Delivery Date", DelDate
iReturn = CancelOperation
End If
Service_PreInvokeMethod = iReturn
End Function
See Also
Version 6.0
3-203
Interfaces Reference
Property Set Methods
AddChild
The AddChild method is used to add subsidiary property sets to a property set, in
order to form hierarchical (tree-structured) data structures.
oPropSet.AddChild(childObject)
Syntax
Parameter
Description
childObject
Returns
Usage
Property sets can be used to create tree-structured data structures. Any number of
arbitrarily structured child property sets can be added to a property set. You may
use child property sets to structure a property set in a manner similar to the data
model. Thus, for example, the parent property set might be Account, with child
property sets for opportunities, contacts, activities, and so on. At the same time, you
could construct an independent property set called Opportunity, to which accounts,
contacts, and activities might be children.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-204
Version 6.0
Interfaces Reference
Property Set Methods
Example
The following fragment of eScript code shows how child property sets may be added
to a parent property set.
var
var
var
var
Account = TheApplication().NewPropertySet();
Opportunity = TheApplication().NewPropertySet();
Contact = TheApplication().NewPropertySet();
Activity = TheApplication().NewPropertySet();
Account.AddChild(Opportunity);
Account.AddChild(Contact);
Account.AddChild(Activity);
See Also
Version 6.0
3-205
Interfaces Reference
Property Set Methods
Copy
Syntax
Parameter
Description
Not applicable
Returns
Usage
This method creates a copy of a property set, including any properties and children
it may have. Since property sets are generally passed by reference, making a copy
enables the method to manipulate the property set without affecting the original
definition.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
This Siebel VB uses a copy of a property set to store the original values of its
properties, and displays both the original and Pig-Latin forms of the properties, as
shown in the illustration following the example.
(general) (declarations)
Option Explicit
Function PigLatin (Name1 As String) As String
Dim Name2 As String, FirstLetter As String
Name2 = Right$(Name1, len(Name1) - 1)
FirstLetter = Left$(Name1, 1)
Name2 = UCase(Mid$(Name1, 2, 1)) & _
Right$(Name2, Len(Name2) - 1)
Name2 = Name2 & LCase(FirstLetter) & "ay"
PigLatin = Name2
End Function
3-206
Version 6.0
Interfaces Reference
Property Set Methods
Sub ClickMe_Click
Dim Inputs As PropertySet, Outputs As PropertySet
Dim message As String, propName, propVal, newPropVal
set Inputs = theApplication.NewPropertySet
Inputs.SetProperty "Name", "Harold"
Inputs.SetProperty "Assistant", "Kathryn"
Inputs.SetProperty "Driver", "Merton"
set Outputs = Inputs.Copy()
propName = Outputs.GetFirstProperty()
do while propName <> ""
propVal = Outputs.GetProperty(propName)
newPropVal = PigLatin(propVal)
Outputs.SetProperty propName, newPropVal
message = message & propVal & " has become " & _
newPropVal & Chr$(13)
propName = Outputs.GetNextProperty()
loop
MsgBox message, mbOKOnly, "Pig-Latin Translator"
End Sub
Version 6.0
3-207
Interfaces Reference
Property Set Methods
GetChild
Syntax
oPropSet.GetChild(index)
Parameter
Description
index
Returns
Usage
When child property sets are created, each is given an index number within the
parent property set, starting at 0. Property sets added using AddChild get the next
available index number. However, a property set added using InsertChildAt inserts
a new property set at a specified index. The property set previously at that index,
and all property sets after it, have their indexes increased by 1. Similarly, a property
set removed using RemoveChild decreases the indexes of following child property
sets by 1.
NOTE: This method returns the number of direct descendants only. That is, if the
child property sets have children of their own, these grandchildren are not included
in the computation of the return value.
Used With
3-208
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
Interfaces Reference
Property Set Methods
Example
This Siebel eScript example sets the Name property of all child property sets to the
same value.
function Test1_Click ()
{
var Account = TheApplication().NewPropertySet();
var Opportunity = TheApplication().NewPropertySet();
var Contact = TheApplication().NewPropertySet();
var Activity = TheApplication().NewPropertySet();
var j;
Account.AddChild(Opportunity);
Account.AddChild(Contact);
Account.AddChild(Activity);
for (var i = 0; i < Account.GetChildCount(); i++)
{
j = Account.GetChild(i);
j.SetProperty('Name', 'Allied Handbooks');
}
}
See Also
Version 6.0
3-209
Interfaces Reference
Property Set Methods
GetChildCount
This method returns the number of child property sets attached to a parent property
set.
oPropSet.GetChildCount()
Syntax
Parameter
Description
Not applicable
Returns
Usage
This method returns the actual number of child property sets of oPropSet. Since
index numbers for child property sets start at 0, a child count of 3 indicates that
there are child property sets at indexes 0, 1, and 2.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object
Manager*
Example
3-210
Version 6.0
Interfaces Reference
Property Set Methods
GetFirstProperty
This method returns the name of the first property in a property set.
Syntax
oPropSet.GetFirstProperty()
Parameter
Description
Not applicable
Returns
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
See Also
Version 6.0
3-211
Interfaces Reference
Property Set Methods
GetNextProperty
Syntax
Parameter
Description
Not applicable
Returns
Usage
After retrieving the name of the first property with the GetFirstProperty method,
GetNextProperty should be used in a loop, to be terminated when a null string ("")
is returned. When property names have been retrieved, they may be used as
parameters to GetProperty in order to retrieve the property value, or with
SetProperty to assign property values.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
For examples, see Copy on page 3-206 and GetFirstProperty on page 3-211.
See Also
3-212
Version 6.0
Interfaces Reference
Property Set Methods
GetProperty
This method returns the value of a property when given the property name.
Syntax
oPropSet.GetProperty(propName)
Parameter
Description
propName
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
The following fragment of Siebel eScript code receives a set of input properties used
with the Shipping Engine service described in Service_PreInvokeMethod on
page 3-200.
var Inputs = TheApplication().NewPropertySet();
var
var
var
var
See Also
Version 6.0
3-213
Interfaces Reference
Property Set Methods
GetType
This method retrieves the data value stored in the type attribute of a property set.
oPropSet.GetType
Syntax
Parameter
Description
Not applicable
Returns
A string representing the value stored in the type attribute of the property set.
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
3-214
Version 6.0
Interfaces Reference
Property Set Methods
GetValue
This method retrieves the data value stored in the value attribute of a property set.
Syntax
oPropSet.GetValue
Parameter
Description
Not applicable
Returns
A string representing the data value stored in the value attribute of a property set.
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
GetProperty on page 3-213, GetType on page 3-214, and SetValue on page 3-223
Version 6.0
3-215
Interfaces Reference
Property Set Methods
InsertChildAt
This method inserts a child property set into a parent property set at a specific
location.
oPropSet.InsertChildAt childObject, index
Syntax
Parameter
Description
childObject
index
Returns
Not applicable
Usage
This method inserts the property set childObject at the location index. Index
numbers start at 0. When a child property set is inserted, the property set previously
at the location index has its index increased by 1, as do all subsequent child
property sets.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
3-216
Version 6.0
Interfaces Reference
Property Set Methods
PropertyExists
This method returns a Boolean value indicating whether a specified property exists
in a property set.
Syntax
oPropSet.PropertyExists(propName)
Parameter
Description
propName
Returns
In Siebel VB, an integer (0 for false, 1 for true); in all other interfaces, a Boolean.
Usage
Since GetProperty returns a null string ("") for all nonexistent properties, you
should use PropertyExists() in an if statement to determine whether a specific
property has been set.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
Version 6.0
3-217
Interfaces Reference
Property Set Methods
RemoveChild
This method removes a child property set from a parent property set.
oPropSet.RemoveChild index
Syntax
Parameter
Description
index
Returns
Not applicable
Usage
When a child property set is removed, all child property sets with indexes higher
than that of the removed set have their indexes decremented by 1.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
The following Siebel VB code fragment removes all child property sets of a property
set.
Dim i As Integer
for i = 0 to outputs.GetChildCount()
outputs.RemoveChild(0)
Next i
See Also
3-218
Version 6.0
Interfaces Reference
Property Set Methods
RemoveProperty
oPropSet.RemoveProperty propName
Parameter
Description
propName
Returns
Not applicable
Usage
This method removes the property propName from the property set oPropSet.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Version 6.0
3-219
Interfaces Reference
Property Set Methods
Reset
This method removes all properties and child property sets from a property set.
oPropSet.Reset()
Syntax
Parameter
Description
Not applicable
Returns
Not applicable
Usage
This method removes all properties and children from a property set, allowing the
property set to be reused with new properties.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
3-220
Version 6.0
Interfaces Reference
Property Set Methods
SetProperty
Description
propName
propValue
Returns
Not applicable
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
Example
This Siebel VB fragment makes use of the business service Shipping Engine,
which is illustrated in Service_PreInvokeMethod on page 3-200.
Dim
Dim
Set
Set
Svc As Service
Inputs As PropertySet, Outputs As PropertySet
Svc = theApplication.GetService("Shipping Engine")
Inputs = theApplication.NewPropertySet()
With Inputs
.SetProperty
.SetProperty
.SetProperty
.SetProperty
End With
See Also
Version 6.0
3-221
Interfaces Reference
Property Set Methods
SetType
This method assigns a data value to the type attribute of a property set.
oPropSet.SetType type
Syntax
Parameter
Description
type
Returns
Not applicable
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
3-222
Version 6.0
Interfaces Reference
Property Set Methods
SetValue
This method assigns a data value to the value attribute of a property set.
Syntax
oPropSet.SetValue value
Parameter
Description
value
Returns
Not applicable
Usage
Values, like properties and types, are simply storage locations for a data value.
Used With
Siebel VB, Siebel eScript, COM Automation Server, COM Data Server, ActiveX
Application Control, ActiveX Data Control, Java Data Bean, CORBA Object Manager
See Also
GetValue on page 3-215, SetProperty on page 3-221 and SetValue on page 3-223
Version 6.0
3-223
Interfaces Reference
Control Methods
Control Methods
In the methods that follow, the placeholder controlVar stands for the name of the
control on which the method is invoked; for example, Button1_Click.
Applet
The Applet method returns the parent applet object for a control.
controlVar.Applet
Syntax
Argument
Description
Not applicable
Returns
Usage
Obtaining the parent applet allows you to perform operations on the applet object,
not just the control.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
3-224
Version 6.0
Interfaces Reference
Control Methods
BusComp
controlVar.BusComp
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
3-225
Interfaces Reference
Control Methods
BusObject
The BusObject method returns the corresponding business object for a control. This
is a shortcut for getting the business object associated with the parent applet.
controlVar.BusObject
Syntax
Argument
Description
Not applicable
Returns
The business object containing the business component used by the parent applet
of the control.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
In Siebel VB:
Dim oControl as Control
Dim oBusObject as BusObject
Dim oBusComp as BusComp
Set oBusObject = oControl.BusObject
3-226
Version 6.0
Interfaces Reference
Control Methods
GetProperty
Description
propName
The name of the property to be retrieved, which must be one of the following
strings:
BackgroundColor
ForegroundColor
TextStyle
Enabled
Shown
The following table lists the type of value that can be retrieved for each property
type.
Version 6.0
Property
Value
Description
BackgroundColor
ForegroundColor
TextStyle
textStyleName
Enabled
true or false
Shown
true or false
3-227
Interfaces Reference
Control Methods
Returns
Usage
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
See Also
3-228
Version 6.0
Interfaces Reference
Control Methods
GetValue
The GetValue method returns the value of the control. The type of the return value
depends on the specific control object.
Syntax
controlVar.GetValue
Argument
Description
Not applicable
Returns
The value of the control, of the data type that the control displays.
Usage
The GetValue and SetValue methods will work only for controls that are associated
with business component fields. Therefore, these methods are not applicable
to labels.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
Version 6.0
3-229
Interfaces Reference
Control Methods
Name
Syntax
Argument
Description
Not applicable
Returns
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
For an example, see the business component method Name on page 3-133.
3-230
Version 6.0
Interfaces Reference
Control Methods
SetProperty
controlVar.SetProperty(propName, propValue)
Argument
Description
propName
propValue
The following table lists the properties that can be set for a control, and the values
that can be assigned to them
Property
Value
Description
BackgroundColor
ForegroundColor
TextStyle
textStyleName
Enabled
true or false
Shown
true or false
Returns
Not applicable
Usage
If more than one property is to be set, each must be set in a separate statement.
RGB values must be between 0 and 255.
Version 6.0
3-231
Interfaces Reference
Control Methods
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Example
See Also
3-232
Version 6.0
Interfaces Reference
Control Methods
SetValue
The SetValue method sets the contents of the specified control to the
value indicated.
Syntax
controlVar.SetValue (controlValue)
Argument
Description
controlValue
Returns
Not applicable
Usage
The GetValue and SetValue methods will work only for controls that are associated
with business component fields. Therefore, these methods are not applicable to
labels. SetValue sets the contents of a control. The user can still change those
contents before they are committed to the BusComp field.
Used With
Siebel VB, Siebel eScript, COM Automation Server, ActiveX Application Control
Version 6.0
3-233
Interfaces Reference
Web Applet Methods
BusComp
BusComp returns the business component that is associated with the Web applet.
oWebApplet.BusComp
Syntax
Argument
Description
Not applicable
Returns
Used With
BusObject
BusObject returns the business object for the business component for the Web
applet.
oWebApplet.BusObject
Syntax
Argument
Description
Not applicable
Returns
Used With
3-234
Version 6.0
Interfaces Reference
Web Applet Methods
InvokeMethod
eScript
Syntax
oWebApplet.InvokeMethod(methodName, methodArgs)
Argument
Description
methodName
methodArgs
Description
methodName
Returns
Usage
InvokeMethod should be used only to call supported specialized methods or userdefined methods for the Web applet.
Used With
Version 6.0
3-235
Interfaces Reference
Web Applet Methods
Name
Syntax
Argument
Description
Not applicable
Returns
Used With
3-236
Version 6.0
Interfaces Reference
Web Applet Events
WebApplet_InvokeMethod
WebApplet_InvokeMethod(methodName)
Argument
Description
methodName
Returns
Not applicable
Used With
See Also
Version 6.0
3-237
Interfaces Reference
Web Applet Events
WebApplet_PreInvokeMethod
The PreInvokeMethod event is called before a specialized method for the Web
applet is invoked by the system or a user-defined method is invoked via
oWebApplet.InvokeMethod.
WebApplet_PreInvokeMethod(methodName)
Syntax
Argument
Description
methodName
Returns
ContinueOperation or CancelOperation
Usage
Used With
3-238
Version 6.0
Interfaces Reference
Web Applet Events
WebApplet_ShowControl
This event allows scripts to modify the HTML generated by the Siebel Web Engine
to render a control on a Web page in a .COM application.
Syntax
Description
controlName
property
mode
The mode of the applet that is being shown; possible modes are:
Base
Edit
New
Query
Sort
HTML
The HTML generated by the Siebel Web Engine for the swe:control or
swe:this tag that triggers this event
Returns
Not applicable
Usage
The generated HTML depends on the control, the property being shown, and the
mode of the applet. The script can modify the value of the HTML parameter, and
the Siebel Web Engine will send the modified value back to the Web browser.
Version 6.0
3-239
Interfaces Reference
Web Applet Events
.COM applications render the layout of applets using template files (.swt files).
These are HTML files that contain special placeholder tags that indicate where a
control is to be rendered. These control placeholder tags (<swe:control>) can be
included in the following two ways:
The <swe:control> tag and <swe:this> tag are used to show a control.
<swe:control id="1">
.
.
.
<swe:this property="DisplayName"/>
.
.
.
</swe:control>
In the first instance, if the control ID is mapped to an actual control in the applet
using Siebel Tools, Siebel Web Engine will render the DisplayName property of the
control at the point where this tag is placed in the template file.
In the second instance, the Siebel Web Engine renders the DisplayName property of
the control at the point where the <swe:this> tag is placed in the template file.
The outer <swe:control> tag in this case is used only to check if the control ID
is mapped to an actual control in the applet.
The Siebel Web Engine converts these tags into HTML to render the controls on the
Web page. The WebApplet_ShowControl event is triggered for each of these tags
after the Siebel Web Engine has generated the HTML for rendering the control, but
before the generated HTML is sent back to the browser. This gives the scripts a
chance to modify the generated HTML before it is shown.
3-240
Version 6.0
Interfaces Reference
Web Applet Events
In the first example, the event fires only once, after the HTML for the
<swe:control> tag is generated by the Siebel Web Engine. In the second
example, this event gets fired twice. The event is first fired when the Siebel Web
Engine has generated the HTML for the <swe:this> tag. The event is fired again
when the Siebel Web Engine has generated the HTML for the outer
<swe:control> tag; that is, after everything between the <swe:control> and
</swe:control> tags, including the <swe:this> tag, is converted into HTML.
The script can distinguish between these two event calls by the value of the
property attribute of the tag that is passed as a parameter to the event.
Used With
See Also
Example
This Siebel eScript script displays negative amounts in red in a read-only form.
function WebApplet_ShowControl (ControlName, Property, Mode, &HTML)
{
var BC = me.BusComp;
if( ControlName == "Amount" && Mode == "Base" && Property ==
"FormattedHTML")
{
var amount = ToNumber(BC.GetFieldValue ("Transaction
Amount"));
If amount < 0
HTML = "<FONT Color=Red> " + HTML + " </FONT>";
}
}
Version 6.0
3-241
Interfaces Reference
Web Applet Events
WebApplet_ShowListColumn
This event allows scripts to modify the HTML generated by the Siebel Web Engine
to render a list column on a Web page in a .COM application.
Syntax
Description
columnName
property
mode
The mode of the applet that is being shown; possible modes are:
Base
Edit
New
Query
Sort
HTML
Returns
3-242
The HTML generated by the Siebel Web Engine for the swe:control or
swe:this tag that triggers this event
Not applicable
Version 6.0
Interfaces Reference
Web Applet Events
Usage
The generated HTML depends on the list column, the property being shown, and
the mode of the applet. The script can modify the value of the HTML parameter,
and the Siebel Web Engine will send the modified value back to the Web browser.
.COM applications render the layout of applets using template files (.swt files).
These are HTML files that contain special placeholder tags that indicate where a
control is to be rendered. These control placeholder tags (<swe:control>) can be
included in the following two ways:
The <swe:control> tag and <swe:this> tag are used to show a list
column:
<swe:control id="1">
.
.
.
<swe:this property="DisplayName"/>
.
.
.
</swe:control>
In the first instance, if the list column ID is mapped to a list column in the applet
using Siebel Tools, Siebel Web Engine will render the DisplayName property of the
list column at the point where this tag is placed in the template file.
In the second instance, the Siebel Web Engine renders the DisplayName property of
the list column at the point where the <swe:this> tag is placed in the template
file. The outer <swe:control> tag in this case is used only to check if the list
column ID is mapped to an actual list column in the applet.
The Siebel Web Engine converts these tags into HTML to render the list columns on
the Web page. The WebApplet_ShowListColumn event is triggered for each of these
tags after the Siebel Web Engine has generated the HTML for rendering the list
column, but before the generated HTML is sent back to the browser. This gives the
scripts a chance to modify the generated HTML before it is shown.
Version 6.0
3-243
Interfaces Reference
Web Applet Events
In the first example, the event fires only once, after the HTML for the
<swe:control> tag is generated by the Siebel Web Engine. In the second
example, this event is triggered twice. The event is first triggered when the Siebel
Web Engine has generated the HTML for the <swe:this> tag. The event is fired
again when the Siebel Web Engine has generated the HTML for the outer
<swe:control> tag; that is, after everything between the <swe:control> and
</swe:control> tags, including the <swe:this> tag, is converted into HTML.
The script can distinguish between these two event calls by the value of the
property attribute of the tag that is passed as a parameter to the event.
Used With
See Also
Example
3-244
Version 6.0
Interfaces Reference
SiebelAppFactory Methods
SiebelAppFactory Methods
CreateSiebelAppObject
factoryRef->CreateSiebelAppObject()
Argument
Description
Not applicable
Returns
Usage
Obtain the SiebelAppFactory object reference as shown below in the example. Then
invoke SiebelAppFactory.CreateSiebelAppObject to obtain an object reference for a
Siebel Application object.
Used With
Example
This C++ example illustrates how to get a reference for the SiebelAppFactory.
char* strServerName = new char[SERVER_NAME_LEN];
char* strHostName = "SCOMSERVER";
// append the host name to the server name
strcpy(strServerName,"SiebelObjectFactory:SiebelCorbaServer");
try {
// bind to the Factory object in the server.
appFact = SiebelAppFactory::_bind(strServerName, strHostName);
} catch(const CORBA::SystemException& excep) {
cout << "Error binding to SiebelObjectFactory" <<
endl;
return;
}
Version 6.0
3-245
Interfaces Reference
SiebelAppFactory Methods
3-246
Version 6.0
Interfaces Reference
Miscellaneous Methods and Events
ControlName_Click
The Click event is called when the user clicks a push-button control.
Syntax
Usage
ControlName_Click
Argument
Description
ControlName
The control event procedures are made up of the control name and the event name.
Both are necessary because control event procedures are actually stored in the same
module that contains their applet procedures.
This method should not be used in combination with the MethodInvoked property,
but is rather an alternative to it. ControlName_Click looks for user-defined methods
in Applet_PreInvokeMethod and then in BusComp_PreInvokeMethod, but it will
not look in Application_PreInvokeMethod.
Used With
Example
The following VB example launches Microsoft Excel upon the click of a user-defined
button.
Sub btnExcel_Click
Dim i as long
i = Shell("C:\Program Files\Microsoft Office\Office\EXCEL.EXE",1)
End Sub
Version 6.0
3-247
Interfaces Reference
Miscellaneous Methods and Events
GetErrorCode
This method is used with the Java Data Bean to display numeric error codes.
public int getErrorCode()
Syntax
Parameter
Description
Not applicable
Returns
Used With
See Also
GetErrorMessage
This method is used with the Java Data Bean to display error messages.
public string getErrorMessage()
Syntax
Parameter
Description
Not applicable
Returns
Used With
See Also
3-248
Version 6.0
Interfaces Reference
Miscellaneous Methods and Events
theApplication
theApplication
eScript
Syntax
TheApplication()
Argument
Description
Not applicable
Returns
Usage
Used With
Example
To retrieve the login name from the application object and create the Employee
business object:
Dim oEmpBusObj as BusObject
Dim sLoginName as String
sLoginName = theApplication.LoginName
Set oEmpBusObj = theApplication.GetBusObject("Employee")
Set oEmpBusObj = Nothing
Version 6.0
3-249
Interfaces Reference
Miscellaneous Methods and Events
3-250
Version 6.0
Applet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-2
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-4
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-7
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-13
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-13
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-15
Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-17
Miscellaneous Interfaces and Events . . . . . . . . . . . . . . . . . . . . . . . . . A-18
Version 6.0
A-1
Applet
Table A-1.
Method
Description
Syntax
ActiveControl
Dim oApplet
Dim control
Set control
controlName
Calls an argument-specified
specialized method.
page 3-25
BusComp
page 3-26
BusObject
page 3-28
Drilldown
page 3-29
FindActiveXControl
page 3-31
FindControl
page 3-32
GotoControl
page 3-33
InvokeMethod
page 3-34
Name
page 3-36
PostChanges
page 3-37
A-2
as Applet
as Control
= oApplet.FindActiveXControl
as String
Version 6.0
Table A-2.
Event
Description
Syntax
Applet_ChangeRecord
Called when
the applet
gets the
focus.
Applet_GotFocus
Called when
applet.Invoke
Method is
called.
Applet_InvokeMethod(MethodName as String)
Called when
the applet
loses focus.
Applet_LostFocus
Called before
a specialized
method is
invoked.
Applet_PreInvokeMethod(MethodName as String)
page 3-39
Applet_InvokeMethod
page 3-42
Applet_Load
page 3-43
Applet_PreInvokeMethod
page 3-46
Version 6.0
A-3
Application
Table A-3.
(Sheet 1 of 3)
Method
Description
Syntax
ActiveApplet
page 3-48
ActiveBusComp
page 3-49
ActiveBusObject
page 3-50
ActiveControl
page 3-51
ActiveViewName
page 3-53
CurrencyCode
page 3-54
FindApplet
page 3-56
GetBusObject
page 3-57
GetProfileAttr
page 3-60
GetService
page 3-61
A-4
Version 6.0
Table A-3.
(Sheet 2 of 3)
Method
Description
Syntax
GetSharedGlobal
page 3-61
GotoApplet
page 3-63
GotoView
page 3-64
InputBox
page 3-66
InvokeMethod
page 3-68
LoginId
page 3-72
LoginName
page 3-73
MsgBox
page 3-75
NewPropertySet
page 3-78
PositionId
page 3-79
PositionName
page 3-80
Version 6.0
A-5
Table A-3.
(Sheet 3 of 3)
Method
Description
Syntax
SetProfileAttr
page 3-83
SetSharedGlobal
page 3-82
ShowStatus
page 3-84
Trace
page 3-85
TraceOff
page 3-87
TraceOn
page 3-88
Table A-4.
Event
Description
Syntax
Application_Close
Application_Close
Called after a
specialized method is
invoked.
Application_InvokeMethod(methodName as String)
Application_PreClose
Called before a
specialized method is
invoked.
Application_PreInvokeMethod(methodName as String)
Application_Start(commandLine as String)
page 3-91
Application_InvokeMethod
page 3-92
Application_PreClose
page 3-93
Application_PreInvokeMethod
page 3-94
Application_Start
page 3-96
A-6
Version 6.0
Business Component
Table A-5.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField
page 3-98
AllowNotification
page 3-100
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
FirstSelected
page 3-112
Version 6.0
A-7
Table A-5.
(Sheet 2 of 4)
Method
Description
Syntax
GetAssocBusComp
page 3-113
GetFieldValue
page 3-115
GetFormattedFieldValue
page 3-117
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetUserProperty
page 3-128
GetViewMode
page 3-129
A-8
Version 6.0
Table A-5.
(Sheet 3 of 4)
Method
Description
Syntax
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
NextSelected
page 3-137
ParentBusComp
page 3-138
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
Version 6.0
A-9
Table A-5.
(Sheet 4 of 4)
Method
Description
Syntax
SetFieldValue
page 3-143
SetFormattedFieldValue
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SetUserProperty
page 3-156
SuppressNotification
page 3-159
UndoRecord
page 3-160
WriteRecord
page 3-161
A-10
Version 6.0
Table A-6.
(Sheet 1 of 2)
Event
Description
Syntax
BusComp_Associate
Called to create an
association after a record is
added to a business
component.
BusComp_Associate
BusComp_ChangeRecord
BusComp_CopyRecord
BusComp_DeleteRecord
BusComp_InvokeMethod(methodName as String)
BusComp_NewRecord
BusComp_PreAssociate
BusComp_PreCopyRecord
BusComp_PreDeleteRecord
BusComp_PreGetFieldValue(FieldName as String,
FieldValue as String)
page 3-164
BusComp_ChangeRecord
page 3-165
BusComp_CopyRecord
page 3-167
BusComp_DeleteRecord
page 3-168
BusComp_InvokeMethod
page 3-169
BusComp_NewRecord
page 3-170
BusComp_PreAssociate
page 3-171
BusComp_PreCopyRecord
page 3-172
BusComp_PreDeleteRecord
page 3-173
BusComp_PreGetFieldValue
page 3-175
Version 6.0
A-11
Table A-6.
(Sheet 2 of 2)
Event
Description
Syntax
BusComp_PreInvokeMethod
BusComp_PreInvokeMethod(methodName as String,
Arguments as String or StringArray)
BusComp_PreNewRecord
BusComp_PreQuery
BusComp_PreSetFieldValue(FieldName as
String,FieldValue as String)
BusComp_PreWriteRecord
BusComp_Query
BusComp_SetFieldValue(fieldName as String)
BusComp_WriteRecord
page 3-176
BusComp_PreNewRecord
page 3-177
BusComp_PreQuery
page 3-178
BusComp_PreSetFieldValue
page 3-179
BusComp_PreWriteRecord
page 3-181
BusComp_Query
page 3-182
BusComp_SetFieldValue
page 3-184
BusComp_WriteRecord
page 3-185
A-12
Version 6.0
Business Object
Table A-7.
Method
Description
Syntax
GetBusComp
page 3-186
Name
page 3-189
Business Service
Table A-8.
(Sheet 1 of 2)
Method
Description
Syntax
GetFirstProperty
Calls a specialized
method or a usercreated method on
the business
service.
page 3-211
GetNextProperty
page 3-191
GetProperty
page 3-192
InvokeMethod
page 3-193
Name
page 3-195
Version 6.0
A-13
Table A-8.
(Sheet 2 of 2)
Method
Description
Syntax
PropertyExists
Returns a Boolean
value indicating
whether the
property specified
in the argument
exists.
Removes a
property from a
business service.
Assigns a value to a
property of a
business service.
page 3-196
RemoveProperty
page 3-197
SetProperty
page 3-198
Table A-9.
Method
Description
Syntax
Service_InvokeMethod
Called when
a business
service is
accessed.
Service_InvokeMethod(methodName as String)
Called before
a specialized
method is
invoked on a
business
service.
Service_PreInvokeMethod(methodName as
String, Inputs as PropertySet, Outputs as
PropertySet)
page 3-199
Service_PreInvokeMethod
page 3-200
A-14
Version 6.0
Property Set
Table A-10.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild
Adds subsidiary
property sets to a
property set.
Returns a copy of a
property set.
Returns a specified
child property set of
a property set.
Returns a value
stored as part of a
property set.
Inserts a child
property set into a
parent property set
at a specific
location.
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
Version 6.0
A-15
Table A-10.
(Sheet 2 of 2)
Method
Description
Syntax
PropertyExists
Returns a Boolean
value indicating
whether the
property specified in
the argument exists.
Removes a child
property set as a
specified index from
a parent property
set.
Removes the
property specified in
its argument from a
property set.
Removes all
properties and child
property sets from a
property set.
Assigns a value to
the property of a
property set
specified in its
argument.
page 3-217
RemoveChild
page 3-218
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
A-16
Version 6.0
Control
Table A-11.
Method
Description
Syntax
Applet
page 3-224
BusComp
page 3-225
BusObject
page 3-226
GetProperty
page 3-227
GetValue
page 3-229
Name
page 3-230
SetProperty
page 3-231
SetValue
page 3-233
Version 6.0
A-17
Method
Description
Syntax
theApplication
TheApplication.Application_method
page 3-249
Table A-13.
Method
Description
Syntax
ControlName_Click
Control_Name_Click
page 3-247
A-18
Version 6.0
Applet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-2
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-3
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-6
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-10
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-10
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-11
Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-13
Version 6.0
B-1
Applet
Table B-1.
Method
Description
Syntax
ActiveControl
Calls a specialized
method whose name is
specified in the argument.
page 3-25
BusComp
page 3-26
BusObject
page 3-28
Drilldown
page 3-29
FindActiveXControl
page 3-31
FindControl
page 3-32
GotoControl
page 3-33
InvokeMethod
page 3-34
Name
page 3-36
PostChanges
page 3-37
B-2
Version 6.0
Application
Table B-2.
(Sheet 1 of 3)
Method
Description
Syntax
ActiveApplet
Instantiates and
returns a new
instance of the
business object
specified in the
argument.
page 3-48
ActiveBusComp
page 3-49
ActiveBusObject
page 3-50
ActiveControl
page 3-51
ActiveViewName
page 3-53
CurrencyCode
page 3-54
FindApplet
page 3-56
GetBusObject
page 3-57
GetLastErrText
page 3-59
GetLastErrCode
page 3-58
Version 6.0
B-3
Table B-2.
(Sheet 2 of 3)
Method
Description
Syntax
GetProfileAttr
Instantiates and
returns a new
instance of the
argument-specified
service.
Allows external
applications to log in
to the COM Data
Server.
Constructs a new
property set object.
page 3-60
GetService
page 3-61
GotoApplet
page 3-63
GotoView
page 3-64
InvokeMethod
page 3-68
Login
page 3-70
LoginId
page 3-72
LoginName
page 3-73
NewPropertySet
page 3-78
PositionId
page 3-79
B-4
Version 6.0
Table B-2.
(Sheet 3 of 3)
Method
Description
Syntax
PositionName
Used in
personalization to
assign values to
attributes in a user
profile.
Displays a message
in the status bar.
Appends a message
to the trace file.
page 3-80
SetProfileAttr
page 3-83
SetSharedGlobal
page 3-82
ShowStatus
page 3-84
Trace
page 3-85
TraceOff
page 3-87
TraceOn
page 3-88
Version 6.0
B-5
Business Component
Table B-3.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField
Allows queries to
retrieve data for the
specified field.
Deactivates all
currently activated
fields.
Fetches a set of
BusComp records.
Fetches a set of
BusComp records.
page 3-98
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
FirstSelected
page 3-112
B-6
Version 6.0
Table B-3.
(Sheet 2 of 4)
Method
Description
Syntax
GetAssocBusComp
Returns a formatted
value for the field
specified in the
argument.
page 3-113
GetFieldValue
page 3-115
GetFormattedFieldValue
page 3-117
GetLastErrText
page 3-120
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetUserProperty
page 3-128
Version 6.0
B-7
Table B-3.
(Sheet 3 of 4)
Method
Description
Syntax
GetViewMode
page 3-129
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
NextSelected
page 3-137
ParentBusComp
page 3-138
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
B-8
Version 6.0
Table B-3.
(Sheet 4 of 4)
Method
Description
Syntax
SetFieldValue
Deletes an active
record created by
NewRecord.
Commits to the
database any changes
made to the current
record.
page 3-143
SetFormattedFieldValue
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SetUserProperty
page 3-156
SuppressNotification
page 3-159
UndoRecord
page 3-160
WriteRecord
page 3-161
Version 6.0
B-9
Business Object
Table B-4.
Method
Description
Syntax
GetBusComp
Returns the
specified
business
component.
Returns the
name of the
business object.
page 3-186
Name
page 3-189
Business Service
Table B-5.
(Sheet 1 of 2)
Method
Description
Syntax
GetFirstProperty
Calls a specialized
method or a user-created
method on the business
service.
page 3-211
GetNextProperty
page 3-191
GetProperty
page 3-192
InvokeMethod
page 3-193
Name
page 3-195
B-10
Version 6.0
Table B-5.
(Sheet 2 of 2)
Method
Description
Syntax
PropertyExists
Assigns a value to a
property of a business
service.
page 3-217
RemoveProperty
page 3-197
SetProperty
page 3-198
Property Set
Table B-6.
(Sheet 1 of 3)
Method
Description
Syntax
AddChild
Returns a copy of a
property set.
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
Version 6.0
B-11
Table B-6.
(Sheet 2 of 3)
Method
Description
Syntax
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
RemoveChild
page 3-218
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
B-12
Version 6.0
Table B-6.
(Sheet 3 of 3)
Method
Description
Syntax
SetType
page 3-222
SetValue
page 3-223
Control
Table B-7.
Method
Description
Syntax
Applet
page 3-224
BusComp
page 3-225
BusObject
page 3-226
GetProperty
page 3-227
GetValue
page 3-229
Name
page 3-230
SetProperty
page 3-231
SetValue
page 3-233
Version 6.0
B-13
B-14
Version 6.0
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .C-2
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .C-4
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .C-8
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .C-8
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .C-9
Version 6.0
C-1
Application
Table C-1.
(Sheet 1 of 2)
Method
Description
Syntax
CurrencyCode
Allows external
applications to log in to
the COM Data Server.
page 3-54
GetBusObject
page 3-57
GetLastErrText
page 3-59
GetProfileAttr
page 3-60
GetService
page 3-61
GetSharedGlobal
page 3-62
InvokeMethod
page 3-68
LoadObjects
page 3-69
Login
page 3-70
LoginId
page 3-72
C- 2
Version 6.0
Table C-1.
(Sheet 2 of 2)
Method
Description
Syntax
LoginName
Used in personalization
to assign values to
attributes in a user
profile.
page 3-73
NewPropertySet
page 3-78
PositionId
page 3-79
PositionName
page 3-80
SetProfileAttr
page 3-83
SetSharedGlobal
page 3-82
Trace
page 3-85
TraceOff
page 3-87
TraceOn
page 3-88
Version 6.0
C-3
Business Component
Table C-2.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField
Allows queries to
retrieve data for the
specified field.
Deactivates all
currently activated
fields.
Fetches a set of
BusComp records.
Fetches a set of
BusComp records.
Returns the
association business
component.
page 3-98
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
GetAssocBusComp
page 3-113
C- 4
Version 6.0
Table C-2.
(Sheet 2 of 4)
Method
Description
Syntax
GetFieldValue
Returns a formatted
value for the field
specified in the
argument.
Returns the
argument-named
search specification.
page 3-115
GetFormattedFieldValue
page 3-117
GetLastErrText
page 3-120
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetUserProperty
page 3-128
GetViewMode
page 3-129
Version 6.0
C-5
Table C-2.
(Sheet 3 of 4)
Method
Description
Syntax
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
ParentBusComp
page 3-138
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
SetFieldValue
page 3-143
C- 6
Version 6.0
Table C-2.
(Sheet 4 of 4)
Method
Description
Syntax
SetFormattedFieldValue
Deletes an active
record created by
NewRecord.
Commits to the
database any changes
made to the current
record.
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SetUserProperty
page 3-156
UndoRecord
page 3-160
WriteRecord
page 3-161
Version 6.0
C-7
Business Object
Table C-3.
Method
Description
Syntax
GetBusComp
Returns the
specified business
component.
page 3-186
Name
page 3-189
Business Service
Table C-4.
(Sheet 1 of 2)
Method
Description
Syntax
GetFirstProperty
page 3-211
GetNextProperty
page 3-191
GetProperty
page 3-192
Name
page 3-195
InvokeMethod
page 3-193
C- 8
Version 6.0
Table C-4.
(Sheet 2 of 2)
Method
Description
Syntax
PropertyExists
page 3-217
RemoveProperty
page 3-197
SetProperty
page 3-198
Property Set
Table C-5.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
Version 6.0
C-9
Table C-5.
(Sheet 2 of 2)
Method
Description
Syntax
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
RemoveChild
page 3-218
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
C- 1 0
Version 6.0
Applet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-2
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-3
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-5
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-9
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-10
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-11
Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . D-13
Version 6.0
D-1
Applet
Table D-1.
Method
Description
Syntax
ActiveControl
Calls an argument-specified
specialized method.
page 3-25
BusComp
page 3-26
BusObject
page 3-28
Drilldown
page 3-29
FindControl
page 3-32
GotoControl
page 3-33
InvokeMethod
page 3-34
Name
page 3-36
PostChanges
page 3-37
D-2
Version 6.0
Application
Table D-2.
(Sheet 1 of 2)
Method
Description
Syntax
ActiveApplet
page 3-48
ActiveBusComp
page 3-49
ActiveBusObject
page 3-50
ActiveControl
page 3-51
ActiveViewName
page 3-53
CurrencyCode
page 3-54
EnableExceptions
page 3-55
FindApplet
page 3-56
GetBusObject
page 3-57
GetLastErrCode
page 3-58
GetLastErrText
page 3-59
GetProfileAttr
page 3-60
Version 6.0
D-3
Table D-2.
(Sheet 2 of 2)
Method
Description
Syntax
GetService
page 3-61
GotoApplet
page 3-63
GotoView
page 3-64
InvokeMethod
page 3-68
Login
page 3-70
LoginId
page 3-72
LoginName
page 3-73
Logoff
page 3-74
NewPropertySet
page 3-78
PositionId
page 3-79
PositionName
page 3-80
SetProfileAttr
page 3-83
ShowStatus
page 3-84
D-4
Version 6.0
Business Component
Table D-3.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField
Allows queries to
retrieve data for the
specified field.
Deactivates all
currently activated
fields.
Fetches a set of
BusComp records.
Fetches a set of
BusComp records.
page 3-98
AllowNotification
page 3-100
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
Version 6.0
D-5
Table D-3.
(Sheet 2 of 4)
Method
Description
Syntax
GetAssocBusComp
Returns the
association business
component.
Returns a formatted
value for the field
specified in the
argument.
page 3-113
GetFieldValue
page 3-115
GetFormattedFieldValue
page 3-117
GetLastErrText
page 3-120
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetViewMode
page 3-129
D-6
Version 6.0
Table D-3.
(Sheet 3 of 4)
Method
Description
Syntax
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
ParentBusComp
page 3-138
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
SetFieldValue
page 3-143
Version 6.0
D-7
Table D-3.
(Sheet 4 of 4)
Method
Description
Syntax
SetFormattedFieldValue
Deletes an active
record created by
NewRecord.
Commits to the
database any changes
made to the current
record.
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SuppressNotification
page 3-159
UndoRecord
page 3-160
WriteRecord
page 3-161
D-8
Version 6.0
Business Object
Table D-4.
Method
Description
Syntax
GetBusComp
Returns the
specified business
component.
page 3-186
GetLastErrCode
page 3-187
GetLastErrText
page 3-188
Name
page 3-189
Version 6.0
D-9
Business Service
Table D-5.
Method
Description
Syntax
GetFirstProperty
page 3-211
GetNextProperty
page 3-191
GetProperty
page 3-192
InvokeMethod
page 3-193
Name
page 3-195
PropertyExists
page 3-217
RemoveProperty
page 3-197
SetProperty
page 3-198
D-10
Version 6.0
Property Set
Table D-6.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
Version 6.0
D-11
Table D-6.
(Sheet 2 of 2)
Method
Description
Syntax
RemoveChild
page 3-218
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
D-12
Version 6.0
Control
Table D-7.
Method
Description
Syntax
Applet
Returns the
corresponding business
component for the
control.
Returns the
corresponding business
object for the control.
page 3-224
BusComp
page 3-225
BusObject
page 3-226
GetProperty
page 3-227
GetValue
page 3-229
Name
page 3-230
SetProperty
page 3-231
SetValue
page 3-233
Version 6.0
D-13
D-14
Version 6.0
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . E-2
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . E-4
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . E-8
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . E-9
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . E-10
Version 6.0
E-1
Application
Table E-1.
(Sheet 1 of 2)
Method
Description
Syntax
CurrencyCode
Enables/disables native
COM error handling.
page 3-57
GetLastErrCode
page 3-54
EnableExceptions
page 3-55
GetBusObject
page 3-58
GetLastErrText
page 3-59
GetProfileAttr
page 3-60
GetService
page 3-61
InvokeMethod
page 3-68
Login
page 3-70
LoginId
page 3-72
LoginName
page 3-73
E-2
Version 6.0
Table E-1.
(Sheet 2 of 2)
Method
Description
Syntax
NewPropertySet
Used in personalization to
assign values to attributes in
a user profile.
page 3-78
PositionId
page 3-79
PositionName
page 3-80
SetProfileAttr
page 3-83
Version 6.0
E-3
Business Component
Table E-2.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField
Allows queries to
retrieve data for the
specified field.
Deactivates all
currently activated
fields.
Fetches a set of
BusComp records.
Fetches a set of
BusComp records.
Returns the
association business
component.
page 3-98
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
GetAssocBusComp
page 3-113
E-4
Version 6.0
Table E-2.
(Sheet 2 of 4)
Method
Description
Syntax
GetFieldValue
Returns a formatted
value for the field
specified in the
argument.
Returns the
argument-named
search specification.
page 3-115
GetFormattedFieldValue
page 3-117
GetLastErrText
page 3-120
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetViewMode
page 3-129
InvokeMethod
page 3-130
Version 6.0
E-5
Table E-2.
(Sheet 3 of 4)
Method
Description
Syntax
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
ParentBusComp
page 3-138
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
SetFieldValue
page 3-143
SetFormattedFieldValue
page 3-145
E-6
Version 6.0
Table E-2.
(Sheet 4 of 4)
Method
Description
Syntax
SetNamedSearch
Deletes an active
record created by
NewRecord.
Commits to the
database any changes
made to the current
record.
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SuppressNotification
page 3-159
UndoRecord
page 3-160
WriteRecord
page 3-161
Version 6.0
E-7
Business Object
Table E-3.
Method
Description
Syntax
GetBusComp
page 3-186
GetLastErrCode
page 3-187
GetLastErrText
page 3-188
Name
page 3-189
E-8
Version 6.0
Business Service
Table E-4.
Method
Description
Syntax
GetFirstProperty
page 3-190
GetNextProperty
page 3-191
GetProperty
page 3-192
Name
page 3-195
InvokeMethod
page 3-193
PropertyExists
page 3-217
RemoveProperty
page 3-197
SetProperty
page 3-198
Version 6.0
E-9
Property Set
Table E-5.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
E-10
Version 6.0
Table E-5.
(Sheet 2 of 2)
Method
Description
Syntax
RemoveChild
page 3-218
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
Version 6.0
E-11
E-12
Version 6.0
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-2
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-4
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-7
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-7
Property Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-8
SiebelAppFactory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . F-9
Version 6.0
F-1
Application
Table F-1.
(Sheet 1 of 2)
Method
Description
IDL
CurrencyCode
page 3-54
GetBusObject
page 3-57
GetLastErrText
page 3-59
GetProfileAttr
page 3-60
GetSharedGlobal
page 3-62
GetService
page 3-61
InvokeMethod
page 3-68
Login
page 3-70
LoginId
page 3-72
LoginName
page 3-73
Logoff
page 3-74
PositionId
page 3-79
F-2
Version 6.0
Table F-1.
(Sheet 2 of 2)
Method
Description
IDL
NewPropertySet
page 3-78
PositionName
page 3-80
SetProfileAttr
page 3-83
SetSharedGlobal
page 3-82
Trace
page 3-85
TraceOff
page 3-87
TraceOn
page 3-88
Version 6.0
F-3
Business Component
Table F-2.
Method
Description
IDL
ActivateField
page 3-98
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
GetAssocBusComp
page 3-113
GetFieldValue
page 3-115
GetFormattedFieldValue
page 3-117
F-4
(Sheet 1 of 3)
Version 6.0
Table F-2.
Method
Description
IDL
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetUserProperty
page 3-128
GetViewMode
page 3-129
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
ParentBusComp
page 3-138
Version 6.0
(Sheet 2 of 3)
F-5
Table F-2.
Method
Description
IDL
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
SetFieldValue
page 3-143
SetFormattedFieldValue
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SetUserProperty
page 3-156
SetViewMode
page 3-157
UndoRecord
page 3-160
WriteRecord
page 3-161
F-6
(Sheet 3 of 3)
Version 6.0
Business Object
Table F-3.
Method
Description
IDL
GetBusComp
page 3-186
Name
page 3-189
Business Service
Table F-4.
Method
Description
IDL
GetFirstProperty
string
string
page 3-211
GetNextProperty
page 3-191
GetProperty
page 3-192
Name
page 3-195
InvokeMethod
page 3-193
PropertyExists
page 3-217
RemoveProperty
page 3-197
SetProperty
page 3-198
Version 6.0
F-7
Property Set
Table F-5.
(Sheet 1 of 2)
Method
Description
IDL
AddChild
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
RemoveChild
page 3-218
F-8
Version 6.0
Table F-5.
(Sheet 2 of 2)
Method
Description
IDL
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
SiebelAppFactory
Table F-6.
Method
Description
IDL
CreateSiebelAppObject
Returns a CORBA
object reference
for an application
object.
SiebelApplication CreatSiebelAppObject()
raises (SiebelException);
page 3-245
Version 6.0
F-9
F-1 0
Version 6.0
Applet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-2
Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-3
Business Component . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-6
Business Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-11
Business Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-11
PropertySet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-13
Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . G-14
Miscellaneous Interfaces and Events . . . . . . . . . . . . . . . . . . . . . . . . . G-15
Version 6.0
G-1
Applet
Table G-1.
Method
Description
Syntax
ActiveControl()
var applet;
var control;
control = applet.ActiveControl();
var applet;
var myBusComp;
busComp = applet.myBusComp();
var applet;
var busObject;
busObject = applet.BusObject();
var applet;
applet.Drilldown(drilldown_object);
var applet;
var control;
control = applet.FindControl(controlName);
var applet;
applet.GotoControl(controlObj);
Calls an argument-specified
specialized method.
var applet;
applet.InvokeMethod(methodName, methodArg1,
methodArg2, ..., methodArgn);
var applet;
var sApplet;
sApplet = applet.Name();
var applet;
var bSuccess;
iReturn = applet.PostChanges();
page 3-25
BusComp()
page 3-26
BusObject()
page 3-28
Drilldown()
page 3-29
FindControl()
page 3-32
GotoControl()
page 3-33
InvokeMethod()
page 3-34
Name()
page 3-36
PostChanges()
page 3-37
G-2
Version 6.0
Table G-2.
Event
Description
Syntax
Applet_ChangeRecord()
Applet_GotFocus();
Called when
applet.InvokeMethod
is called.
Applet_InvokeMethod(MethodName);
Applet_LostFocus();
Called before a
specialized method is
invoked.
Applet_PreInvokeMethod(MethodName);
page 3-39
Applet_InvokeMethod()
page 3-42
Applet_Load()
page 3-43
Applet_PreInvokeMethod()
page 3-46
Application
Table G-3.
(Sheet 1 of 3)
Method
Description
Syntax
ActiveApplet()
var applet;
applet = TheApplication().ActiveApplet();
var busComp;
busComp = TheApplication().ActiveBusComp();
var busObject;
busObject = TheApplication().ActiveBusObject();
var control;
control = TheApplication().ActiveControl();
var sView;
sView = TheApplication().ActiveViewName();
var sCur;
sCur = TheApplication().CurrencyCode();
page 3-48
ActiveBusComp()
page 3-49
ActiveBusObject()
page 3-50
ActiveControl()
page 3-51
ActiveViewName()
page 3-53
CurrencyCode()
page 3-54
Version 6.0
G-3
Table G-3.
(Sheet 2 of 3)
Method
Description
Syntax
FindApplet()
var applet;
applet = TheApplication().FindApplet(appletName);
var myBusObject;
myBusObject = TheApplication().GetBusObject(BusObject);
var sAttr;
sAttr = TheApplication.()GetProfileAttr(name);
var Service;
Service = TheApplication().GetService(serviceName);
var sName;
sName = TheApplication().GetSharedGlobal(varName);
TheApplication().GotoApplet(appletObj);
TheApplication().GotoView(viewName,[
BusinessObjectName]);
TheApplication.InputBox(prompt
[,title][,default][,xpos][,ypos];
var sReturn;
sReturn = TheApplication().InvokeMethod(methodName,
methodArg1, methodArg2,..., methodArgn);
var sID;
sID = TheApplication().LoginId();
var sUser;
sUser = TheApplication().LoginName();
var iResponse;
iResponse = TheApplication().MsgBox(prompt[, buttons][,
title]);
var oPropSet;
oPropSet = TheApplication().NewPropertySet();
var sRow;
sRow = TheApplication().PositionId();
page 3-56
GetBusObject()
page 3-57
GetProfileAttr
page 3-60
GetService()
page 3-61
GetSharedGlobal()
page 3-62
GotoApplet()
page 3-63
GotoView()
page 3-64
InputBox()
page 3-66
InvokeMethod()
page 3-68
LoginId()
page 3-72
LoginName()
page 3-73
MsgBox()
page 3-75
NewPropertySet()
page 3-78
PositionId()
page 3-79
G-4
Version 6.0
Table G-3.
(Sheet 3 of 3)
Method
Description
Syntax
PositionName()
var sPosition;
sPosition = TheApplication().PositionName();
Used in personalization to
assign values to attributes
in a user profile.
TheApplication().SetProfileAttr(name, value);
TheApplication().SetSharedGlobal(varName, value);
TheApplication().ShowStatus(message);
TheApplication().Trace(message);
TheApplication().TraceOff();
page 3-80
SetProfileAttr
page 3-83
SetSharedGlobal()
page 3-82
ShowStatus()
page 3-84
Trace()
page 3-85
TraceOff()
page 3-87
TraceOn()
page 3-88
Table G-4.
Event
Description
Syntax
Application_Close()
Application_Close();
Application_InvokeMethod(methodName);
Application_PreClose();
Application_PreInvokeMethod(methodName);
Application_Start(commandLine);
page 3-91
Application_InvokeMethod()
page 3-92
Application_PreClose()
page 3-93
Application_PreInvokeMethod()
page 3-94
Application_Start()
page 3-96
Version 6.0
G-5
Business Component
Table G-5.
(Sheet 1 of 4)
Method
Description
Syntax
ActivateField()
var myBusComp;
myBusComp.ActivateField(fieldName);
var myBusComp;
myBusComp.AllowNotification();
var myBusComp;
myBusComp.Associate(whereIndicator);
var myBusComp;
var busObject;
busObject = myBusComp.BusObject();
var myBusComp;
myBusComp.ClearToQuery();
var myBusComp;
myBusComp.DeactivateFields();
var myBusComp;
myBusComp.DeleteRecord()
var myBusComp;
myBusComp.ExecuteQuery(cursorMode);
var myBusComp;
myBusComp.ExecuteQuery2(cursorMode,
ignoreMaxCursorSize);
var myBusComp;
var bIsRecord;
bIsRecord = myBusComp.FirstRecord();
var myBusComp;
var bIsMultipleSelection;
bIsMultipleSelection =
myBusComp.FirstSelected();
var myBusComp;
var AssocBusComp;
AssocBusComp = myBusComp.GetAssocBusComp();
page 3-98
AllowNotification()
page 3-100
Associate()
page 3-101
BusObject()
page 3-103
ClearToQuery()
page 3-104
DeactivateFields()
page 3-105
DeleteRecord()
page 3-106
ExecuteQuery()
page 3-107
ExecuteQuery2()
page 3-110
FirstRecord()
page 3-111
FirstSelected()
page 3-112
GetAssocBusComp()
page 3-113
G-6
Version 6.0
Table G-5.
(Sheet 2 of 4)
Method
Description
Syntax
GetFieldValue()
var myBusComp;
var sValue
sValue = myBusComp.GetFieldValue(FieldName);
var myBusComp;
var sValue;
sValue =
myBusComp.GetFormattedFieldValue(FieldName);
var myBusComp;
var MvgBusComp;
MvgBusComp=
myBusComp.GetMVGBusComp(FieldName);
var myBusComp;
var sValue;
sValue = myBusComp.GetNamedSearch(SearchName);
var myBusComp;
var pickBusComp;
pickBusComp =
myBusComp.GetPicklistBusComp(FieldName);
var myBusComp;
var sExpr;
sExpr = myBusComp.GetSearchExpr()
var myBusComp;
var sSpec;
sSpec = myBusComp.GetSearchSpec(FieldName);
var myBusComp;
var sValue;
sValue =
myBusComp.GetUserProperty(propertyName);
var myBusComp;
var iMode;
iMode = myBusComp.GetViewMode();
var myBusComp;
var sReturn;
sReturn = myBusComp.InvokeMethod(methodName,
methodArg1, methodArg2,..., methodArgn);
var myBusComp;
var iReturn;
iReturn = myBusComp.LastRecord();
var myBusComp;
var sName;
sName = myBusComp.Name();
page 3-115
GetFormattedFieldValue()
page 3-117
GetMVGBusComp()
page 3-121
GetNamedSearch()
page 3-123
GetPicklistBusComp()
page 3-124
GetSearchExpr()
page 3-126
GetSearchSpec()
page 3-127
GetUserProperty()
page 3-128
GetViewMode()
page 3-129
InvokeMethod()
page 3-130
LastRecord()
page 3-132
Name()
page 3-133
Version 6.0
G-7
Table G-5.
(Sheet 3 of 4)
Method
Description
Syntax
NewRecord()
var myBusComp;
myBusComp.NewRecord(whereIndicator);
var myBusComp;
var bFound;
bFound = myBusComp.NextRecord();
var myBusComp;
var iReturn;
iReturn = myBusComp.NextSelected();
var myBusComp;
var parentBusComp;
parentBusComp = myBusComp.ParentBusComp();
var myBusComp;
myBusComp.Pick();
var myBusComp;
var iReturn;
iReturn = myBusComp.PreviousRecord();
var myBusComp;
myBusComp.RefineQuery();
var myBusComp;
myBusComp.SetFieldValue(FieldName,
FieldValue);
var myBusComp;
myBusComp.SetFormattedFieldValue(FieldName,
FieldValue);
var myBusComp;
myBusComp.SetNamedSearch(searchName,
searchSpec);
var myBusComp;
myBusComp.SetSearchExpr(searchSpec);
var myBusComp;
myBusComp.SetSearchSpec(FieldName,
searchSpec);
var myBusComp;
myBusComp.SetSortSpec(sortSpec);
page 3-134
NextRecord()
page 3-136
NextSelected()
page 3-137
ParentBusComp()
page 3-138
Pick()
page 3-139
PreviousRecord()
page 3-141
RefineQuery()
page 3-142
SetFieldValue()
page 3-143
SetFormattedFieldValue()
page 3-145
SetNamedSearch()
page 3-147
SetSearchExpr()
page 3-148
SetSearchSpec()
page 3-150
SetSortSpec()
page 3-154
G-8
Version 6.0
Table G-5.
(Sheet 4 of 4)
Method
Description
Syntax
SetUserProperty()
var myBusComp;
myBusComp.SetUserProperty(propertyName,
newValue);
var myBusComp;
myBusComp.SuppressNotification();
var myBusComp;
myBusComp.UndoRecord();
var myBusComp;
myBusComp.WriteRecord();
page 3-156
SuppressNotification()
page 3-159
UndoRecord()
page 3-160
WriteRecord()
page 3-161
Table G-6.
(Sheet 1 of 2)
Event
Description
Syntax
BusComp_Associate()
BusComp_Associate();
BusComp_ChangeRecord();
BusComp_CopyRecord();
BusComp_DeleteRecord();
BusComp_InvokeMethod(methodName,methodArg1,
methodArg2,..., methodArgn);
BusComp_NewRecord();
BusComp_PreAssociate();
page 3-164
BusComp_ChangeRecord()
page 3-165
BusComp_CopyRecord()
page 3-167
BusComp_DeleteRecord()
page 3-168
BusComp_InvokeMethod()
page 3-169
BusComp_NewRecord()
page 3-170
BusComp_PreAssociate()
page 3-171
Version 6.0
G-9
Table G-6.
(Sheet 2 of 2)
Event
Description
Syntax
BusComp_PreCopyRecord()
BusComp_PreCopyRecord();
BusComp_PreDeleteRecord();
BusComp_PreGetFieldValue(FieldName,
&FieldValue);
BusComp_PreInvokeMethod(methodName);
BusComp_PreNewRecord();
BusComp_PreQuery();
BusComp_PreSetFieldValue(FieldName,
FieldValue);
BusComp_PreWriteRecord();
BusComp_Query();
BusComp_SetFieldValue(FieldName);
BusComp_WriteRecord();
page 3-172
BusComp_PreDeleteRecord()
page 3-173
BusComp_PreGetFieldValue()
page 3-175
BusComp_PreInvokeMethod()
page 3-176
BusComp_PreNewRecord()
page 3-177
BusComp_PreQuery()
page 3-178
BusComp_PreSetFieldValue()
page 3-179
BusComp_PreWriteRecord()
page 3-181
BusComp_Query()
page 3-182
BusComp_SetFieldValue()
page 3-184
BusComp_WriteRecord()
page 3-185
G-10
Version 6.0
Business Object
Table G-7.
Method
Description
Syntax
GetBusComp()
var myBusObject;
var myBusComp;
myBusComp =
myBusObject.GetBusComp(BusCompName);
page 3-186
Name()
page 3-189
Business Service
Table G-8.
(Sheet 1 of 2)
Method
Description
Syntax
GetFirstProperty()
var oService;
var sName;sName = oService.GetFirstProperty();
var oService;
var sName;
sName = oService.GetNextProperty();
var oService;
var sValue;
sValue = oService.GetProperty(propName);
var oService;
var sName;
sName = oService.Name();
var oService;
var Return;
Return = oService.InvokeMethod(methodName,
InputArguments, OutputArguments);
var oService;
oService.PropertyExists(propName);
page 3-190
GetNextProperty()
page 3-191
GetProperty()
page 3-192
Name
page 3-195
InvokeMethod()
page 3-193
PropertyExists()
page 3-196
Version 6.0
G-11
Table G-8.
(Sheet 2 of 2)
Method
Description
Syntax
RemoveProperty()
var oService;
oService.RemoveProperty(propName);
var oService;
oService.SetProperty(propName, propValue);
page 3-197
SetProperty()
page 3-198
Table G-9.
Method
Description
Syntax
Service_InvokeMethod()
Called when a
business service is
accessed.
Service_InvokeMethod(methodName);
Called before a
specialized method
is invoked on a
business service.
page 3-199
Service_PreInvokeMethod()
page 3-200
G-12
Version 6.0
PropertySet
Table G-10.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild()
var oPropSet;
var iIndex;
oPropSet.AddChild(childObject);
var oPropSet1;
var oPropSet2;
oPropSet2 = oPropSet1.Copy();
var oPropSet;
var sPropVal;
sPropVal = oPropSet.GetChild(index);
var oPropSet;
var iCount;
iCount = oPropSet.GetChildCount();
var oPropSet;
var sPropName
sPropName = oPropSet.GetFirstProperty()
var oPropSet;
var sPropName
sPropName = oPropSet.GetNextProperty()
var oPropSet;
var sPropVal
sPropVal = oPropSet.GetProperty(propName)
var oPropSet;
var sTypeVal
sTypeVal = oPropSet.GetType(value)
var oPropSet;
var sValVal;
sValVal = oPropSet.GetValue(value);
var oPropSet;
oPropSet.InsertChildAt(childObject, index);
var oPropSet;
oPropSet.PropertyExists(propName);
var oPropSet;
oPropSet.RemoveChild(index);
page 3-204
Copy()
page 3-206
GetChild()
page 3-208
GetChildCount()
page 3-210
GetFirstProperty()
page 3-211
GetNextProperty()
page 3-212
GetProperty()
page 3-213
GetType()
page 3-214
GetValue()
page 3-215
InsertChildAt()
page 3-216
PropertyExists()
page 3-217
RemoveChild()
page 3-218
Version 6.0
G-13
Table G-10.
(Sheet 2 of 2)
Method
Description
Syntax
RemoveProperty()
var oPropSet;
oPropSet.RemoveProperty(propName);
var oPropSet;
oPropSet.Reset();
var oPropSet;
oPropSet.SetProperty propName , propValue
var oPropSet;
oPropSet.SetType(value);
var oPropSet;
oPropSet.SetValue(value);
page 3-219
Reset()
page 3-220
SetProperty()
page 3-221
SetType()
page 3-222
SetValue()
page 3-223
Control
Table G-11.
(Sheet 1 of 2)
Method
Description
Syntax
Applet()
var myControl;
var applet;
applet = myControl().Applet();
var myControl;
var myBusComp(
myBusComp = myControl.BusComp();
var myControl;
var myBusObject;
myBusObject = myControl.BusObject();
var control;
control.GetProperty(propName);
var myControl;
var sValue
sValue = myControl.GetValue()
var myControl;
var sName;
sName = myControl.Name();
page 3-224
BusComp()
page 3-225
BusObject()
page 3-226
GetProperty
page 3-227
GetValue()
page 3-229
Name()
page 3-230
G-14
Version 6.0
Table G-11.
(Sheet 2 of 2)
Method
Description
Syntax
SetProperty
Dim control;
control.SetProperty(propName, propValue);
var myControl;
myControl.SetValue(controlValue);
page 3-231
SetValue()
page 3-233
Method
Description
Syntax
theApplication()
TheApplication().Application_method;
page 3-249
Table G-13.
Method
Description
Syntax
ControlName_Click()
ControlName_Click();
page 3-247
Version 6.0
G-15
G-16
Version 6.0
Version 6.0
H-1
Data Bean
Table H-1.
Method
Description
Syntax
CurrencyCode
page 3-54
GetBusObject
page 3-57
GetService
page 3-61
InvokeMethod
page 3-68
Login
page 3-70
LoginId
page 3-72
LoginName
page 3-73
Logoff
page 3-74
NewPropertySet
page 3-78
PositionId
page 3-79
PositionName
page 3-80
H- 2
Version 6.0
Business Component
Table H-2.
(Sheet 1 of 3)
Method
Description
Syntax
ActivateField
page 3-98
AllowNotification
page 3-100
Associate
page 3-101
BusObject
page 3-103
ClearToQuery
page 3-104
DeactivateFields
page 3-105
DeleteRecord
page 3-106
ExecuteQuery
page 3-107
ExecuteQuery2
page 3-110
FirstRecord
page 3-111
GetAssocBusComp
page 3-113
GetFieldValue
page 3-115
GetFormattedFieldValue
page 3-117
Version 6.0
H-3
Table H-2.
(Sheet 2 of 3)
Method
Description
Syntax
GetMVGBusComp
page 3-121
GetNamedSearch
page 3-123
GetPicklistBusComp
page 3-124
GetSearchExpr
page 3-126
GetSearchSpec
page 3-127
GetUserProperty
page 3-128
GetViewMode
page 3-129
InvokeMethod
page 3-130
LastRecord
page 3-132
Name
page 3-133
NewRecord
page 3-134
NextRecord
page 3-136
ParentBusComp
page 3-138
H- 4
Version 6.0
Table H-2.
(Sheet 3 of 3)
Method
Description
Syntax
Pick
page 3-139
PreviousRecord
page 3-141
RefineQuery
page 3-142
SetFieldValue
page 3-143
SetFormattedFieldValue
page 3-145
SetNamedSearch
page 3-147
SetSearchExpr
page 3-148
SetSearchSpec
page 3-150
SetSortSpec
page 3-154
SetViewMode
page 3-157
SuppressNotification
page 3-159
UndoRecord
page 3-160
WriteRecord
page 3-161
Version 6.0
H-5
Business Object
Table H-3.
Method
Description
Syntax
GetBusComp
page 3-186
Name
page 3-189
Business Service
Table H-4.
Method
Description
Syntax
InvokeMethod
page 3-193
Name
page 3-195
H- 6
Version 6.0
Property Set
Table H-5.
(Sheet 1 of 2)
Method
Description
Syntax
AddChild
page 3-204
Copy
page 3-206
GetChild
page 3-208
GetChildCount
page 3-210
GetFirstProperty
page 3-211
GetNextProperty
page 3-212
GetProperty
page 3-213
GetType
page 3-214
GetValue
page 3-215
InsertChildAt
page 3-216
PropertyExists
page 3-217
RemoveChild
page 3-218
Version 6.0
H-7
Table H-5.
(Sheet 2 of 2)
Method
Description
Syntax
RemoveProperty
page 3-219
Reset
page 3-220
SetProperty
page 3-221
SetType
page 3-222
SetValue
page 3-223
SiebelException
Table H-6.
Method
Description
Syntax
GetErrorCode
page 3-248
GetErrorMessage
page 3-248
H- 8
Version 6.0
Index
A
accessing business components 2-63
ActivateField business component
method 3-98
active view name, returning 3-53
ActiveApplet 3-48
ActiveApplet application method 3-48
ActiveBusComp application method 3-49
ActiveBusObject application method 3-50
ActiveControl application method 3-51
ActiveViewName application method 3-53
ActiveX Application Control
communicating with Siebel
applications 2-9
instantiating 2-53
ActiveX control
Login method 3-70
specified in an argument, returning 3-31
ActiveX Data Control
communicating with Siebel
applications 2-9
from a server-side script 2-56
instantiating 2-53
instantiating through JavaScript 2-54
ActiveX interfaces
accessing 2-39
Siebel Business Objects, accessing 2-8
adding business rules to business
component 1-7, 1-8
adding new record 3-134
allocations, tracking 3-88
AllowNotification business component
method 3-100
Version 6.0
applet
control method 3-224
focus, setting 3-63
with input focus, returning 3-48
object type 2-18
Applet_ChangeFieldValue event 3-38
Applet_ChangeRecord event 3-39
Applet_GotFocus applet event 3-40
Applet_GotFocus event
firing of 2-80
Applet_InvokeMethod event 3-42, 3-237
Applet_Load event 3-43
Applet_LostFocus event 3-44
Applet_PreInvokeMethod event 3-46, 3-238
application factory object type 2-20
application object type 2-16
Application_Close event 3-91
Application_InvokeMethod event 3-92
Application_PreClose event 3-93
Application_Start event 3-96
arguments
syntax Intro-3
associate business component
method 3-101
returning 3-113
B
breakpoint 1-21
BusComp
control method 3-225
records, returning 3-107, 3-110
web applet method 3-234
BusComp_Associate event 3-164
BusComp_ChangeRecord event 3-165
BusComp_CopyRecord event 3-167
Index
business services
built-in 2-17
removing properties 3-197
retrieving property names 3-190, 3-191
retrieving property values 3-192
run-time 2-17
specialized 2-17
BusObject
activating 3-64
control method 3-226
Web applet method 3-234
BusObject business component
method 3-103
C
Calls 1-22
CancelOperation 2-77, 2-78, 3-201
check syntax command 1-20
ClearToQuery business component
method 3-104
COM 3-70
COM Data Server object, starting 3-69
COM interfaces
accessing 2-6
accessing in C++ 2-26
accessing in Microsoft Visual Basic 2-25
functionality 2-8
limitations 2-7
performance differences 2-8
COM, syntax conventions 2-24
Compiler/Interpreter 1-3
constants, table of 3-23
ContinueOperation 2-77, 2-78
control
contents, setting 3-233
with input focus, returning 3-25, 3-51
ControlName_Click event 3-247
controls
manipulating 2-70
rendering on a Web page 3-239
value, returning 3-229
copying records 3-134
CORBA, attributes in 3-14
Version 6.0
Index
D
data
manipulation capabilities 1-4
retrieving for queries 3-98
transport 1-6
data types 3-117
data validation 1-4
date format 1-27
date variables 1-27
DeactivateFields business component
method 3-105
deallocations, tracking 3-88
Debug menu 1-16
Debug toolbar 1-16
debugger
accessing 1-16
breakpoints 1-21
Debug toolbar, buttons 1-16
debugging/run-time preferences 1-18
described 1-3
overview 1-15
run-time preferences 1-19
using 1-16
debugging preferences 1-18
declarations in the (general) (declarations)
section 2-73
DeleteRecord business component
method 3-106
disconnecting client from the server 3-74
documentation, additional Intro-5
Drilldown applet method 3-29
DTYPE_DATE data type 3-118
DTYPE_PHONE data type 3-117
Version 6.0
E
Edit toolbar 1-12
edit functions of 1-12
EnableExceptions method 2-47, 3-55
EnableOLEAutomation flag 2-25
error code
returning last 3-187
returning most recent 3-119
error handling
differences among the interfaces 2-45
enabling and disabling native COM 3-55
error message tracking 2-45
error notification 1-5
error text message, returning last 3-120,
3-188
event method syntax 2-75
events
BusComp 2-81
determining firing order 2-80
and extension events 2-75
object interface 2-75
object interface table 3-19
outcome of 2-76
and Thin Client interfaces 3-21
user interface control 2-82
exception handling, CORBA 2-47
ExecuteQuery business component
method 3-107
ExecuteQuery2 business component
method 3-110
exporting data 1-6
extension events and events 2-75
extension routine 1-6
external applications
integrating 1-6
launching 1-6
logging 3-70
using ActiveX interfaces 2-8
using CORBA interfaces 2-11
Index
F
field value
returning 3-115
returning in local format 3-117
fields, deactivating current 3-105
FindActiveXControl applet method 3-31
FirstRecord business component
method 3-111
FirstSelected business component
method 3-112
G
GetAssocBusComp business component
method 3-113
GetBusComp business object method 3-186
GetBusObject application method 3-57
GetFieldValue business component
method 3-115
GetFirstProperty
business service method 3-190
GetFormattedFieldValue business
component method 3-117
GetLastErrCode
application method 3-58
business component method 3-119
business object event 3-187
GetLastErrText
application method 3-59
business component method 3-120
business object method 3-188
method, availability 1-25
GetMVGBusComp business component
method 3-121
GetNamedSearch business component
method 3-123
GetPicklistBusComp business component
method 3-124
GetProperty
business service method 3-192
I
importing data 1-6
InputBox application method 3-66
instantiating
ActiveX Application Control 2-53
business objects 3-57
Siebel COM Automation Server 2-48
Siebel COM Data Server 2-50
integrating an external application
with Siebel applications 1-6
inter-application variables 2-74
interface and method table 3-8
interface methods 2-3
interface objects, custom behavior 1-5
InvokeMethod
applet method 3-34
application method 3-68
business component method 3-130
business service method 3-193
Web applet method 3-235
Version 6.0
Index
Version 6.0
Name
applet method 3-36
business component method 3-133
business object method 3-189
business service method 3-195
control method 3-230
Web applet method 3-236
named field value, assigning 3-143, 3-145
naming conventions 1-24
navigating
to the Drilldown object view 3-29
methods 2-69
overview 2-69
navigation methods 2-69
NewRecord business component
method 3-134
NextRecord business component
method 3-136
NextSelected business component
method 3-137
Index
P
parent applet object, returning for
control 3-224
parent business component,
returning 3-138
ParentBusComp business component
method 3-138
Pick business component method 3-139
Pick business component, returning 3-124
PositionId application method 3-79
PositionName application method 3-80
PostChanges applet method 3-37
preferences, run-time 1-18, 1-19
PreInvokeMethod application event 3-94
PreInvokeMethod events 2-76
PreviousRecord business component
method 3-141
program flow
controlling 2-76
programming
and upgrades 1-2
when to use 2-4
properties
global state 2-70
properties and functions, global state 2-70
property set object type 2-19
PropertyExists
business service method 3-196
Q
queries
clearing current 3-104
refining 3-142
sorting specifications 3-104, 3-154
R
record
adding new 3-134
committing database changes 3-161
moving to first 3-111
moving to last 3-132
moving to next selected 3-137
moving to previous 3-141
picking currently selected 3-139
removing current 3-106
reversing uncommitted changes 3-160
RefineQuery business component
method 3-142
RemoveProperty
business service method 3-197
run-time engine, invoking 1-23
run-time errors
trapping 1-25
S
script editor
accessing 1-9, 1-11
illustration of 1-10
overview 1-3
script editing preferences 1-13
using 1-10
Scripted flag 1-13
ScriptingDLL 1-7
scripts
maximum size of 1-12
search expression
returning current 3-126
setting entire 3-148
search specification
returning 3-123, 3-127
setting 3-147, 3-150
SetFieldValue business component
method 3-143
SetFormattedFieldValue business
component method 3-145
SetNamedSearch business component
method 3-147
Version 6.0
Index
Version 6.0
Index
Siebel VB Debugger
described 1-3
variable window of 1-22
Siebel VB Language 1-3
sorting specification, setting 3-154
specialized methods, calling 3-68, 3-130
sscfbas.dll 1-7
sscfjs.dll 1-7
SuppressNotification business component
method 3-159
syntax checking 1-20
T
temporary files
sbx files 1-23
theApplication method 3-249
thin client
interfaces and methods 3-14
Thin clients, interfaces and methods 3-14
this object reference in Siebel eScript 1-28
toolbars
Debug 1-16
Siebel Script 1-12
Trace 2-74
Trace application method 3-85
trace file message, appending 3-85
TraceOff 2-74
application method 2-74, 3-87
TraceOn 2-74
application method 2-74, 3-88
tracing, turning off 3-87
typographic conventions 2-22
V
value of a control, returning 3-229
Variable 1-22
variables
availability 2-50
declaring 1-24
local 2-72
scoping 2-72
view, activating 3-64
visibility mode, returning current 3-129
visibility rules 1-5
visibility type, setting 3-157
W
Web applet object type 2-20
scripting 2-20
WebApplet_InvokeMethod event 3-237
WebApplet_PreInvokeMethod event 3-238
WebApplet_ShowControl event 3-239
WebApplet_ShowListColumn event 3-242
Window 1-22
WriteRecord business component
method 3-161
U
UndoRecord business component
method 3-160
user interaction methods 2-69
user interface control events 2-82
user interface control object type 2-19
Version 6.0