zoukankan      html  css  js  c++  java
  • Load map with popups(代码好像有问题!!!)

     1 using System.Windows;
     2 using System.Windows.Controls;
     3 using System.Windows.Media;
     4 using ESRI.ArcGIS.Client;
     5 using ESRI.ArcGIS.Client.WebMap;
     6 
     7 namespace ArcGISSilverlightSDK
     8 {
     9     public partial class WebMapNotesPopups : UserControl
    10     {
    11         public WebMapNotesPopups()
    12         {
    13             InitializeComponent();
    14 
    15             Document webMap = new Document();
    16             webMap.GetMapCompleted += webMap_GetMapCompleted;
    17 
    18             webMap.GetMapAsync("2ccf901c5b414e5c98a346edb75e3c13");
    19         }
    20 
    21         void webMap_GetMapCompleted(object sender, GetMapCompletedEventArgs e)
    22         {
    23             if (e.Error == null)
    24             {//发现下面代码并没有起到什么作用?????
    25                 foreach (Layer layer in e.Map.Layers)
    26                 {
    27                     if (layer is GraphicsLayer)
    28                     {
    29                         GraphicsLayer glayer = layer as GraphicsLayer;
    30                         // Modification of the default map tip style
    31                         Border border = glayer.MapTip as Border;
    32                         if (border != null)
    33                         {
    34                             border.Background = new SolidColorBrush(Color.FromArgb(200, 102, 150, 255));
    35                             border.CornerRadius = new CornerRadius(4);
    36                         }
    37                     }
    38                 }
    39                 LayoutRoot.Children.Add(e.Map);
    40             }
    41         }
    42     }
    43 }
  • 相关阅读:
    03_Redis数据类型(List)
    02_Redis数据类型(String、Hash)
    01_Redis基础
    22_AOP_切面——静态切面
    21_AOP_Advice增强2(异常、引介)
    20_AOP_Advice增强1(前置、后置、环绕)
    19_AOP概述
    18_CGLib动态代理
    利用NTP搭建自己的ntp服务
    VM设置BIOS延长时间
  • 原文地址:https://www.cnblogs.com/rockman/p/3342008.html
Copyright © 2011-2022 走看看