Hi I was wondering how can I store the values of “lat” and “long” in a table?
Thanks
Hi I was wondering how can I store the values of “lat” and “long” in a table?
Thanks
Never mind, I finally did it. The mistake I made was that I did not treat the data from the event block as a text string.
All I did was create a list from the data and then split it using the “,”
I spoke too soon, I just faced another issue. The coordinates are meant to be integers but since I am extracting the values a string, it does not work on map.
How can I convert them to Integers?
Try assigning a string to a variable block, and then use some suitable mathematical block to perform an operation on this variable, for example, add its value with the value 0.
mama mia nice hack. That worked
I was trying to make mine work but screen 3 doesn’t open with these blocks (starting from screen 2, clicking the callout on the map). I was trying to understand what data the “event” gives. Eventually I want to change screen3 based on a local database list (which restaurant is chosen from the map).
Please take a look at my previous post in this thread (here) for some info on how to properly obtain longitude and latitude for the onPress
, onMarkerPress
and onLongPress
event handlers of the Map component. Note that onCalloutPress
appears to not work at all
-Mark
Thanks for your reply Actually I got onCalloutPress to work with the below blocks. It does save the latitude value of a marker to the local storage. Next problem is how to do a vlookup formula using the latitude value in local_db and returning another field in the spreadsheet. I can only find instructions if the choice is made in a list viewer… how to do that using a local storage value?
Frozen Aloha,
It’s not totally clear to me what you are trying to do. It seem as if you want to lookup a latitude value in one column of your local_db and then return another column in the same row of that local_db. Is that right?
By the way, I strongly suggest using stored variables instead of the Local Storage component. It’s generally much easier to use. Here are some blocks which demonstrate how you can use them when the variable name (which is essentially the same as the key for the Local Storage component) is not necessarily fixed.
In the above example the "test"
block could be replaced with something that is looked up or calculated dynamically.
-Mark
These blocks doesnt work now. whats wrong?
but when I do below it gets longitude or latitude.
Try this
This works. Thanks.
i have searching on all over thunkable community,
actualy it’s same method… but why on mine is not working…
i always got “null” on nativeEvent…
There seems to be a bug that makes the Coordinate Object only available once. Therefor the solution of @actech is a workaround by storing the value and retrieving the information from the stored object afterwards