Skip to Content
Author's profile photo Former Member

Mobile Application Development Platform for Developers – Native Apps

Building Native Apps with SAP Mobile Platform – Enablement Resources

Overview Admin & Architect Developer Integration Events
Native Apps
iOS | Win | Android
Hybrid Apps

Developing Native Mobile Apps with SMP

The SDK of the SAP Mobile Platform  provides you with tools that streamline the development. One of the most common types are Native Apps: mobile apps developed specifically for one device operating system.

Native apps typically perform better than other application types and provide full access to a device’s hardware.

They are often used for consumer facing apps – when branding and customer satisfaction are of highest priority. As a draw back, native apps have to be re-written for different device technologies, therefore can come at a higher cost.

Our harmonized OData SDK provides an open and flexible framework for native OData application development for both online and offline applications for the most popular devices OS’s: Android, iOS and Windows.

The name “Harmonized” comes from the concept that you can use very similar APIs across different platforms for native and cross-platfom apps, which run on either on-premise version or HANA Cloud Platform Mobile Services. We have different programming languages but ideally we want to use the very similar APIs – hence “harmonized”!

Native Apps by Operating System

/wp-content/uploads/2014/10/idevices_48_562297.png

iOS Apps

As always, the Documentation (SMP 3.0 SDK SP12 for iOS) is a great start to get going.

Next, Ken Unnai wrote an excellent blog series on how to develop native iOS apps with the SMP SDK, including both online and offline scenarios. Read his Introduction and then dive deep:

Online APIs for iOS Apps
Onboarding
Offline APIs for iOS Apps

Bonus Topics

Stan Stadelman has authored a number of technical blogs, one focusing on iOS:


1. In Introduction to HttpConversationManager, and SAML2 Auth in Mobile SDK, Stan describes how this provides a flexible framework for enterprise authentication in your apps.

2. OfflineStore differences from OnlineStore ‘Technical Cache’

Webinar: Online and Offline Apps

In his webinar, Kenichi Unnai covers how to develop online & offline mobile apps for iOS apps (pdf available).

1) Theory – How does the oData Store work

  • Online – 2:20  –  Offline – 5:20

2) How to Implement the oData Store API

  • Online 11:30  –  Offline 15:00
  • Read Entity, Request Fail 19:00
  • Create, Update, Refresh & Flush 23:30

3) Demo

  • Online Store 28:00  – Offline Store 31:00

How-To-Guides

/wp-content/uploads/2014/10/windows_8_smartphone_48_562301.png

Windows Apps

With SMP 3.0 SDK SP5, we have introduced the SDK for Windows apps. Check out the detailed SDK SP5 blog by Product Manager  Kiran Karunakaran. You would also find Documentation (SMP 3.0 SDK SP12 for Windows) very useful to read.

Also, check out the blog series by Milton Chandradas from the Technology RIG team.

Introduction to Developing Windows Apps with SMP

Introduction Video

Recorded Webinar

In this short video, Milton Chandradas shows how to build an app for Windows devices.

Milton goes into more detail in this webinar (Oct 2014), by adding demos and process flow charts to the presentation (pdf available).

  • Overview – SMP & Windows Apps
  • Demo: Setting up the SDK – 10:20
  • On-Boarding Users (Demo) – 14:00
  • HTTP GET Requests (Demo) – 23:00
  • Binding to UI Controls – 34:30
  • CRUD Operations – 37:00
  • Login Operations (Demo) – 43:00

How-To-Guides

/wp-content/uploads/2014/10/android_48_562296.png

Android Apps

Alongside iOS and Windows, the SAP Mobile Platform supports development of native Android Apps with its SDK.

Android Studio

In December 2014, Google launched Android Studio, Google’s official Integrated Development Environment (IDE) based on IntelliJ and it discontinued the Android Developer Tools (ADT) plugin for Eclipse, which means it’s time to leave eclipse behind. Check this blog if you are interested in Migrating Eclipse Based Projects to Android Studio

On-boarding Users onto the SAP Mobile Platform

Before any communication with the SAP backend systems can take place, a mobile app needs to on-board users onto SMP.

You can check the next post for a detailed description of the methods available to registrate in the SMP:

SAP Mobile Platform registration methods available for Android Programming

We support two ways of doing so, and Claudia describes them in her How-To Guides:

  1. MAF Logon Component: The Mobile Application Framework (MAF) contains the MAF logon component that provides easy integration for applications that use logon UI behavior.
  2. OData SDK: Certain use cases require more control over the look and feel of the logon screen or don’t require the logon UI behavior. In these cases, developers can use the SMP 3.0 OData SDK to onboard users


OData Consumption

These How-To Guides by Claudia show the step-by-step procedure on how to code an Android app to consume OData services. The guides use the Flight sample service available in all SAP Gateway installation.


Push Notifications: The SAP Mobile Platform provides native push notification support for major enterprise mobile platforms. This guide discusses enabling push notifications using SAP Mobile Platform, focusing on the specifics of the Android device platform and the Google Cloud Messaging (GCM) service. This guide uses new AppSettings API available to download and upload application setting from and to the Mobile platform.


