CRM & Cloud

Issues I faced in CRM & Cloud solutions

A few days ago i upgraded my visual studio from 15.7 to 15.8 and I noticed that Live Player option is showing no more. I looked into it and found the solution.
Please use below steps to enable the Xamarin Live Player.


  • Go to Tools -> Options ->Xamarin ->Other
  • Tick mark the "Enable Xamarin Live Player" option

That is it. Go to device list drop down and verify that Live Player option is listed.


I updated my Adroid SDK and right after that everything stops working and I started getting error message "PANIC: Missing emulator engine program for 'x86' CPU".

I started looking into this issue and found that on the Visual Studio output following command was being set:

C:\Program Files (x86)\Android\android-sdk\tools\emulator.EXE -partition-size 512 -no-boot-anim -avd Android_Accelerated_x86_Oreo -prop monodroid.avdname=Android_Accelerated_x86_Oreo
while my path to the emulator when i checked is:
C:\"Program Files (x86)\Android\android-sdk\emulator.EXE
 Further I noticed that when I tried to run emulator from command line from path "C:\"Program Files (x86)\Android\android-sdk\emulator.EXE" the emulator was getting started but from path "C:\Program Files (x86)\Android\android-sdk\tools\emulator.EXE" it was giving the same error message PANIC..

So until here i understood the issue that what is the problem I was dealing with, only thing i had to do was to point my visual studio to start new emulator instead of the older one.

When i googled visual studio forum to check the fix for this issue then i found that it is a known bug and it is going to be fixed in release 15.8 while current release is 15.7.6.

This is what Microsoft official replied:

Added a solution by Jon Douglas [MSFT] Thank you for your feedback! We have fixed this issue and it's available in a future version of Visual Studio. This issue came down to our IDEs using the old outdated tools/emulator path when Google moved emulator items in 25.0.3 to emulator/emulator instead. We have updated this path and thus consider this behavior fixed. Expect this to be inside a 15.8 proper release and we will work on trying to get it in a 15.7 SR if possible.
Question 
URL: https://developercommunity.visualstudio.com/content/problem/252854/unable-to-start-android-emulator-from-within-visua.html
So after getting to know there is not proper fix so I started to look into workarounds..
The workaround I found is very simple, please follow below steps:
  • Go to "Open Android Device Manager"
  • Delete the existing Device
  • Create a New device and MUST select "Google Play Store"
  • Click "Create"




Referring to this post, more issues came across and a new weird issue which was being displaying over the simulator when i was starting it, the issue was stating "Cold Boot: Snapshot doesn't exist".

I started browsing and googling this issue and came across that this is not even an issue. As s developer you don't need to worry about it. Please do not apply any fixes or any configuration settings or no need to create any environment variables.

In order to increase the start up performance and faster boot time of the emulators, its previous state is saved always. This enables the developers to not wait longer each time. So whenever you will start your emulator first time you will see this message. Let your emulator run and continue until you see a proper mobile screen. After you see the mobile desktop, please shutdown and close your emulator. You will see following message when you will do exactly as i mentioned:


It will save the state and on your next try the emulator will be loaded fast and it won't display any message that will worry you.

I build a Xamarin app in visual studion 2017 and it all worked fine. But in the visual studio verbose i saw there was a message that updates are available and i should apply the updated by going to Tools -> Android -> Android SDK Manager. 


I went there and there were three updates recommended, I clicked on apply and after that when i tried to run emulator, it started giving below error:

"hardware virtualization is not enabled on this computer and is required to use haxm. look at the reference material for your computer to find out if you can enable hardware virtualization. "

After googling this issue and reading through multiple contents online i fixed this problem by doing following steps:

  • Go to the machine BIOs then Advance Security and tick mark following options:
  • Go to Android installation directory and reached to the following path:
C:\Program Files (x86)\Android\android-sdk\extras\intel\Hardware_Accelerated_Execution_Manager


Bounce your computer and try again.
As a part of our Siebel Upgrade project, we had to upgrade Siebel Actuate reports as well. As Siebel Actuate is not compatible with Siebel IP17 so we decided to move on BIP 12C.

