Asp.Net引用Arcengine提供后台GIS服务
来源:互联网 发布:win10网络唤醒关闭 编辑:程序博客网 时间:2024/06/04 19:05
Web前台使用地图瓦片,JS拼装;后台使用asp.net引用Arcengine提供GIS服务。
1. 简单点查询
(1)引用
using ESRI.ArcGIS.Geodatabase;
using ESRI.ArcGIS.DataSourcesFile;
using ESRI.ArcGIS.esriSystem;
(2)ArcEngine的Licence认证
IAoInitialize m_AoInitialize = new AoInitializeClass();
esriLicenseStatus licenseStatus = esriLicenseStatus.esriLicenseUnavailable;
licenseStatus = m_AoInitialize.Initialize(esriLicenseProductCode.esriLicenseProductCodeEngine);
(3)空间查询或属性查询
IFeatureClass featureClass = null;
IWorkspaceFactory pWorkspaceFactory = new ShapefileWorkspaceFactoryClass();
IWorkspace pWorkspace = pWorkspaceFactory.OpenFromFile("E://shp//shp", 0);
string LayerName="×××";
featureClass = pWorkspace .OpenFeatureClass(LayerName);
ESRI.ArcGIS.Geometry.Point point = new ESRI.ArcGIS.Geometry.PointClass();
point.X = 100;
point.Y = 200;
ISpatialFilter spatialFilter = new SpatialFilterClass();
spatialFilter.Geometry = point;
spatialFilter.GeometryField = "shape";
spatialFilter.SpatialRel = esriSpatialRelEnum.esriSpatialRelIntersects;
//IQueryFilter queryFilter = new QueryFilterClass();
//queryFilter.WhereClause = "FID=90";
int index = featureClass.Fields.FindField("字段名");
IFeatureCursor featureCursor;
featureCursor = featureClass.Search(spatialFilter, false);
IFeature feature = featureCursor.NextFeature();
while (feature != null)
{
this.Label1.Text = feature.get_Value(index).ToString();
feature = featureCursor.NextFeature();
}
- Asp.Net引用Arcengine提供后台GIS服务
- asp.net的前台引用后台变量
- asp.net的前台引用后台变量
- asp.net的前台引用后台变量
- asp.net引用后台代码块
- asp.net的前台引用后台变量
- asp.net的前台引用后台变量
- asp.net的前台引用后台变量
- asp.net的前台引用后台变量
- ASP.NET后台为移动端提供接口
- 使用ASP.NET做android的后台服务
- ArcEngine引用
- ASP.NET提供程序
- asp.net调用远程Web_Service(服务引用方式)
- asp.net 后台计算器
- ASP.NET提供程序模型
- ASP.NET提供程序模型
- ASP.NET - 配置文件提供程序
- gvim使用心得
- 排序系列之(1)归并排序及C语言实现
- odbc如何读取foxpro的标记删除的记录?
- flex 各组件对应的样式属性
- HermesJMS配置
- Asp.Net引用Arcengine提供后台GIS服务
- 怎样在EVC4.0下编程实现音频和视频文件的的播放
- Delphi 中使用 ADO 方法打开 MySQL5.0 数据库并避免汉字乱码
- Spring框架的主要功能
- mp4文件格式解析(一)
- MTK平台 获取本机的SIM卡中IMSI号
- CString ,BSTR ,LPCTSTR之间关系和区别
- zju2736水仙花数
- 设置超链接格式