Unable to show RadMap in Usercontrol

5 posts, 0 answers
  1. priya
    priya avatar
    10 posts
    Member since:
    May 2011

    Posted 13 Jun 2011 Link to this post

    Hi,

    I am using a Telerik RadMap control in my web project.

    I have referenced this control using the silverlight xap file inside object element in the usercontrol.
    But i cant see any map.

    When i do the same process in an aspx page , the map displays.

    Would appreciate a quick response.

    Thanks,
    Priya.
  2. priya
    priya avatar
    10 posts
    Member since:
    May 2011

    Posted 15 Jun 2011 Link to this post

    Hi,

    I am in need of the solution urgently.Please help.

    One more try i made today was , when the object element containing Xap file only is added in the usercontrol (no other controls), the map works but when i add it inside my Ajax panel or radpanelbar , it does not show up.

    Thanks,
    Priya
  3. DevCraft banner
  4. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 16 Jun 2011 Link to this post

    Hi Priya,

    Unfortunately it is very complicated and it is hard to reproduce the problem without your solution.
    Most often this problem occurs when you read html-page from your local file system. In this case the security policies do not allow downloading map tiles from Web.

    Greetings,
    Andrey Murzov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. priya
    priya avatar
    10 posts
    Member since:
    May 2011

    Posted 16 Jun 2011 Link to this post

    this is my XAML in silverlight application:

     

    <UserControl x:Class="MyNetworkMap.MainPage"
        xmlns:local="clr-namespace:MyNetworkMap"
        mc:Ignorable="d"
        d:DesignHeight="332" d:DesignWidth="894" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" Loaded="UserControl_Loaded">
      
        <Grid x:Name="LayoutRoot" Background="White" Height="333" Width="960">
      
            <telerik:RadMap x:Name="radMap">
      
                <telerik:InformationLayer x:Name="informationLayer">
                    <telerik:InformationLayer.ItemTemplate>
                        <DataTemplate>
                            <Grid telerik:MapLayer.BaseZoomLevel="{Binding BaseZoomLevel}"
                           telerik:MapLayer.Location="{Binding Location}"
                           telerik:MapLayer.ZoomRange="{Binding ZoomRange}">
                                <telerik:MapLayer.HotSpot>
                                    <telerik:HotSpot X="0.5"
                                               Y="0.5"
                                               ElementName="PART_Ellipse" />
                                </telerik:MapLayer.HotSpot>
                                <Ellipse x:Name="PART_Ellipse"
                                   Width="20"
                                   Height="20"
                                   Stroke="Red"
                                   StrokeThickness="3"
                                   Fill="Transparent">
                                    <ToolTipService.ToolTip>
                                        <ToolTip Content="{Binding Caption}" />
                                    </ToolTipService.ToolTip>
                                </Ellipse>
                            </Grid>
                        </DataTemplate>
                    </telerik:InformationLayer.ItemTemplate>
                </telerik:InformationLayer>
            </telerik:RadMap>
           </Grid>
      
    </UserControl>
      
    this is my ascx code
      
      
      
    <telerik:RadAjaxPanel ID="rapMyNetwork" runat="server">
      
    <table>
      
    <tr>
      
    <td>
      
    <telerik:RadPanelBar ID="MyNetworkPanel" runat="server" ExpandMode="MultipleExpandedItems"
      
    CollapseAnimation-Type="InBack" Width="960px" Font-Size="Large" EnableEmbeddedSkins="False"
      
    Skin="GreatwideSkin12">
      
    <Items>
      
    <telerik:RadPanelItem Expanded="True" Text="My Network" Width="960px">
      
    <ContentTemplate>
      
    </ContentTemplate>
      
    </telerik:RadPanelItem>
      
    </Items>
      
    </telerik:RadPanelBar>
      
    </td>
      
    <td>
      
    </td>
      
    </tr>
      
    </table>
      
    </telerik:RadAjaxPanel>
      
    <div id="Div1">
      
    <object data="data:application/x-silverlight-2," type="application/x-silverlight-2"
      
    width="950" height="333">
      
    <param name="source" value="ClientBin/MyNetworkMap.xap" />
      
    <param name="onError" value="onSilverlightError" />
      
    <param name="background" value="gray" />
      
    <param name="minRuntimeVersion" value="4.0.50826.0" />
      
    <param name="autoUpgrade" value="true" />
      
    <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=4.0.50826.0" style="text-decoration: none">
      
    <img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight"
      
    style="border-style: none" />
      
    </a>
      
    </object>
      
    <iframe id="Iframe1" style="visibility: hidden; height: 0px; width: 0px; border: 0px">
      
    </iframe>
      
    </div>

    This is sample code snippets i have been using.Can u suggest me on the solution with some sample ?
    (I am unable to upload the solution as such.)
    I have been trying to solve this for a long time now.

    Actually what i need is the RAdMap inside the Panel item which doesnt work.

    Thanks,
    Priya

  6. Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 17 Jun 2011 Link to this post

    Hello Priya,

    We have tried to put the control to the HTML page using the code snippet you sent. It works fine.
    To get support on using the Telerik RadControls for ASP.NET you have to start a thread in the corresponding forum. Or you can start a formal support ticket and attach a runnable sample, that reproduces the problem.

    Best regards,
    Andrey Murzov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top
DevCraft banner