Skip to Content

Starting

from we left off in Creating Blackberry Apps with WebWorks and BSP – Part 2, we were able to

successfully test our app in the browser. As of now we have worked with

everything local so the MDS had little to do with our work. MDS is basically

Blackberry’s Mobile Data Service. You can read about it more here. You can test the

connectivity of your Blackberry simulator to the internet by simply going to

the browser within it. Try browsing to google.com or a site of your choice. If

you connect, you don’t need to provide settings to configure MDS. But in case

you do use a proxy, you’d have to add couple of lines to the MDS configuration

file which can be easily found (sarcastically speaking of course) @

Open

the ‘rimpublic.property’ file in edit mode in a notepad and under the

section and before , add the following lines to set the

proxy.

Registering your Code Signing Keys

Hopefully
you should’ve received your code signing keys by now, (if you’ve applied for
them a day or two ago) and you still remember the PIN you’ve supplied
(hopefully, you took my advice and noted it down somewhere). You should’ve
received three keys in three separate emails. Save all three of them in a local
folder.

Now
select the project AssetTagSAP from the project explorer, go to the ‘Project’
menu and select ‘Build and Sign Blackberry WebWorks Project’

!https://weblogs.sdn.sap.com/weblogs/images/251890305/signapp.png|height=196|alt=|width=512|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/signapp.png!

First
time when you do this, Eclipse will prompt that you don’t have any signing keys
registered. Click ‘Proceed’ to associate the keys you received from RIM.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/errorlaunchingtool.png|height=132|alt=Error 1|width=425|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/errorlaunchingtool.png!

Another
dialogue would open giving you the option to register existing keys, new keys
or import keys.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/installkeysprompt.png|height=443|alt=Signature tool|width=509|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/installkeysprompt.png!

Click

on the ‘Install new keys’ and it will prompt for a ‘CSI’ file which is the key

you’ve received from RIM. You’d have to register all three keys to make this

work, start with the RBB.CSI or any other you’d like. At the selection of the

first file/key it will prompt with another error, simply click ‘Yes’:

!https://weblogs.sdn.sap.com/weblogs/images/251890305/Signingtool1.png|height=155|alt=Error 2|width=653|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/Signingtool1.png!

The
program will prompt for setting up new password for securing the private key
(minimum 8 characters). This would be required anytime you’d like to sign an
application. I would recommend that you should save this password as well and
as far as I remember this has to be at least 8 characters long. Try not to make
this too personal, as although it takes it in a password field, this gets
displayed in the Eclipse console every time you sign an app.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/settingsigningpassword.png|height=183|alt=|width=439|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/settingsigningpassword.png!

Note: This password should/can

be different from the PIN you provided while applying for the keys on RIM’s

website.

Once
you provide the new password, the application prompts you to move your mouse or
type to generate random information

!https://weblogs.sdn.sap.com/weblogs/images/251890305/randominformationgen.png|height=279|alt=|width=393|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/randominformationgen.png!

Complete
this to 100% and up comes the prompt to provide the PIN you provided at the
time of applying for the keys.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/Signingtool4.png|height=228|alt=|width=268|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/Signingtool4.png!

If
you have a proxy in place, it will be wise to provide the proxy information by
clicking on the ‘Configure Proxy’ button. Click ‘Register’ and if you’ve
provided the right PIN (and the proxy if you need one) it will try to register
your keys and voila! Your first key is about
to be registered!

!https://weblogs.sdn.sap.com/weblogs/images/251890305/waitingscreen.png|height=215|alt=|width=297|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/waitingscreen.png!

It
specifies the ‘Client’ number corresponding to the key you received from RIM in
the successful registration message.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/confirmation.png|height=149|alt=|width=529|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/confirmation.png!

Repeat
the same procedure to register the 2nd

(RCR.CSI) and the 3rd

key (RRT.CSI). But this time the prompt would ask for the original PIN and

the password you just set.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/secondkey.png|height=228|alt=|width=267|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/secondkey.png!

You’d
have to do this with every Eclipse instance you might install. The keys are
good only for one install only, I tried to import existing keys but was never
successful and anytime you forget your password, you’d have to apply for new
set of keys. At the time of writing this blog, there was no known procedure for
password recovery. You’ll receive emails from RIM confirming the registration
and the signature tool will be kicked off immediately.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/signaturetool.png|height=320|alt=|width=520|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/signaturetool.png!

Now
the application is ready to be deployed on your Blackberry device. Next time
you register another application, it would only prompt for the password for the
key (which we entered in the steps above) and never for the PIN.

Deploying to your Blackberry device

”. You can only execute this successfully here if

you’ve defined the ‘bin’ path in the environment variables like I mentioned in Creating Blackberry Apps with WebWorks and BSP – Part 1 of

this blog series. When

you execute the file, it would prompt for the device password. Enter the

password and hit enter.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/javaloaderexewithpasswordupdate.png|height=124|alt=|width=512|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/javaloaderexewithpasswordupdate.png!

And
you are done! This program loads and disconnects itself from the device very
efficiently.

!https://weblogs.sdn.sap.com/weblogs/images/251890305/cmdafterexecutionupdate.png|height=163|alt=|width=512|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/cmdafterexecutionupdate.png!

Check

the download folder of your Blackberry device and try out the application. Here

are some snapshots from my Blackberry (taken through a utility called BBScreenShooter,

you can find it here )

!https://weblogs.sdn.sap.com/weblogs/images/251890305/Downloadfolder.png|height=217|alt=|width=289|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/Downloadfolder.png! !https://weblogs.sdn.sap.com/weblogs/images/251890305/secondpage.png|height=217|alt=|width=289|src=https://weblogs.sdn.sap.com/weblogs/images/251890305/secondpage.png!</p>

Conclusion

This is awesome! Blackberry’s
WebWorks provides a great platform to roll out applications quickly on the
mobile devices. A nice CSS can help you standardize how the mobile applications
should look in your company. The BSP opens the doors to everything which SAP
has to offer in terms of information. One has to be aware of the limits of the
small screen of a mobile phone presents and only the most important information
need to be provided for communication. A combination of HTML/BSP with good ABAP
skill set can get all kinds of applications rolling out relatively quick!

To report this post you need to login first.

5 Comments

You must be Logged on to comment or reply to a post.

  1. Padmakar Tadepalli
    Hi,
    Excellent blog, a very good introduction to BlackBerry WebWorks.
    Just one quick question, is there any way to call this application using a BlackBerry over the internet? As you might be aware that BSP applications work only with a FQDN.Can you throw some light on how to access it outside my company’s domain? DO I have to expose my development system by giving it a public IP, is that the only way?

    Regards,
    Padmakar

    (0) 
    1. Asim Mian Post author
      Thanks Padmakar, glad you liked it! The sample application I wrote is based on the fact that the Blackberry Enterprise Server (BES) has open connection to the SAP system you are trying to connect. Going through the BES makes it very secure. This the general idea given to us from the RIM solution architect as well.

      I wouldn’t advise you to expose your company information publicly but rather have a VPN connection established as they’ve been preaching for other devices.

      Hope this helps.

      Best regards,
      Asim

      (0) 

Leave a Reply