There were certain reports on which client was using check boxes and based on certain condition and value these check boxes are being filled with 'X' sign. In the Actuate reports all these were working perfectly until we moved our reports from Actuate to BIP 12C.

We notice that all the check boxes started appearing as rhombus sign or diamond sign. We looked into the issue fixed by doing using Wingdings2 font. The steps to fix the issues are:

  • Copy the Wingdings2.ttf file of your custom font (e.g. wingdings2.ttf) to the JRE home\fonts (e.g. C:\OraHome_1\jdk\jre\lib\fonts) folder on the BI Publisher Server
Log into the BI Publisher Server using the 'Administrator' login.
    • Click on the 'Administration' tab. 
    • Click on the 'Font Mappings' link under the 'Runtime Configurations' section on the right hand side. 
    • Click on 'Add Font Mapping' button under the 'RTF Templates' section. 
    • Set the following fields: 
Base Font - Wingdings
Style - Normal
Weight - Normal
Target Font Type - Truetype
Target Font - wingding2.ttf 
  • Go the the following location of your BIP 12C installation:
Lets suppose it is intalled in C dir,
C:\Oracle_Home\user_projects\domains\bip\bidata\components\bipublisher\repository\Admin\Configuration 

 Open the xdo.cfg file in textpad and add the entry:

<property name="rtf-checkbox-glyph">Wingdings2;0082;0163</property>
  • Copy the font file wingdings2.ttf  to: $BIP_INSTAL_HOME\user_projects\domains\bifoundation_domain
Please note that, you can also set following property:
<property name="rtf-checkbox-glyph">Wingdings2;0082;0163</property>
By going to "Administration" - > Parameters -> Characters Used for Checkbox,




When you are done with above steps, please bounce the BIP sever and test your reports.


In Siebel IP17 once you will open Weblayout editor to arrange controls on the template then you won't be able to see anything and if you look into the browser console, you will see below error:

Uncaught TypeError: this.GetUIWrapper(...).BuildPreview is not a function
 The issue is caused by the following setup: Customization added at JS level.
WebTools is the correspondent of Tools, and should, therefore, contain no customizations. This includes JS files. 

In order to fix this use below parameters:

Manifest Safe Load : TRUE
Enable Safe Boot : TRUE
The printing of the current record in Siebel IP17 has been taken off. The Print menu option is there but when it is not working. Here is to reproduce the issue:
1. On an applet go to Menu
2. Click on the Print option
3. the print dialog appears
4. Click on Print button nothing happened
5. Clicking on Print Preview button nothing happened

The Print functionality works perfectly in Siebel 8.1x but it is been taken off in Siebel IP17. I am not sure why this happened and what is the alternative Oracle is thinking to provide but so far this is not available.

As per Oracle, Print option from the Siebel Applet menu should not be selected and instead Browser Print functionality will be used. It is recommended by Oracle to hide Print menu option in the applets by using CSS.
In Siebel IP17 there is a major problem with the State Models that some of the business components will not appear in the State Model MVG Applet when you will search the business component.

Until all previous versions all the available business components are available in the MVG applet to be added in a State Model but in IP17 the underlying model got changed.

Now, in IP17+ the business component behind the applet used to show all the BCs to be selected for a State Model is replaced with a virtual business component and only those business components having a user property State Model = Y will be displayed but this is not how it is currently working. Despite the user property is mentioned, most of the business components do not appear in the applet to be selected for State Model. As per Oracle this bug will be fixed in Siebel 18.7.
Apparently Siebel IP17 has some problem for testing development related changes on local environment before pushing it to the server. Development related changes cannot be tested locally on the workspace also known as sandbox in IP17 but changes cannot be seen made in the objects until workspace get submitted and delivered the respository.

As per bookshelf, below are the steps to test changes/modifications locally:
  1. Create a workspace 
  2. Edit objects for example update the Applet control caption 
  3. Checkpoint/versioned the workspace ( i suppose this is optional step) 
  4. Modify the corresponding CFG file say "publicsector.cfg" cfg file as below: 
