This is a migrated thread and some comments may be shown as answers.

Can't move the map or see markers.

2 Answers 101 Views
Map
This is a migrated thread and some comments may be shown as answers.
Gonzalo
Top achievements
Rank 1
Gonzalo asked on 15 May 2014, 03:20 PM
Hello,

I just copied the Razor MVC example "basic usage" from the demo page and I can't see the markers.
Aside of that, the map disappears when I tried to navigate with the mouse to another area (image attached).

These is the code I have used:

@(Html.Kendo().Map()
.Name("map")
.Center(30.268107, -97.744821)
.Zoom(3)
.Layers(layers =>
{
layers.Add()
.Type(MapLayerType.Tile)
.UrlTemplateId("http://tile2.opencyclemap.org/transport/#= zoom #/#= x #/#= y #.png")
.Subdomains("a", "b", "c")
.Attribution("&copy; <a href='http://osm.org/copyright'>OpenStreetMap contributors</a>." +
"Tiles courtesy of <a href='http://www.opencyclemap.org/'>Andy Allan</a>");
})
.Markers(markers =>
{
markers.Add()
.Location(30.268107, -97.744821)
.Shape(MapMarkersShape.PinTarget)
.Tooltip(tooltip => tooltip.Content("Austin, TX"));
})
)

Thanks.

2 Answers, 1 is accepted

Sort by
0
Accepted
Hristo Germanov
Telerik team
answered on 19 May 2014, 11:53 AM
Hello Gonzalo,

Could you please double check that your css files are loaded?
You need to load:

Regards,
Hristo Germanov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Gonzalo
Top achievements
Rank 1
answered on 30 May 2014, 10:11 AM
Thanks! I was missing a reference.
Tags
Map
Asked by
Gonzalo
Top achievements
Rank 1
Answers by
Hristo Germanov
Telerik team
Gonzalo
Top achievements
Rank 1
Share this question
or