using ESRI.ArcGIS.Display;
using ESRI.ArcGIS.DisplayUI private esriTOCControlItem toccItem = esriTOCControlItem.esriTOCControlItemNone;
private ILayer iLayer = null;
private IBasicMap iBasicMap = null;
private void axTOCControl1_OnDoubleClick(object sender, ITOCControlEvents_OnDoubleClickEvent e)
{
object unk = null;
object data = null;
if (e.button == )
{
axTOCControl1.HitTest(e.x, e.y, ref toccItem, ref iBasicMap, ref iLayer, ref unk, ref data);
System.Drawing.Point pos = new System.Drawing.Point(e.x, e.y);
if (this.toccItem == esriTOCControlItem.esriTOCControlItemLegendClass)
{
ESRI.ArcGIS.Carto.ILegendClass pLC = new LegendClassClass();
ESRI.ArcGIS.Carto.ILegendGroup pLG = new LegendGroupClass();
if (unk is ILegendGroup)
{
pLG = (ILegendGroup) unk;
}
pLC = pLG.get_Class((int) data);
ISymbol pSym;
pSym = pLC.Symbol;
ESRI.ArcGIS.DisplayUI.ISymbolSelector pSS = new ESRI.ArcGIS.DisplayUI.SymbolSelectorClass();
bool bOK = false;
pSS.AddSymbol(pSym);
bOK = pSS.SelectSymbol();
if (bOK)
{
pLC.Symbol = pSS.GetSymbolAt();
}
this.axMapControl1.ActiveView.Refresh();
this.axTOCControl1.Refresh();
}
}
}

双击axTocControl弹出符号选择器。

最新文章

  1. 我对 Java 标识符的分类命名方法
  2. UVA 10791 Minimum Sum LCM(分解质因数)
  3. Windows 终端服务器授权 激活
  4. android 圆角图片的实现
  5. ActiveMQ学习笔记之异常
  6. android: startActivityForResult用法详解
  7. php 依赖注入
  8. 提高Linux上socket性能
  9. 火狐flash插件
  10. 头文件 boost/cstdint.hpp
  11. 快速实现兼容的js复制方式。有点非正规,通过非正规的排版实现。
  12. Lock锁方式解决线程安全问题
  13. 学Python的感受
  14. 18.4 #if 0…endif的用途
  15. Tomcat:在centos中做成自启动服务
  16. MySQL学习笔记:select语句性能优化建议
  17. wifi
  18. P4745 B’s problem(b)
  19. Java并发编程原理与实战十二:深入理解volatile原理与使用
  20. Eclipes批量创建文件夹

热门文章

  1. freeswitch 注册错误408 - Request Timeout
  2. php的更新
  3. java实现多个数字求和_图形化界面
  4. 【基于mini2440开发板的交叉编译环境及内核树配置.
  5. JavaScript push(),join() 函数
  6. java源码之HashMap和HashTable的异同
  7. Mysql优化之优化工具profiling
  8. Excel数据导入___你hold住么(一)
  9. hello world to php( mac 配置 xmapp virtual host)
  10. POJ 3693 后缀数组+RMQ