[Workspace]
Name = Main
Version = 41 -- The version of the workspace for which you wanted to test the changes

[InfraObjMgr]
RequestServerName = <SERVER_NAME>
RepositoryType = RUNTIME 

      5. Start thick client (dedicated client) to view the changes

You can even try mentioning your own workspace name like:

[Workspace]
Name = dev_umer_fieldupdate1
Version = 01

[InfraObjMgr]
RequestServerName = <SERVER_NAME>
RepositoryType = RUNTIME

But in this case it even would not let you log in.

Similarly, in the thin/thick client it is not possible to edit/view Workspace changes by opening Workspace directly, there is no hammer icon anywhere.
In one of our Siebel IP17 upgrade project we had to set an option for the end users cancel currently long running queries. In Siebel 8.1x if user executes a query in the application UI then if the result is taking longer time then a popup window appeared asking and informing user to wait as query is taking longer execute time or Cancel the current operation. In the meanwhile user do not have the option/permission to click anywhere else on the screen while the current operation is in progress.



 But in OpenUI (until IP17.5), in case of long running query a circle appears showing as system is busy but after certain amount of time it stop spinning and disappear and from here the user can click on other screens but as the current operation was not completed the next screen will not be loaded and system appears as stuck.

In case we set set CancelQueryTimeOut >=1 say 10 in the corresponding Object Manager and execute a long running query then a popup window starts appearing after 10 seconds but on clicking Cancel button it did not work and stays as below:




I have written a Java Card (Javacard) shell by which you can communicate with a real javacard compliance smart card. This tool is opensource and can be downloaded from github.

I named it as "GPCShell", global platform shell. By using this shell following can be performed:


  • APDUs can be sent and received
  • Status command can be send and received
  • It is complaint to Global Platform and ISO7816-4
  • It can be used to upload .cap files to a real javacard
The project is compiled via Netbeans and can be downloaded and extended.

A demo is presented here:


The tool works as follows:
  • Card is using a XML file for the Card Manager Id and security keys
  • It reads Card Manager Id from the XML and connects to the card
  • Security keys can be updated by providing SH1 256 byte keys in the XML
  • The tool uses provided security keys in the XML to authenticate the Card using SCP01 and SCP02
The structure of the XML file is as below:



One of the major problem and shortcoming with Siebel CRM was its browser dependence. That is, it was only used to work with IE. Moreover it was using ActiveX technology by Microsoft which is also now going to vanished.
Oracle lunched a major release of Siebel CRM called IP13 [ IP2013] and here for the first time Siebel was made browser independent. That is from IP13 onward now Siebel can be accessed on any modern browsers like Chrome, firefox etc including IE.
Oracle removed ActiveX technology and replaced it with a new custom framework called OpenUI. It is based on Javascript and CSS files. Just like for any modern website development, here now developer's can write javascript code to customize end user functionality like field validation, data manipulation at the browser end etc and can design and formate UI by using by customizing CSS files.
OpenUI enables Siebel CRM to be cloud ready, responsive and mobile friendly. Making UI level customization in Siebel are now as much possible as for with any other website.

ava(smart) Card is considered as future technology. They are getting fame and being used in many secure applications. In many countries like Estonia smart cards are mandatory to have for each citizen. They are being used as a secure transection medium.
Some of the formal definations of the java card are below:
Java Card refers to a technology that allows Java-dd applications (applets) to be run securely on smart cards and similar small memory footprint devices. Java Card is the tiniest of Java targeted for embedded devices. Java Card gives the user ability to program the device and make them application specific
Oracle say that:
Java Card technology provides a secure environment for applications that run on smart cards and other devices with very limited memory and processing capabilities. Multiple applications can be deployed on a single card, and new ones can be added to it even after it has been issued to the end-user. Applications written in the Java programming language can be executed securely on cards from different vendors
Also some site has the definition that:
Java Card is an open standard from Sun Microsystems for a smart card development platform. Smart cards created using the Java Card platform have Java applets stored on them. The applets can be added to or changed after the card is issued.
All above descriptions and definitions of java cards are correct and have meanings. But if we want to summarize them all then we can say that:
A Java Card is a smart card (having a chip) which can be programmed in java programming language using special application programming interface and is obeying set of rules and standards
.
To demonstrate how to write a Java Card basic applet and how to execute it, In the video blow I have wirtten a java card applet, just an example. In this example, Java Card Counter, Java card applet will initialize a variable with '0' and will start incrementing its value upto '4' on each APDU. It is a basic example, and I hope, it will help people who are just beginners in the Java Card field ...




