Tag Info

Hot answers tagged

4

IQueryFilter is the best option for your problem.You can put your name value in the whereclause of the queryfilter and thereby you can get the desired feature. ESRI.ArcGIS.Geodatabase.IQueryFilter queryFilter = new ESRI.ArcGIS.Geodatabase.QueryFilterClass(); queryFilter.WhereClause = "NAME LIKE 'LIGHT_POLE'; ESRI.ArcGIS.Geodatabase.ICursor cursor = ...


2

This is just conjecture, but there is probably some variable-width text measurement logic going on behind the scenes, and the character W was probably chosen because it is one of the widest characters available in variable-width fonts. I agree that it is a bit nonsensical to do it this way.


2

I found a work around to this by using Rick Brewster's suggestions. First, I modified Rick's class by adding a constructor public ToolStripEx() : base() { } Then in my dockable window's designer class "MyClass.Designer.cs" I changed the toolstrip's declared type from System.Windows.Forms.ToolStrip to ToolStripEx. Next, in the InitializeComponent() method ...


2

The best option is to use a query to get back the corresponding feature: IQueryFilter queryFilter = new QueryFilterClass(); queryFilter.WhereClause = "NAME = '<featureName>'"; using (ComReleaser comReleaser = new ComReleaser()) { ICursor cursor = table.Search(queryFilter, true); comReleaser.ManageLifetime(cursor); IRow row = null; while ((row ...


1

This post might help and here is a getting started section in the official API page on the ESRI support site.


1

Try using IEnumLayer interfase: IEnumLayer pEnumLayer; pEnumLayer = map.Layers; layer = pEnumLayer.Next(); while (layer != null) { flayer = (IFeatureLayer) layer;


1

IEnumLayer will build an index for you when you initialize it. It indexes all layers in the order that they appear in the TOC (the top layer will be index 0, the next down will be 1, etc). You can use this index as your key as it will always be unique to the layer. Here's the code to initialize and access in ArcGIS Desktop: ...


1

That string represent the maximum length of string that you can show on that combo-box.That mean if it shows "WWW" you can add items of maximum 3 character.If you entered otherwise the arc-map split that string by the maximum length and balance will shown as next item.This also mentioned in Add-in _wizard. See image below


1

I also had significant 9.3 code that needed to be upgraded. The good news is that, although some conversion is necessary, it's not difficult. Firstly you need to get your hands on Visual Studio 2010 if you don't already have it... the Express version works just fine but make sure you're not breaking some licensing restriction by using that version. Other ...


1

Here are couple of Google searches that explain what it is: http://www.functionx.com/win32/Lesson08.htm http://msdn.microsoft.com/en-us/library/aa979055%28v=vs.71%29.aspx#feedback From what I understand (and could be wrong) its just a number that is used to indicate what the parent window is. So I don't think you can use it to control the visibility of ...


1

The following code zooms to the extent of the polygon in the map then fits the whole page in page layout. This code gets the polygon and rotates it back to the horizontal (approximately 35° in my example) and then zooms to the extent of that rather than the original polygon extent which is much larger if the rectangle is rotated. Public Sub Zoom() Dim ...


1

polyline.splitAtDistance doesn't actually split a polyline. All you have to do is cast your IFeature as IFeatureEdit and use the method IFeatureEdit.Split(). This will create two separate features.


1

It is very unlikely that the in memory workspace is implemented in similar fashion to an on-disk one. Instead of having a persistent storage with IWorkspace, IFeatureClass etc mapped to on-disk structures IName.Open creating new ArcObjects that map to them, they will just be implementations in memory. IName.Open could just return a reference to the existing ...



Only top voted, non community-wiki answers of a minimum length are eligible