Troubleshooting

Using the SAP Mobile Platform gives you a number of features, one being ‘supportability’. Claudia has authored two How-To Guides on this topic. Make sure to also check the webinar recording by John Polus, where he explains how Solution Manager can be used for system monitoring.

  • SDK SP05+ How to… Handle Synchronization Errors
    This guide explains how to handle business logic failures during synchronization.
  • SDK SP05+ How To…Write and Upload Client Logs to the SMP Server
    This guide explains how to upload client logs from an Android app to the server for further analysis.
    Log messages allow administrators and support professionals to identify problem areas. Developers can identify code problems by capturing debug level log messages. Set the log level for individual logging components to specify the amount of information captured.


Additional Links


Webinar: On-boarding & Developing Online and Offline Apps

Check the webinar recording below to get started with the SMP 3.0 SDK SP05+ for Android

In her webinar, Claudia Pacheco covers how to onboard users with the MAF Logon component, and how to develop online & offline mobile Android apps (pdf available).

  • Architecture Overview 0:50
  • Onboarding users with MAF 5:00
  • Harmonized OData API
    • Overview 8:40
    • Online 11:30
    • Offline 24:10
  • Demo 42:00

Need a summary? Watch this 6min version!

How-To-Guides (Archive)

As time allows, we will convert eclipse-based projects into Android Studio based project. The following guides represent those ones that have been already replaced.

Brought to you by the SAP Technology RIG and the SAP Mobile Platform SDK Development Team

