cancel
Showing results for 
Search instead for 
Did you mean: 

How to create session variable in SUP 2.2?

Former Member
0 Kudos

Hi, this is my first time develop a hybrid mobile app. I have a lot of things which I am unsure about this software. I would like to create session variable so that i can pass those values to the next page by just calling this session variable. Can anyone guide me how to do so?

Regards,

Theary

Accepted Solutions (1)

Accepted Solutions (1)

former_member186566
Active Participant
0 Kudos

Hi Theary,

In hybrid application data will be stored in Message value collection object, by extracting this we can retrieve and display it in screens.

You can do this in custom.js file. it will have set of before and after methods. use beforenavigationforward method to implement your functionality. refer the below link for retrieving data.

Hybrid App Message Data Functions

Refer the example2 in the above example. By simple document getelement java script methods you can display it in screen.

If you are completely new to this development please refer the below links.

Sample application - http://scn.sap.com/docs/DOC-8803

MBO development - http://infocenter.sybase.com/help/topic/com.sybase.infocenter.dc01208.0224/doc/html/aro1369939412683...

Hybrid app development - Develop MBO-based Hybrid Apps

Regards

Yokesvaran Kumarasamy

Former Member
0 Kudos

Hi Yokesvaran Kumarasamy,

Thanks for these useful info links.

Regards,

Theary

Answers (4)

Answers (4)

former_member186566
Active Participant
0 Kudos

Hi Theary Phalla

is this issue resolved? Close this ticket if it is resolved

How to close a discussion and why

Regards

Yokesvaran Kumarasamy

midhun_vp
Active Contributor
0 Kudos

Have a look at this tutorial,

- Midhun VP

Former Member
0 Kudos

Hi Midhun VP,

Thanks for these useful tutorials

Regards,

Theary

Former Member
0 Kudos

Hi Theary,

Typically, the mobile frameworks used (e.g. JQuery Mobile, Sencha) in the mobile applications, uses ONE html page, so there is no passing of variables from page to page.  What you typically do to mimic page navigation is to show and hide <div>s on the single HTML page.  Therefore, one JavaScript variable you have in the HTML page is accessible in the different <div>s on the same page.

You can see the generated JavaScript from the Hybrid App Designer as an example.  This is using JQuery Mobile by default.

Thanks,

Andrew.

Former Member
0 Kudos

Hi Andrew,

Thanks for your info

Regards,

Theary

former_member186566
Active Participant
0 Kudos

Hi Theary,

Are you developing Web application or Mobile application in SUP 2.2?

Mobile device will handle the sessions in mobile application, we dont do the sessions. More over we cant copy the URL and execute in other browser to fake the session in mobile applications, whereas you can do this in web application. But mobile apps are not URL based. so its not required.

If its a web application, you must depend on server side scripting to define sessions.

Regards

Yokesvaran Kumarasamy

Former Member
0 Kudos

Hi Yokesvaran kumarasamy,

I am developing a mobile app in SUP 2.2. It is my first time trying to develop a mobile app that's y there are a lot of things i am unsure about. Anyway thanks for your info. But if i want to pass values to the other page, may i know how to do that?

Regards,

Theary