Monday, November 30, 2009

How to customize your Siebel application toolbar

Want to customize your tool bar? here is how you can do it.

Depending upon where you want your button or control to go. You will have to select the appropriate toolbar and customixe it.

In this post I will show you how to create a custom button to logout from your application.

Step 1:  go to Command Object in your Object Explorer and query for "Logout"
(If you cannot see this object. In tools go to View | Options | Object Explorer tab | check the Command Object)






Step 2: Copy the the Logout command object and rename it to 'Logout New'(you could use the same one too)








Step 3: Go to the toolbar Object in your Object Explorer and query for "HIQuery" toolbar(you could use another toolbar depending on where you would like to see your button on the application)







Step 4: click on the toolbar Item child object. Create a new record called 'Logout' with the following properties

- Name: Logout
- Command: Logout New
- Display Name: Logout

 


Step 5: Compile all objects you modified/ created.

your application should have the 'Logout' button right next to the Execute query button.






 





Now, when you click on the logout button siebel will call the Logoff method and the application will logout.

Next, I will show you show to call a business service from a custom button on the toolbar. Stay tuned...


Cheers!

Wednesday, November 18, 2009

How to add a Screen Tab image to your siebel application

Hi all,

This is usually a part of Branding, adding your own images/icons to the siebel application like I have added below.




Required Configuration :



Add the Screen on the Page tab. Only the image will be visible.





In Bitmap Category create a new record with a unique name and the required parameters.
In Bitmap child object create a new record with name ‘Screen Tab’ and in filename specify the name of the file with the .gif extention.






To specify the properties of ‘Logo’ go to menu -->View-->Windows-->Properties Windows.
Now you will be able to edit the ‘Height’ and ‘Width’ properties.
In the Object Explorer goto Screen --> Create new/Use existing screen and give the required properties.
Then goto Siebel Tools menu--> View-->Windows-->Properties Windows.
Specify the name of the Bitmap Category in the Bitmap Category Property as displayed in the below figure.






Compile all the Objects.
Clear internet history and files. Reopen the Application.
You should now see the icon you have added on the screen tab.


Cheers!

Tuesday, November 17, 2009

Integrating Siebel 8 With Oracle SOA Suite

Here is a complete documentation of how to pull Siebel data from an external application(JDeveloper)



Cheers!

Tuesday, November 10, 2009

How to Launch an external executable from Siebel

There are many ways of doing this. Here are two -

1. The first approach is a bit easier than the second. The script is written in the Applet_Load event of the Applet Browser Script. You can also invoke the executable file from a button click etc...

Script

function Applet_Load ()
{
//Instantiate an ActiveX shell Objext.
var wshell = new ActiveXObject("WScript.Shell");
var oFSO = new ActiveXObject("Scripting.FileSystemObject");

//the path of where this file has been installed
sDirectory = "C:\\PROGRA~1\\WINDOW~1\\ACCESS~1\\";

sFile = "wordpad.exe";
sFilePath = sDirectory + sFile;

//Check if the .exe file is installed
if(oFSO.FileExists(sFilePath))
{
execRet = wshell.Run(sFilePath, 3, false);
}
else
{
alert("You do not Wordpad Installed.");
}

oFSO = null;
wshell = null;
return ("CancelOperation");
}


Now, When the applet loads wordpad will open.

2. The second approach uses a setTimeout JavaScript function that offers executing a function after a sleep duration. Then a new function must be created (waitForExecCompleted in the below example); this function will perform the test on the status of the external application: If the application is still running, re-execute itself after a while If the application is completed, run the rest of code


Script

//Global Declaration

var execRet;

function waitForExecCompleted()
{
if(execRet.Status == 0)
setTimeout("waitForExecCompleted()", 100);
else
{
execRet = null;
alert("Completed");
}
}

function launchExternalApplication()
{
var wShell = new ActiveXObject("WScript.Shell");

//File path
execRet = wShell.Exec("C:\\WINNT\\system32\\calc.exe");
waitForExecCompleted();
}



Cheers!

Tuesday, October 27, 2009

Siebel VB to eScript Converter

Hey Amigos,

Here is a utility from Siebel Systems that converts VBScript to eScript. After conversion it is not totally done but you should be 85% on your way.

Click on the below icon to download the converter.




Cheers!

How to kill Siebel process

Hi Folks,

Here is an Interesting tip shared by my Colleague Venus Hindocha about how to kill your Siebel.exe Process by avoiding the hassle of going to task manager and killing it there.

you can use the foll command from Start -> Run or put it in a batch file

taskkill /F /IM siebel.exe

Some theory:

Taskkill: Ends one or more tasks or processes. Processes can be killed by process ID or image name.


Syntax:
taskkill [/s Computer] [/u Domain\User [/p Password]]] [/fi FilterName] [/pid ProcessID]|[/im ImageName] [/f][/t]

/f : Specifies that process(es) be forcefully terminated. This parameter is ignored for remote processes; all remote processes are forcefully terminated.


/IM (ImageName): Specifies the image name of the process to be terminated. Use the wildcard (*) to specify all image names.

More Details

Wednesday, October 7, 2009

What Is the Calculation Logic Behind the Conversion Function RowIdToRowIdNum?

In Siebel versions 6.x and 7.x, there are several number fields such as SR Number, Agreement Number, Asset Number, and Invoice Number which have the Pre Default Value = Expr: 'RowIdToRowIdNum ([Id])'. RowIdToRowIdNum is a function used in calculated expressions. This function converts an alphanumeric ROW_ID to a unique, pure numeric ROW_ID.

