dale
Posts: 0
Joined: Fri Mar 29, 2013 5:28 pm

Multi-page and service invocation from js

Hi,

Based on the fact that I writing a small app (3 pages), want faster page loads and know the capabilities of my target platform, I think I've decided to re-write things for a multi-page template.

At the moment, I using onloads on pages to fire functions, though with multipage there's only one call at the start of the app, so I'll need to work things differently.

So I'm thinking, click button, show page (via js) and run service (via js).

I think I read somewhere that a service instance has to be present on a page, in order to be invoked from Javascript, but is this true for multi-page and would the above sequence actually work as the service is invoked after another page is shown?

Thanks,

Dale.

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Multi-page and service invocation from js

Hello!

1) Use page Show event instead of Load;
2) if you add service to each page it won't affect app loading speed.

dale
Posts: 0
Joined: Fri Mar 29, 2013 5:28 pm

Multi-page and service invocation from js

Thanks, do I need to add a service to each page?
Dale.

dale
Posts: 0
Joined: Fri Mar 29, 2013 5:28 pm

Multi-page and service invocation from js

Thanks.

dale
Posts: 0
Joined: Fri Mar 29, 2013 5:28 pm

Multi-page and service invocation from js

R.e. "Use page Show event instead of Load"

I don't have "Show" listed in "Common Events" for the 'landing' page.
I thought you meant use this event to then run the service?

Maybe I'm missing something obvious? Sorry.

Thanks,

Dale.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Multi-page and service invocation from js

Dale,

I meant "Page Show" event. It is on each page.

dale
Posts: 0
Joined: Fri Mar 29, 2013 5:28 pm

Multi-page and service invocation from js

I'm sorry, my fault entirely, I just looked at the list alphabetically ... yes, found it now. Thanks. I'll give it a try.

Return to “Issues”