Additional Blogs by SAP
cancel
Showing results for 
Search instead for 
Did you mean: 
0 Kudos
Hope you have your code handy from the {code:html}Creating Blackberry Apps with WebWorks and BSP – Part 1{code} of this blog series as you’ll reuse all or most of it. What we’ll be doing in this part is creating a BSP application and among other activities dumping the html pages there and then calling the BSP application from our app instead of calling the local html pages. I’d like to take a moment and emphasize on the fact the opportunities that this framework among others have opened; connecting to a SAP system through a Blackberry mobile device. In my opinion, Blackberry currently have an edge in the enterprise market compared to other smart phones, making it easier to roll out solutions to existing devices as compared to rolling out devices first and then the solutions and on top of it, providing a secure and dependable connection. Once the connection is established, most of ABAP techies will feel at home and can do almost everything within the BSP. Only sky (and the connection speed/page loading) is the limit! 🙂 Now let’s get started with the BSP application!

h3. Creating BSP application get_form_fields( changing fields = lt_fields ). read table lt_fields into ls_fields with key name ='assetnumber'. if sy-subrc = 0. move ls_fields-value to ls_assetdata-equnr. CALL FUNCTION 'Z_EQUI_HANDLER' EXPORTING IS_ZSEQUIDATA = ls_assetdata IV_ACTION = 'READ' IMPORTING ES_ZSEQUIDATA = ls_assetdata. * ES_BAPIRET = if sy-subrc = 0. lv_view = create_view( view_name = 'AssetList.htm' ). lv_view->set_attribute( name = 'is_assetdata' value = ls_assetdata ). call_view( lv_view ). else. lv_view = create_view( view_name = 'MainView.htm' ). call_view( lv_view ). endif. else. lv_view = create_view( view_name = 'MainView.htm' ). call_view( lv_view ). endif. Activate the controller class as well as the BSP application and test it out again in the browser. You should see similar results as we saw in {code:html}Creating Blackberry Apps with WebWorks and BSP – Part 1{code} of this blog.

h3. Preparing application launcher in Eclipse I would suggest you make a copy of the AssetTag app as we’ll be deleting most of the information off of it or create a new project under the name ‘AssetTagSAP’. All that we need in this new project is a html which calls our BSP application on ‘body’ tag’s ‘onload’ event, associate the icon and set permissions. For the sake of not worrying about manually typing in information and setting things over, I am copying the ‘AssetTag’ project and delete the objects which are not required. You only need to keep the ‘MainVeiw.htm’, ‘config.xml’ and ‘SAPIcon.png’ image. Do make sure all the entries in the ‘config.xml’ are copied over, especially in the permissions' tab and while you are there change the domain ‘*’ to your SAP server (e.g. https://test.com (https://test.com/)) and check the ‘Apply access request to subdomains’ check box. The last thing to do here is to add ‘blackberry.ui.menu’ feature to this domain. After deleting objects from the new package, the final package should look like
14 Comments