ArcEngine的问题
private void query1(IFeatureLayer pf, string where, IColor ic)
{
IFeatureSelection pFeatureSelection = pf as IFeatureSelection;
//创建过滤器
IQueryFilter pQueryFilter = new QueryFilterClass();
//设置过滤器对象的查询条件
pQueryFilter.WhereClause = where;
//选择要素
pFeatureSelection.SelectFeatures(pQueryFilter, esriSelectionResultEnum.esriSelectionResultNew, false);
//获取选择集对象
ISelectionSet pSelectinSet = pFeatureSelection.SelectionSet;
/*-begin---------*/
ISimpleFillSymbol iFillSymbol;
ISymbol iSymbol;
iFillSymbol = new SimpleFillSymbol();
iFillSymbol.Style = esriSimpleFillStyle.esriSFSSolid;
iFillSymbol.Outline.Width = 12;
iFillSymbol.Color = ic as IRgbColor;
iSymbol = (ISymbol)iFillSymbol;
//设置选择集的符号
pFeatureSelection.SelectionSymbol = iSymbol;
/*-end---------*/
}
begin end 中间的这段代码没效果
我想实现把查询到的内容给他变个颜色,把边去掉 该怎么做呢。 --------------------编程问答-------------------- iFillSymbol.Outline.Width = 0; // 去掉边框
iFillSymbol.Color = ic as IRgbColor; // 定义一个新的IColor对象,修改颜色 --------------------编程问答-------------------- 使用IFeatureSelection.SelectionSymbol,之前需要设置IFeatureSelection.SetSelectionSymbol为True --------------------编程问答-------------------- 学到了很多的东西!
补充:企业软件 , 地理信息系统