|
POST
|
Bert, Not having the original dataset to interrogate makes it difficult to answer why the code version reports a different row count. I note that that the screen shot from ArcCatalog shows the cell size to be not symmetrical. This could be the source of the error? Maybe the algorithm behind the code version computes the row count based upon cell size and extent of dataset? This is the only thing I can think of. You can test this with a dataset that has a more typically symmetrical cell size. Create a raster using the Create Raster Dataset tool so you know you are creating a grid that conforms to the esri standard and compare the different row count techniques. Duncan
... View more
11-28-2012
11:58 PM
|
0
|
0
|
1803
|
|
POST
|
Bert, Not tried it but I guess your rlyr object is a RasterLayer object? If so this interface actually has a row count method called...wait for it... RowCount! Duncan
... View more
11-28-2012
01:30 PM
|
0
|
0
|
1803
|
|
POST
|
Here is one for the developer gurus... I'm using ArcMap 10.1 and developingi in visual studio 2010 VB .net. I create a form, drop a button on it, drop a tooltip control on it and under the properties of the tooltip control I can set the properties ToolTipIcon to Info and ToolTipTitle which gives me a nice professional looking tooltip to aid my users. Now for an ESRI AddIn button I can set the tooltip text in the Config.esriaddinx file as shown below: <Button id="GDI_btnPointAnalysis" class="btnPointAnalysis" message="Point Analysis Tools." caption="Point Analysis Tools" tip="Point Analysis Tools" category="Tools" image="Icons\AnalysisDS.bmp" onDemand="false"/> Is there anyway to add an info icon and title just like my button on my form? Duncan
... View more
11-28-2012
08:06 AM
|
0
|
0
|
2195
|
|
POST
|
You could just use Quantum GIS, it's completely free... Have a look here
... View more
11-23-2012
06:23 AM
|
0
|
0
|
1425
|
|
POST
|
Simon, Have you tried looking at the Help in ArcMap, at some point you are going to have to... There is lots of information about creating watershed boundaries. Duncan
... View more
11-17-2012
10:03 AM
|
0
|
0
|
1114
|
|
POST
|
Armin, I'm curious, how did you determine it was the IDataStatistics interface that was causing you problems, you say it runs OK then crashes, what made you decide it was that and not something else? I only ask as I am having a 10.1 addin I am creating crashing with a heap corruption error at seemingly random times. It's such a catastrophic error that none of my error-trapping catches it, ArcMap simply bombs out to Windows. Duncan
... View more
11-09-2012
06:12 AM
|
0
|
0
|
2606
|
|
POST
|
Domenico, Thank you for your reply. I've had a look at the links. I now know that QueryFilterClass is a managed class but I am unsure why one would create it? Is it best practise to now use a managed class for say memory issues? Why should I stop creating my QueryFilter class and start creating QueryFilterClass classes? Duncan
... View more
11-09-2012
12:34 AM
|
0
|
0
|
1735
|
|
POST
|
All ArcObject Gurus, For years when I've been developing ArcObjects VB code to create a QueryFilter I have used the following to create the object: Dim pQueryFilter As IQueryFilter pQueryFilter = New QueryFilter I'm now redeveloping a 9.3 project into 10.1 using Visual Studio 2012 (VB). When I look at the code snippet examples I now see: Dim pQueryFilter As IQueryFilter pQueryFilter = New QueryFilterClass If one looks at the help file on IQueryFilter Interface it says only the class QueryFilter implements the IQueryFilter interface (as well as a bunch of other classes) but no mention of the QueryFilterClass. If I change my code to use QueryFilterClass everything compiles as normal. So what is the difference, is there some reason why ESRI are showing snippet examples with this class? Is there some sort of performance issue? Duncan
... View more
11-08-2012
05:53 AM
|
1
|
3
|
3481
|
|
POST
|
Harry, Are you showing the complete code in your uploaded sample? If you search the Help file for FieldInfo the example given in the help shows that this object is obtained via the Describe Object. Maybe your fieldInfo object is invalid? Duncan
... View more
11-04-2012
09:46 AM
|
0
|
0
|
1407
|
|
POST
|
David, Just to clarify when you say "in memory layer", are you saying you have created a FeatureClass in an InMemoryWorkSpace? FYI I knocked together some code in VBA on a FeaturelClass in the in_memory workspace which I created using the Table Select tool. My code worked fine and the only difference I can see is that you are not setting the QueryFilter. This code worked for me: Public Sub test()
Dim pMXDocument As IMxDocument
Set pMXDocument = ThisDocument
Dim pMap As IMap
Set pMap = pMXDocument.FocusMap
Dim pLayer As ILayer
Set pLayer = pMap.Layer(0)
Dim pFeatureLayer As IFeatureLayer
Set pFeatureLayer = pLayer
Dim pFeatureClass As IFeatureClass
Set pFeatureClass = pFeatureLayer.FeatureClass
Dim pTable As ITable
Set pTable = pFeatureClass
Dim pTableSort As ITableSort
Set pTableSort = New TableSort
With pTableSort
.Ascending("Strahler") = False
Set .Table = pTable
Set .QueryFilter = Nothing
.Fields = "Strahler"
.Sort Nothing
End With
' Get sorted cursor and write to debug window
Dim pCursor As ICursor
Set pCursor = pTableSort.Rows
Dim pRow As IRow
Set pRow = pCursor.NextRow
Do While Not pr Is Nothing
Debug.Print pRow.Value(pRow.Fields.FindField("Strahler"))
Set pRow = pCursor.NextRow
Loop
End Sub Duncan
... View more
11-04-2012
06:35 AM
|
0
|
0
|
1087
|