Willie Sims
Posts: 0
Joined: Wed Jul 10, 2013 4:37 pm

Marker From Local storage

can't figure out what I am doing wrong, I have created a clickable list that passes to a details page, then added a map it button on that page to go to a map page,
I can see the local storage for lat and long stored and passed to the map page

I did a on load set property , Marker , Latitude, bind to local varible and the same for name, longitude and added a button with a click event to refresh but it will not show the location

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Marker From Local storage

Hello Willie!

Do you have checked Show marker in the map Properties?

The following references are useful:
http://docs.appery.io/tutorials/build...
https://getsatisfaction.com/apperyio/...

Willie Sims
Posts: 0
Joined: Wed Jul 10, 2013 4:37 pm

Marker From Local storage

yes the marker is visible,
The issue is that I am not trying to show multiple markers only the marker corresponding to the list item
http://appery.io/app/mobile-frame?src...

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Marker From Local storage

Hi Willie -- are you refreshing map in the end like shown here?

Willie Sims
Posts: 0
Joined: Wed Jul 10, 2013 4:37 pm

Marker From Local storage

Yes, I have the event set to the button click,
The set properties for Latitude and longitude bind to local storage are set to fire on screen load.
I don't get it

Willie Sims
Posts: 0
Joined: Wed Jul 10, 2013 4:37 pm

Marker From Local storage

Mr Stepanov
This is getting very aggravating this should be a simple deal, I can see the local storage variables are loaded and have used the set property-marker-
name, Latitude and Longitude all bound to the Local storage and then set the map it button on click event run java script code var map = Appery('Map');
map.options['address']='';
map.refresh();
/code
But all that happens is it goes back to the default location

maxkatz
Posts: 0
Joined: Fri Aug 13, 2010 3:24 pm

Marker From Local storage

Click the map in builder and take a screen shot for us. Make sure it includes the properties window.

Willie Sims
Posts: 0
Joined: Wed Jul 10, 2013 4:37 pm

Marker From Local storage

I tried to change tack and see if this would work but still no luck
code

//get map
var map = Appery('Map');

//get lat,longt
var latiTude = localStorage.getItem('lat');
var longtiTude = localStorage.getItem('lon');

//set new location
map.setProperty('latitude',latiTude);
map.setProperty('longitude',longtiTude);

//reset address property
map.setProperty('address','');

//refresh map
map.refresh();
/code
set on mapit button click

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Marker From Local storage

Willie - please check if you added a geolocation service in your app -- I can't see it's launched a location service in a browser.

Return to “Issues”