Arcgis (2) 썸네일형 리스트형 [Add-in] 인쇄용 template 자동으로 적용하기 public override void OnClick() { IGxFile gxFile = new GxMapClass(); gxFile.Path = System.IO.Path.Combine(AppInfo.StartupPath, "Layout", "AgriculturalMap.mxd"); IGxMapPageLayout gxPageLayout = (IGxMapPageLayout)gxFile; IPageLayout pageLayout = gxPageLayout.PageLayout; IMxDocument mxDocument = (IMxDocument)m_application.Document; pageLayout.ReplaceMaps(mxDocument.Maps); mxDocument.PageLayout = pag.. [Add-In] FeatureLayer의 Datasource를 바꾸는 코드 public static void SetDataSource(IMap p_map, string p_layerName, string p_featureClassName) { IMapAdmin2 mapAdmin = (IMapAdmin2)p_map; IFeatureClass newFeatureClass = GetFeatureClassByName(p_featureClassName); if (newFeatureClass == null) return; ILayer layer = GetLayerByName(p_map, p_layerName); if (!(layer is IFeatureLayer)) return; IFeatureLayer featureLayer = (IFeatureLayer)layer; IFeatureCl.. 이전 1 다음