HWC mobile app development for dummies – Part 2
Starting SUP Development
In this part, MBOs (Mobile business objects) will be developed and deployed to SUP server. There is only one MBO called Flights_List. The Flights_List MBO represents a BAPI in SAP system.
This is the 2nd part of this series. Other parts are:
Part 1- Setup Mobile Development Environment
Part 3- Developing a Hybrid Web Container Application
Part 4- Deploying a Hybrid Web Container Application
Part 5- Register Device and Assign User for Hybrid App
Part 6- Test Application on Device
1. Create a new mobile application project by right clicking in a free space under WorkSpace Navigator > New> Mobile Application Project.
2. Give a name for the project “AirlineProject”.
3. It will create a new project in the WorkSpace. Create Flights_List MBO by right clicking on the folder “Mobile Business Objects” as shown below.
4. Give a name for the MBO and click Next.
5. Specify a database from the choice bar. We have connected our SDK with SAP hence it comes in the list. Select SAP and click Next.
6. Click on browse to fetch the BAPIs. Give name of the BAPI and click on “Search BAPIs/RFCs” that will bring the list of BAPIs based on the search. Select BAPI_FLIGHT_GETLIST and click OK.
7. Select “AIRLINE” as input and “FLIGHT_LIST” as output. Click on Next button.
8. Click Next.
9. Click the Next button and click on Finish. It creates the MBO.
10. Create a personalization key and map it to the load parameter of MBO. This key will be used while developing HWC application. “AIRLINE” is the load parameter (ie. RFC input) of the MBO. Right click on the folder “Personalization Keys”> New> Personalization key.
Note: Personalization Keys can be used to set the value of a Load Argument. The Personalization Key needs to be mapped to the Load Argument for this.
11. Give the below details in the Personalization Key window and click on Finish. For HWC apps the PK will not be stored neither in device nor in server, so Transient storage is selected.
12. Map the Personalization Key PK_AirlineID with the Load Argument of MBO.
13. Right click on the project and click on Deploy Project.
14. Click on Next button keeping the default values on the screen. The deploy modes are explained in the wizard.
15. Navigate to screen “Server connection mapping” by clicking Next.
16. Click below Server connection to select/create a new connection.
17. Click on Finish button. It will deploy the MBO package to the Unwired Server. The progress of the deployment can be found in the right bottom of the workspace if the process is happening in the backend, else the process can be seen in a new window.
18. Double click on the SCC icon from desktop and Login to Sybase Control Center to see the package deployed.
Note: Sybase Control Center (SCC) is a Web-based tool for managing and monitoring Sybase Unwired Server. It can accessed via a web browser.
19. Enter the SCC credentials. Username is “supAdmin” and Password is “s3pAdmin”.
20. Navigate to packages under default domain to see the deployed MBO package.
Conclusion
MBO in this project represents a BAPI in SAP. We developed MBO package and deployed it to the Unwired Server. This package will be used by the mobile application to get the data from SAP. In the part 3 we are going to developing HWC application.
Useful information. 🙂 🙂
Thanks,
Soumya Vaishnavi
Hi Midhun,
Thanks for the article. It was very helpful. Is there a way we can develop a HTML5 app in the SUP environment , which is not just a request - response app?
Regards,
Ravi Chaudhary
Hi Midhun
Need help.
Thanks for such a nice article.
i am following your article now i am stuck on point number 12 on personalize Key i am using sql data base to connect on after creating personalize key is not appearing in the
Load argument tab can you guide me.
Regard
Ali
You need to map the load argument with Pk created, click below the header "personalization key" it will give you a drop down>select the Pk you created.
Midhun VP
Thanks Midhun 🙂
can you kindly guide me is there any debug tool in sap for mobile sdk ?
Regard
Ali
If you are looking for HWC debugging, this might help you,
Debugging Sybase SUP HWC Applications
http://www.youtube.com/watch?v=Pp5fmjQXyiY
Midhun VP