Please write down comment and feel free to ask if you can't understand anything.
Before showing you and explaining how to write a Hello World applet for the java card, I would like to discuss how to set the development envirement for the java card applets.
Fortunately, Oracle has provided all the necessary tools, libraries and set of APIs for the development of the Java Card applets. Go to the Oracle offical website and download java card sdk version 2.2.1.
Note: Please don’t go for java card 3.0 as there is no real java card available for prgramming and there is not use to learn if you don’t have a real time envirement to deploy or test it. For further information click here
When you will download the development kit, you will will find that it also have complete java card specs and API documentation alongwith programemrs note. Mainly following tools are very helpful for development of java card apps:
  • Java Card Converter
  • scriptgen
  • Off-card Tool
  • exp2text tool
  • Off-card verifier
  • capdump
  • Installer
A brief description of all of the above mentioned tools are given below:
  • Java Card Converter
  • The converter tool is a very important tool. This tool tool’s duty is to convert your java source files thats .class files to .cap file. CAP file is a Converted Applet File, and this is the actual file which you load and install on the java card. You can’t directly upload your source files(.class files) onto the card.
    For more information click here
  • scriptgen
  • This tool simple converts your CAP file into a sequence of APDUs which can be send to java card for installation of that particular CAP file.
    For more information click here
  • Off-card Tool
  • The off-card verifier is a combination of three tools, verifycap, verifyexp, and verifyrev.
    For more information click here
  • exp2text tool
  • The exp2text tool is provided to allow you to view any export file in text format or human readable formate.
    For more information click here
  • capdump
  • This tool is similar as exp2text tool. For viewing cap files in the ascii format you will use this tool on the command prompt.
    For more information click here
  • Installer
    The development kit installer can be used to:
  • Dynamically download a Java Card technology package to a Java Card technology-compliant smart card. During development, the CAP file can be installed in the C-language Java Card RE rather than on a Java Card technology-compliant smart card. The installer is capable of downloading version 2.1, 2.2, 2.2.1, and 2.2.2 Java Card technology based CAP files (“Java Card CAP files”).
  • Perform necessary on-card linking.
  • Delete applets and packages from a Java Card technology-compliant smart card. Once the installer is selected, requests for deletion can be sent from the terminal to the Java Card technology-compliant smart card in the form of APDU commands. For more information, see Deleting Packages and Applets.
  • Setting default applets on different logical channels.
  • The installer is not a multiselectable application. On startup, the installer is the default applet on logical channel 0. The default applet on the other logical channels is set to No applet selected.
To set up java card development environment you will need all the tools which I have mentioned in my previous post. To set up all these tools there is a very fine link/book which explains each and everything very clearly. In this blog I will focus on the development/programming and will try to use already provided resources and documentation as there is no use to re-invent the wheel. Please Click here to learn how to set up the development environment for java card.
Another very informative link which will help you for setting your development environment. In this link everything is explain via images and screen shots.
Moreover, the above mentioned link will show you how to set up envirement with JCWD which is a tedious way for settting things up. As a beginner you will find a lot of troubles and problem during settings. To get rid of this mess you should go for JCOP Tools. JCOP is an eclipse plugin which is used for development of java card applets. In this blog my posts will using this tool.
There are many reason that I have recommend this tool, for of all it is very easy to integerate with eclipse. You can watch the video below to see how:
The other few advanges of using JCOP are as below:
  • Easy to use and write your code
  • Automatically converts your source code to cap file
  • Global Platform Compliant
  • Off card simulator
  • Debugging facility
  • Allow to install/delete cap files from card
