[Resolved] Issues while using addIconMarker and addPolyline Map Blocks - April 2022

This is my last post about this app, I swear :slight_smile:


When I open the map, the app crashes.
I did the following:
-checked the variable"alarma" and its properties(they’re all fine, so the problem is not there)
-checked other things(everyting is functional until I “call Map1’s addIconMarker”
-set the value of the latitude and longitude to numbers(converted from strings by using mathematical blocks)
Something still seems to be wrong. Why is that?

1 Like

Use direct number that you have in the latitude and longitude

image

Thank you, but I have to use the numbers I have stored in the firebase.

2 Likes

Can you show an image of your Firebase numbers?
If it works with direct numbers but not with the stored numbers then you already localized the problem.

4 Likes

Can you explain a little more about why are you using a local variable to get a value from a cloud variable?

3 Likes

image
Here I displayed the values in the alert, so you can see that they are correct.

And the thing is, it doesn’t work with direct numbers either(it still crashes).

1 Like

Sure! Those values that are to be stored are taken from another user.


(this is from another screen)
When one user clicks a button, that variable will create an object with the coordinate fields. Those are going to be used to add a map marker, in another user’s map. Basically, this should be a location tracker.

First of all, thank you for the videos but they do not show any map in the project and second anything to do with maps need to be run from the mobile not from the computer.

Can you please record another video showing the map in the screen and clicking the option to add the marker?

1 Like

Sure,

This is with numbers.

1 Like

This is what causes the crash
image

Try to remove them and test and it should work OK without crashing.

no :(. still crashes.

1 Like

Make sure the cloud variable for the description is not NULL or currently just replace it with with direct text.

It’s not null. Replaced it anyways, and it still crashes.
https://x.thunkable.com/projects/6249a0ec5ce74e0012aeab52/c69dba59-a384-4cfa-8772-749a57bb0308/blocks
If it helps, here is a link to the project.

I know @muneer is helping you with this but I took a look at the project and I’m wondering which screen you’re having problems with?

1 Like

“main screen voluntar”
the one with the map component.

Not that easy @tatiang
To go through his project you need to connect it to Firebase and then create a key with the User ID that you will login with and in that key create another key called branch with content voluntar to be able to reach the page when you login.

image

After doing so, the next issue is the project does not allow anything with the Map component.

I also created a simple project just a map and a button to click to add a Marker but it failed.

I wonder if this has to do with the recent changes that @jared, @jared mentioned

:open_mouth: I see what you mean. Not sure I have the time for all that right now but hopefully you’ll make some progress.

1 Like

Can you guys check this out?
https://x.thunkable.com/projectPage/621ce2f3819ba7026ee6e069

1 Like

It crashes every time.

Super strange. I get no errors. Im going to ping some teammates!

2 Likes