Custom Map User Icon

To custom the default User Icon on a Map i added a marker and used this blocks:

But this happens:

How can I fix it / solutions?

The custom image is plotting at 0 deg. latitude and 0 deg. longitude in the Atlantic Ocean.

The gps initially does not know where it is at so your code plots the 0,0 defautl. It needs to get a satellite fix to determine where it is at before plotting the location of your device. Read the tutorial and use the two aia files to see how the tool works. You need to place the Marker1 into the Location1.LocationChanged event handler before it will post your current location. ::

2 Likes

Ty, I'll try :slight_smile:

sorry im having difficulties

and what are these difficulties? What have you coded and what happens? If you do not share your code and explain the problem, unfortunately no one can help. :frowning_face:

blocks (3)

So I have this blocks and i tried your print screen solution but I think that it does not work :frowning:

Can you send the tutorial?

You do not show ALL the blocks you used. That makes it impossible to show you what might need to be changed in the code you are using. I don't have access to your Project. What have you coded and what happens?

The code I originally showed on May 6 included the Block set Map1.ShowUser to true. Evidently it is impossible to display the custom Marker when ShowUser is true. It hides the image of the set Marker1.ImageAsset to Block if the custom image is set to the device's current lat/lon . Consequently the ImageAsset will not display in your situation but it does work if the developer doesn't use the ShowUser option.

Said simply, do not use the ShowUser and set it to true as your custom marker for the user's location, otherwise the ImageAsset will not display. I guess that is your issue now?

The original code snippet I displayed works well if you do not use ShowUser and the Marker is not the user's location . (other locations work OK). I didn't expect using ShowUser to do this having never used ShowUser and with the Marker ImageAsset for the same location.

Try these Blocks. You must first modify the Marker1.ImageAsset to the name of your custom image (set it to whatever image you have in Media and replace my firetruck.png image).

After about 20 seconds of starting the app you should see your green image at your device's location.

1 Like

Map.aia (2.8 MB)

Ty for the explanation, this is my project!