A brief document of using JCOP is here
Before starting development and programming for java cards or any other smart card you must need to learn about the basics of them. For Java Card you need to learn and understand following documents:
  • ISO7816-3
  • ISO-7816-4
  • Global Platform 2.2 Or 2.1
  • JCVM 2.2.X
  • Java Card API 2.2.X/Java Card Programming Notes 2.2.X
A beirf description of the above documents are given below:
  • ISO7816-3
  • This document contains the information about the hardware of the (Java)smart card. By hardware I mean the chip size, its contacts, its voltage and other properties like that.
  • ISO-7816-4
  • This document provides all the information which is necessary for the communication between Java card and the CAD (Card Acceptance Device) or host application.
  • Global Platform 2.2 Or 2.1
  • This document is similar as ISO7816-4 but more and much comprehensive. It states all the commands and methods for the communication for the Java Card like installing and selecting an application within the java card
  • JCVM 2.2.X
  • This document is about the internal structure of the Java Card. It explains how java card interprets the APDUs and its instruction set.
  • Java Card API 2.2.X/Java Card Programming Notes 2.2.X
  • These documents are fore Java Card applet developer. It contains the explanations of the functions and programming interface which is available during the programming.
To download GP document you need to visit the GP Site and all other document you will get when you download the development kit from the oracle site. Lucky isn't :P


Writing Java Card applets is not a hard thing, but yes you need to be familiar with java card API and its standards to pass APDUs.
In this post I will try to explain the mandatory functions for the successful execution of the Java Card applet.
Following functions are necessary for an applet to execute and its installation etc.
public static void install(byte[] bArray, short bOffset, byte bLength){}
public void process(APDU apdu){}
protected final void register(){}
        //or
protected final void register(byte[] bArray, short bOffset, byte bLength){}
                                                           throws SystemException
public boolean selectingApplet(){}


  • install()

  • To create an instance of the Applet subclass, the Java Card runtime environment will call this static method first.
    All the initialization and memory allocations should be done in this method.
    All the memory allocations should be done in this method or in the constructor of the class. It will prevent you from memory overflow error later on.


  • process()

  • This method is like a main method of a normal java class. After the installation the execution of APDUs takes place from this method. Each and every APDU comes in this method and get processed as its name suggest ;)


  • register()

  • In order to register an instance of the applet with the Java Card Runtime enviroment this method must be called. This method should be called within install() method.


  • register(parameters)

  • This method works same as above register() plus it assigns the specified AID bytes to the instance AID bytes.


  • selectingApplet()

  • This method is used by the applet process() method to distinguish the SELECT APDU command which selected this applet, from all other SELECT APDU commands which may relate to file or internal applet state selection.
    It is a good programming practice that you should return 0x9000 when this function returns true
    Ok, I hope you are now familiar with the most important functions of the java card applet. Your class (your own applet) will inherit these functions from the Applet class of thejavacard.framework package by extending the javacard.framework.Applet class.
    Now if we sum-up all the above functions and write them in a way so that a complete applet can be written is as below:
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    import javacard.framework.APDU;
    import javacard.framework.Applet;
    import javacard.framework.ISO7816;
    import javacard.framework.ISOException;
    public class MyOwnApplet extends Applet {
        public static void install(byte[] bArray, short bOffset, byte bLength) {
            // GP-compliant JavaCard applet registration
            new MyOwnApplet().register(bArray, (short) (bOffset + 1), bArray[bOffset]);
        }
        public void process(APDU apdu) {
            // Good practice: Return 9000 on SELECT
            if (selectingApplet()) {
                return;
            }
            byte[] buf = apdu.getBuffer();
            switch (buf[ISO7816.OFFSET_INS]) {
            case (byte) 0x00:
                break;
            default:
                // good practice: If you don't know the INStruction, say so:
                ISOException.throwIt(ISO7816.SW_INS_NOT_SUPPORTED);
            }
        }
    }