Assigned Tags

      40 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Added:

      Short video in which Milton Chandradas provides an introduction to building Windows apps with the SMP SDK.

      The recording this week's webinar will follow shortly!

      Author's profile photo Former Member
      Former Member
      Blog Post Author
      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Added:

      Link to the pdf that Milton Chandradas presented in his webinar 'Developing Native Apps for Windows with the SMP SDK

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      added:

      Link to Claudia Pacheco's How to Guide about On-boarding Users to native Android apps, using the Logon Component

      Author's profile photo Former Member
      Former Member
      Blog Post Author
      Author's profile photo Former Member
      Former Member
      Blog Post Author

      added: link to the presentation that Kenichi Unnai used for his webinar on offline and online iOS apps.

      Author's profile photo Former Member
      Former Member
      Blog Post Author
      Author's profile photo Former Member
      Former Member
      Blog Post Author
      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Added:

      Link to recording of Claudia Pacheco's webinar "Native Android Apps: Onboarding and Developing online & offline apps", as well as a blog on onboarding users with the iOS SDK (onboarding with MAF was published already)

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      The PDF for Claudia Pacheco's webinar is now available as well

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Added:

      6min summary of Claudia's Android webinar.

      Author's profile photo Kenichi Unnai
      Kenichi Unnai

      Added:

      For iOS, Blog 13: How-To-Guide

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Added: a lot of goodness by Claudia Pacheco in the form of new How-To Guides for Android apps (you find links in the Android section of this document).

      This includes:

      • A new H2G for onboarding with MAF log-on component, now with a link to github where you can download an example / template
      • OData Consumption for online and offline mode
      • Pushnotifications
      • Troubleshooting
      Author's profile photo Former Member
      Former Member

      Will the sample applications from Github (e.g SAP/sap_mobile_native_android · GitHub) run against HCP Mobile Services without modification? Providing the application configuration and services match etc.

      Author's profile photo Jeff Gebo
      Jeff Gebo

      Hi Gregor,

      yes, providing everything matches with config/security they should work. To be honest, we haven't tested it yet but in theory it should work fine.

      Cheers,
      Jeff

      Author's profile photo Former Member
      Former Member

      This documents and sample code is Using MAF UI libraries(LogonUIFacade). But i want to consume API's using MAF Core libraries(Without using LogonUIFacade). I am searching for last 2 days. I couldn't found any solution for the same.

      Please provide me any documentation or sample code to consume API's Using MAF Core libraries.

      Regards,

      Surya prakash

      Author's profile photo Kenichi Unnai
      Kenichi Unnai

      Which platform are you referring to?

      Author's profile photo Former Member
      Former Member

      Hi Ken,

      I am referring to Android platform.

      Author's profile photo Claudia Pacheco
      Claudia Pacheco

      Hi Surya,

      Have you looked at this guide How To... On-board users with SMP 3.0 OData SDK (Android)?

      It does not use the LogonUIFacade, instead it uses MAF core libraries: LogonCore and LogonCoreContext to onboard users.

      Author's profile photo Kenichi Unnai
      Kenichi Unnai

      Added:

      Performance Tuning with Offline Store (Relevant for all the platform)

      Author's profile photo Former Member
      Former Member

      Hi  Kenichi Unnai

      Thanks for the blogs, and I have implemented the On-boarding application and successfully registered the device in COCKPIT, In the next series of levels you are using RMTSAMPLEFLIGHT  service as back end, But I don't have the SAP  NetWeaver  Gateway, So is there any possibility to access the external service here to access the flight sample application.

      iOS Simulator Screen shot Apr 2, 2015, 5.06.34 PM.png

      Thanks in advance 🙂 ,

      VK.

      Author's profile photo Jeff Gebo
      Jeff Gebo

      Hi VK,

      you can use the sample gateway services:

      SAP Netweaver Gateway Demo System The Flight Service is available there. That said, they don't support create, update or delete...only reading data.

      That said, those are on the internet, so you might need to configure a proxy if your SMP server is inside your corporate network. Also, these sample GW services are over https, this will require you to get the certificate and import it into the Java Key Store of your SMP server.

      Hope this helps.

      Jeff

      Author's profile photo Former Member
      Former Member

      Awesome

      Thanks a lot for sharing this.


      Regards,

      Hossam

      Author's profile photo Kenichi Unnai
      Kenichi Unnai
      Author's profile photo Former Member
      Former Member

      Hi there I wanted to ask about he user experience with mobile application development with SMP.

      Author's profile photo Former Member
      Former Member

      Hi All,

      I have encountered a problem when using MAF to do Onboarding service.

      The Andriod app cannot start up. I raise a fatal error:Cannot find class "com.sap.maf.tools.logon.logonui.BackendPassChangeDialog".

      I use the SMP3.0 SP05, and the maflogonui version is 1.205.1.

      Someone one could help me?

      Except that when I using Native OData SDK, I cannot register successfully.

      I have register to hcpms successfully by using REST Client.

      Author's profile photo Claudia Pacheco
      Claudia Pacheco

      Hi Frankie,

      The error is indicating you are not including all the required libraries and resources. could you please double check the guide How To... Setup MAF resources in Android Studio

      Best regards,

      Claudia

      Author's profile photo Former Member
      Former Member

      Ok Claudia,

      I have followed this guide.(How To... Enable User On-boarding using MAF Logon (Android))https://scn.sap.com/docs/DOC-59006

      It is using eclipse,maybe different from android studio. I would try android studio.

      Thanks for your reply.

      Author's profile photo Claudia Pacheco
      Claudia Pacheco

      Hi Frankie,

      Eclipse and Android Studio are completely different, android developers you should be moving to Android Studio sooner rather than later. Having said that, the guide you mentioned should work as well.

      I would suggest creating a discussion on SCN in the "SMP developer center" space. Attach screenshots of your project libraries and resources, so the community (including me) can help you resolve the problem with your dependencies.

      Best regards

      claudia

      Author's profile photo Hemendra Sabharwal
      Hemendra Sabharwal

      Dear Experts,

      I have the performance issues in SMP-Native Android App, kindly provide your valuable inputs on the same. Please find the thread details for your kind considerations:

      How to handle performance in SMP3.0 - Delayed time in OData response

      Thanks,

      Warm Regards

      Hemendra

      Author's profile photo Jitendra Kansal
      Jitendra Kansal
      Author's profile photo Masoud Eb
      Masoud Eb

      Hi All

      please some one tell me ,is that work on windows mobile 6.1 ?

      my client use SAP ERP 6.0 / NW7.01

      I want develop windows mobile App with C# and read and Write directly to SAP..

      Author's profile photo Milton Chandradas
      Milton Chandradas

      The Windows SDK does not support Windows Mobile 6.1. 

      You could however try using .NET to make direct HTTP calls, since everything is based on OData standards.  Please note that you cannot use this approach for offline functionality.

      Author's profile photo Masoud Eb
      Masoud Eb

      Hi Milton

      thanks for your reply

      I want work Offline ... whats your Proposal?

      Author's profile photo Milton Chandradas
      Milton Chandradas

      SMP 2.3 using the MBO model...

      Author's profile photo Former Member
      Former Member

      Hey, it's not specific to SAP technologies, but I just published this blog post on SCN about iOS development tools that might be interesting to some of you here: Much Loved Tools of an iOS Developer | SCN.

      Author's profile photo Kenichi Unnai
      Kenichi Unnai

      Can you post the question in the forum? Posting the q here won't make the QA searchable for other folks.

      Author's profile photo Kenichi Unnai
      Kenichi Unnai

      Please find "Start a discussion" link on the right side: SMP Developer Center

      Author's profile photo Peter Csontos
      Peter Csontos

      Hi All,
      Documentation has moved to a new platform, here you can find the link to the most recent SP14 version (URLs for documentation of earlier versions still work):
      https://uacp2.hana.ondemand.com/doc/d9c75eebcfa840c8a4aa4b0e6a8136de/3.0.14/en-US/dc74ea98916d4baf9780bbcd929c1a9f.html
      Best regards,
      Peter

      Author's profile photo Jitendra Kansal
      Jitendra Kansal

      Hello Peter,

      this new documentation link is for latest Mobile SDK SP14 right?
      For older versions, i have to refer help.sap.com ?

      Regards,
      JK