The conversion is performed for digits and letters after or before the hyphen '-'. The formula used by RowIdToRowIdNum is the following:

[Last digit or letter * 36^0] + [Second to last digit or letter * 36^1] + [Third to last digit or letter * 36^2] + ...+ [Second digit or letter * 36^n-1)] + [First digit or letter * 36^n]

By design, values of letter A is 10, B is 11, C is 12 ... Y is 34, and Z is 35.

Example 1:

Take the example of ROW_ID = 1-5GYG0.

  1. Start converting from the last digit or letter from right to left, which is 0 in this case:

0 * 36^0 = 0

  1. Conversion of second to last digit or letter, which is 'G':

G * 36^1 = 16 * 36 = 576

  1. Conversion of third to last digit or letter, which is 'Y':

Y * 36^2 = 34 * 36 * 36 = 44064

  1. Conversion of second letter or digit, which is 'G':

G * 36^3 = 16 * 36 * 36 * 36 = 746496

  1. Conversion of first digit or letter before the hyphen '-', which is '5':

5*36^4 = 5 * 36 * 36 * 36 * 36 = 8398080

  1. Adding all the converted values right of the '-' gives 9189216:

0 + 576 + 44064 + 746496 + 8398080 = 9189216

  1. The next character is a hyphen '-'. The letter or digit to the left of the hyphen,'1', is converted by itself:

1 * 36^0 = 1 * 1 = 1

The final converted ROW_ID is 1-9189216.

Example 2:

ROW_ID G-5GYG0

This ROW_ID is the same as the ROW_ID in example 1 with the exception of the letter to the left of the hyphen, 'G'. Using the same conversion, G-5GYG0 would be 16-9189216 where G, the letter to the left of the hyphen, gets converted to 16.

  1. 0 * 36^0 = 0 * 1 = 0
  2. G * 36^1 = 16 * 36 = 576
  3. Y * 36^2 = 34 * 36 * 36 = 44064
  4. G * 36^3 = 16 * 36 * 36 * 36 = 746496
  5. 5 * 36^4 = 5 * 36 * 36 * 36 * 36 = 8398080
  6. Adding all the converted values right of the hyphen = 9189216

The final converted ROW-ID is 16-9189216.

Example 3:

ROW_ID = 1-IB79I

Using the same conversion, 1-IB79I would be 1-30755718 where '1', the digit to the left of the hyphen, gets converted to 1.

  1. I * 36^0 = 18 * 1 = 18
  2. 9 * 36^1 = 9 * 36 = 324
  3. 7 * 36^2 = 7 * 36 * 36 = 9072
  4. B * 36^3 = 11 * 36 * 36 * 36 = 513216
  5. I * 36^4 = 18 * 36 * 36 * 36 * 36 = 30233088
  6. Adding all the converted values right of the hyphen = 30755718

The final converted ROW_ID is 1-30755718.


Have a nice day!

What Is Row Id?


The unique identifier associated with every record in a Siebel Enterprise database is known as a Row Id. The column in which this value is found is ROW_ID and it is present on every table. The Row Id is unique for an entity. For example, the Row Ids for the same person in S_PARTY, S_CONTACT, and S_CONTACT_X are the same because they each refer to the same person.

Row Ids are used extensively throughout Siebel Enterprises to access specific records. Although users access records by a User Primary Key such as Opportunity Name, it is more efficient for the Siebel Enterprise to store and access related data via the Row Id.

The Row Id is a base-36 sequence number generated using a confidential, proprietary algorithm that ensures no duplication, thus protecting the referential integrity of the database. The ROW_ID column is VARCHAR(15), which may contain one or two non-numeric symbols (plus signs or hyphens, or both).

The format of the Row Id is one of the following:

CP-NS - Records created through the user interface
CP+NP+NS - Records created by Interface Manager (EIM)
CP-NP-NS - Records created by EIM (Starting in Siebel versions 6.2 and higher, and Siebel version 7)

Where:

CP = Corporate Prefix, up to 2 alphanumeric characters
NP = Next Prefix, up to 6 alphanumeric characters
NS = Next Suffix, up to 7 alphanumeric characters

The maximum length of the Row Id is 15 alphanumeric characters.

The corporate prefix will always be unique for any database (main or local). The server maintains its original value, and mobile databases created against that particular server database are always assigned a new, unique value.

All connected users share the same Next Prefix (NP), which is obtained from the table S_SSA_ID on the server database. Remote users are each assigned a unique prefix during extraction, which is also stored in the S_SSA_ID table, but on the local database.

Next Suffix (NS) is the heart of the Row Id and is generated with a proprietary algorithm. When a new record is created through the user interface, the Siebel application reads the value of the current NS column from S_SSA_ID table and increments this value by a value more than 1, for performance reasons. In Siebel applications version 7.5.3 and earlier, this value is generally incremented by 50. Starting in Siebel 7.7, the value is generally incremented by 1000. The client caches these potential Row Ids for future inserts. A new record entered from the user interface may result in many inserts to the underlying tables, depending on the business components used. When the client disconnects, cached Row Ids are lost.

In Siebel applications version 7.5.2 and earlier, the caching of Row Ids occurred on individual Application Object Manager (AOM) tasks. In Siebel applications version 7.5.3 and later, Row Id caching occurs on the AOM process itself. This change reduced the potential for contention issues on the S_SSA_ID table.

NOTE: If the client is in a database transaction when it needs to create a new Row Id, the object manager updates the S_SSA_ID table in a separate transaction and commits the transaction immediately.

NOTE: The logical schema reports the ROW_ID column as a VARCHAR, as does the physical schema.


Share/Bookmark