IDEA
|
At now the ITableSort interface can only be used to sort tables that have an ObjectID field. Obviously any table can be sorted by some field, sorting should not require any specific field to proceed. It would be great if this limitation of the ITableSort will be removed.
... View more
01-28-2017
12:28 AM
|
2
|
0
|
444
|
BLOG
|
In 1.4 you've added some controls: Coordinate System Picker Coordinate Systems Details Control Burger Button Circular Animation Control ProWindow Message Label Waiting Cursor Control But help pages for every new control don't have any images. It would be much better if developers know what particular control is and how it looks like before using it at their projects.
... View more
01-28-2017
12:10 AM
|
0
|
0
|
560
|
POST
|
Just cast your layer to IFeatureLayerDefinition2 and set its DefinitionExpression property. This property is actually the same thing that you set via layer's properties definition query. var featureLayerDefinition = featureLayer as IFeatureLayerDefinition2;
if (featureLayerDefinition != null)
featureLayerDefinition.DefinitionExpression = $"Num = '{comboBox2.Text}'";
... View more
01-25-2017
07:05 AM
|
2
|
0
|
895
|
POST
|
I'm building an ArcMap extension. In its Startup method I subscribe to IApplicationStatusEvents.Initialized event. In handler of this event I use some methods of GPUtilities class: public class SomeExtension : IExtension
{
#region COM Registration Function(s)
[ComRegisterFunction]
[ComVisible(false)]
private static void RegisterFunction(Type registerType)
{
ArcGISCategoryRegistration(registerType);
}
[ComUnregisterFunction]
[ComVisible(false)]
private static void UnregisterFunction(Type registerType)
{
ArcGISCategoryUnregistration(registerType);
}
#region ArcGIS Component Category Registrar generated code
/// <summary>
/// Required method for ArcGIS Component Category registration -
/// Do not modify the contents of this method with the code editor.
/// </summary>
private static void ArcGISCategoryRegistration(Type registerType)
{
string regKey = string.Format(CultureInfo.InvariantCulture, "HKEY_CLASSES_ROOT\\CLSID\\{{{0}}}", registerType.GUID);
MxExtension.Register(regKey);
}
/// <summary>
/// Required method for ArcGIS Component Category unregistration -
/// Do not modify the contents of this method with the code editor.
/// </summary>
private static void ArcGISCategoryUnregistration(Type registerType)
{
string regKey = string.Format(CultureInfo.InvariantCulture, "HKEY_CLASSES_ROOT\\CLSID\\{{{0}}}", registerType.GUID);
MxExtension.Unregister(regKey);
}
#endregion
#endregion
// ...
void IExtension.Startup(ref object initializationData)
{
// ...
var application = initializationData as IApplication;
bool initialized = true;
var applicationStatus = Application as IApplicationStatus;
if (applicationStatus != null)
initialized = applicationStatus.Initialized;
var applicationStatusEvents = Application as IApplicationStatusEvents_Event;
if (applicationStatusEvents != null && !initialized)
applicationStatusEvents.Initialized += ApplicationInitialized;
else
ApplicationInitialized();
// ...
}
private void ApplicationInitialized()
{
// ...
var gpUtilities = (IGPUtilities3)Activator.CreateInstance(Type.GetTypeFromCLSID(typeof(GPUtilitiesClass).GUID));
IGPParameter gpParameter = new GPParameterClass();
gpUtilities.PackGPValue(new DEFeatureClassClass(), gpParameter); // This line causes Metadata tools are broken
// ...
}
// ...
} Steps to reproduce the problem: open ArcMap with closed or folded (not pinned) ArcToolbox window; open AcrToolbox; now all tools from the Metadata toolset are broken (they have red cross icon and cannot be opened and executed). But if on the first step you open ArcMap with opened and shown ArcToolbox then everything is fine, Metadata tools are valid and can be executed. If I comment line #74 in the code snippet above then everything is fine too. It seems that GPUtilities must be used only after ArcToolbox is shown. This strange behavior started to appear with ArcMap 10.4. So 10.4, 10.4.1 and 10.5 has this problem. In 10.3.1 all is OK. I believe that this is bug on ArcGIS side, so I really hope that it will be fixed. I didn't find any workaround for this issue. Maybe with 10.4.1 I need to execute some magic code before I can use GPUtilities so Metadata tools will not be broken?
... View more
01-23-2017
08:53 PM
|
1
|
2
|
1646
|
POST
|
Hi Narelle, I've updated my first post. I've added sample data and test code along with images showing input data and expected result.
... View more
01-19-2017
07:18 PM
|
0
|
0
|
2203
|
POST
|
Hi Narelle, Thanks for reply. Let me know if you need test data or more details.
... View more
01-18-2017
07:51 PM
|
0
|
0
|
2203
|
POST
|
Hi, I'm building custom geoprocessing tool where output value can be feature class or table with GPFeatureSchema as default schema. But the type of an output dataset depends on some option. In tool's UpdateParameters method I change schema of the output parameter to GPTableSchema or to GPFeatureSchema. But in Model Builder any tool after the my one always thinks that my tool produces feature classes. Is it possible to dynamically change type of schema so chained tools get right output information from my tool?
... View more
01-16-2017
10:45 PM
|
0
|
0
|
727
|
POST
|
Hi Laurentiu, Values of BLOB fields are returned as COM objects now, so it seems that support of BLOBs editing is not implemented in current version (1.4) of the ArcGIS Pro SDK. I hope ESRI team working on ArcGIS Pro SDK will pay attention to this bug. Max
... View more
01-15-2017
10:43 PM
|
0
|
0
|
2155
|
POST
|
I'm trying to split a polygon by multipart polyline (created from multiple polylines with GeometryEngine.Union) using GeometryEngine.Cut method expecting multiple (more than 2) geometries as the result. But I get empty collection... In ArcObjects I can do this easily with ITopologicalOperator4.Cut2 method. Test data is attached – Data.gdb.zip. If you execute this code you'll get an empty collection as the result of GeometryEngine.Cut method. using (var geodatabase = new Geodatabase("Data.gdb"))
{
// Construct unified line to cut by
var lines = new List<Polyline>();
using (var linesFeatureClass = geodatabase.OpenDataset<FeatureClass>("Lines"))
using (var linesCursor = linesFeatureClass.Search())
{
while (linesCursor.MoveNext())
{
var polyline = GeometryEngine.SimplifyAsFeature(((Feature)linesCursor.Current).GetShape(), true) as Polyline;
lines.Add(polyline);
}
}
var unifiedLine = GeometryEngine.SimplifyAsFeature(GeometryEngine.Union(lines), true) as Polyline;
// Get polygon to be cut
Polygon polygon = null;
using (var polygonsFeatureClass = geodatabase.OpenDataset<FeatureClass>("Building_pol"))
using (var polygonCursor = polygonsFeatureClass.Search())
{
while (polygonCursor.MoveNext())
{
polygon = GeometryEngine.SimplifyAsFeature(((Feature)polygonCursor.Current).GetShape(), true) as Polygon;
break;
}
}
// Cut polygon by unified line
var parts = GeometryEngine.Cut(polygon, unifiedLine); // parts will be empty collection
} Input data: Expected result:
... View more
01-13-2017
11:04 PM
|
0
|
7
|
3582
|
POST
|
I see you've added the GeometryEngine.GetSubCurve method in 1.4. Thank you.
... View more
01-13-2017
07:15 PM
|
1
|
0
|
879
|
POST
|
EditOperation.ShowProgressor property doesn't work. I set it to false but progress dialog is shown anyway. I saw your code with dotPeek and came to this awful workaround: var editOperationType = typeof(EditOperation);
var progressorProperty = editOperationType.GetProperty("CancelableProgressor", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic);
if (progressorProperty != null)
progressorProperty.SetValue(operation, CancelableProgressor.None); Can you fix EditOperation.ShowProgressor property logic?
... View more
01-13-2017
01:18 AM
|
0
|
2
|
2104
|
POST
|
Dataset.GetDatastore method returns UnknownDatastore for shapefile datasets while Shapefile is expected. It was so in 1.3 and still is in 1.4
... View more
01-13-2017
12:58 AM
|
0
|
1
|
1224
|
POST
|
I found that PolylineBuilder throws the AccessViolationException when the builder is used after multiple Dispatcher.Invoke calls. If I use BeginInvoke instead of Invoke, everything goes fine, so it is the workaround. But I believe you should fix this problem. I've attached VS solution with simple test add-in (TestAddIn.zip) and test data (test.gdb.zip, place it in Debug folder after solution building). This test add-in contains one button (Click Me!) which opens a dialog. In this dialog click the Start button and you'll get AccessViolationException at line #35 in FeatureClassIterator.cs file.
... View more
12-05-2016
07:27 PM
|
0
|
2
|
2067
|
POST
|
Sean, Thanks for reply. I hope this functionality will appear in the next release of the ArcGIS Pro SDK.
... View more
11-17-2016
07:43 PM
|
0
|
0
|
772
|
Title | Kudos | Posted |
---|---|---|
1 | 09-25-2018 09:14 AM | |
1 | 11-20-2017 12:35 PM | |
1 | 02-16-2017 08:55 PM | |
1 | 11-18-2017 06:15 AM | |
1 | 01-13-2017 07:15 PM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|