POST
|
Thank you :), I've already tried splitting the SQL into separate statements, but didn't remove the semicolon at the end. After I removed it the logic works as expected, without throwing exceptions. Thanks 🙂
... View more
09-22-2022
05:48 AM
|
0
|
0
|
799
|
POST
|
Thanks, I was hoping to do everything with ArcObjects, without installing other libraries.
... View more
09-22-2022
05:45 AM
|
0
|
0
|
800
|
POST
|
Hello! I'm trying to find a way to run SQL statements using ArcObjects from a standalone application. My idea is to create a materialized view in an oracle database, read data from that view, make some calculations and then to export the results to another table. Currently I'm creating the materialized view manually using SQL Developer IDE, before executing the standalone application which will do the rest of the work. I was wondering if it's possible to create the materialized view from the standalone application - using ArcObjects or something else? My SQL looks like this: DROP MATERIALIZED VIEW MV_GIS_SUBAREAS;
CREATE MATERIALIZED VIEW MV_GIS_SUBAREAS
REFRESH ON DEMAND AS
SELECT * FROM GDIM.GIS_SUBAREAS; I've tried to use IWorkspace.ExecuteSQL(), but seems I'm not using it correctly, or the SQL statement, that I'm trying to run, is not supported: string sql = "[ABOVE SQL]";
IWorkspace workspace = Helpers.GetSourceWorkspace();
workspace.ExecuteSQL(sql); I receive the following exception when I run the above code: Underlying DBMS error [ORA-00933: SQL command not properly ended]. I've tried splitting the SQL statements into a separate calls: first dropping the view then creating it, but again in the first call to the ExecuteSQL() it throws the same exception. I'm using ArcGIS 10.8.1 and Oracle 19c. Thanks, Bogdan
... View more
09-21-2022
10:19 AM
|
0
|
4
|
845
|
POST
|
Thanks! I completely forgot about .net framework. Another way to get the directory is by: AppDomain.CurrentDomain.BaseDirectory
... View more
07-28-2021
11:19 PM
|
0
|
0
|
823
|
POST
|
Hello! I was wondering if there is a way to find the directory path where ArcMap is installed. Is there a key in the registry or a method in ArcObjects which can tell me the path to the directory where ArcMap is installed? I've developed an AddIn which is installed on different machines with different configurations - ArcMap is installed in different places. I want to get the path to the addins directory at runtime (ideally located here: C:\Program Files (x86)\ArcGIS\Desktop10.6\bin\Addins). Thanks
... View more
07-28-2021
10:23 AM
|
0
|
2
|
837
|
POST
|
Hello! I have created a custom SOE which receives some data in JSON format and should create new features in an Oracle DB. A service is published with sources pointing to "SDE.DEFAULT" version. There is another version, already created - "SOS.ORDER1" (with parent "SDE.DEFAULT"). My SOE logic should create those new features in version "SOS.ORDER1". I'm using this topic - Editing with the geodatabase API (Connecting to one version and editing another) to develop my logic, but when trying to create new features in a table I'm getting following error: Objects in this class cannot be updated outside an edit session [GDO.O_LINKA]. This is my workflow: IWorkspace workspace = ... // from SOE
// workspace.ConnectionProperties.GetProperty("VERSION") => "SDE.DEFAULT"
// get a reference to the desired geodatabase version
IVersion version = (workspace as IVersionedWorkspace).FindVersion("SOS.ORDER1");
// this should start an editing session in SOS.ORDER1 version
IMultiuserWorkspaceEdit multiuserWorkspaceEdit = version as IMultiuserWorkspaceEdit;
IWorkspaceEdit2 workspaceEdit = version as IWorkspaceEdit2;
multiuserWorkspaceEdit.StartMultiuserEditing(esriMultiuserEditSessionMode.esriMESMVersioned);
// start editing
workspaceEdit.StartEditing(false);
workspaceEdit.StartEditOperation();
// this probably still points to SDE.DEFAULT instead of SOS.ORDER1
ITable table = (workspace as IFeatureWorkspace).OpenTable("GDO.O_LINKA");
// error is thrown here
IRow row = table.CreateRow(); Is there something wrong with this code? After finding the desired geodatabase version and casting it to IMultiuserWorkspaceEdit, workspace still points to "SDE.DEFAULT". How can I properly update the sources to the new version or get a reference to its workspace? I cannot publish a map service with sources pointing to "SOS.ORDER1" and make the edits directly there as there will be many versions, similar to SOS.ORDER1, created programmatically.
... View more
09-20-2019
12:26 AM
|
0
|
0
|
591
|
POST
|
Hello, I had the same issue with reading DWG files using custom SOE and managed to solve it. It turned out that the OpenFromFile() method must be called with directory path not the file path as argument. So instead of: IWorkspace workspace = factory.OpenFromFile(fileName, 0); Try with this: string directoryName = fileName.Substring(0, fileName.LastIndexOf('\\'));
IWorkspace workspace = factory.OpenFromFile(directoryName, 0);
... View more
05-29-2019
01:46 AM
|
0
|
0
|
742
|
POST
|
Hello, I'm trying to add a custom command item to "Enterprise Geodatabase Context Menu" in ArcCatalog using ArcObjects. I was looking for the UID value for this context menu, but can't find it. On that page ArcObjects Help for .NET developers this context menu is missing (I see there only toolbars and menus, not context menus). It is possible to edit command items manually, but I want to do it programmatically. Is it possible to find what is the UID value for this context menu?
... View more
10-20-2015
08:53 AM
|
0
|
0
|
1758
|
POST
|
Thanks for the replay. Yes, you are right, the question is not related to removing the vertex pragmatically, but removing it while the user is drawing in the application using right click of the pointing device. I tried now and it is working, but only in 2D display. When the active display is 3D, right click is rotating the map . I'll try to find out is it possible to disable map rotation in 3D display. Thanks
... View more
09-03-2015
08:00 AM
|
0
|
0
|
627
|
POST
|
Hello, I'm developing add-in for ArcGIS Explorer using SDK build 1500. I'm using BeginTrackPolyline() method (http://help.arcgis.com/en/arcgisexplorer/2500/sdk/componenthelp/index.html#/BeginTrackPolyline_Method_TrackDelegate/000300000r5m000000/ ) from MapDisplay class to track shapes from the screen. This method have a parameter from type TrackStatus enumeration (http://help.arcgis.com/en/arcgisexplorer/2500/sdk/componenthelp/index.html#/TrackStatus_Enumeration/0003000001vn000000/) and as I see there is a member PointRemoved. According to the documentation: A point has been removed from the tracked shape. This happens when the user right-clicks while tracking a shape with more than one vertex (Vector, Polygon, Polyline, Arrow, Circle and Envelope tracking methods). I'm trying to find out how to actually remove a point while drawing, right-click does not work. Is the documentation wrong? Is there another way to remove a point while drawing on the map?
... View more
09-03-2015
06:52 AM
|
0
|
2
|
2962
|
POST
|
Hello, I'm facing a similar problem. I'm trying to find out how to implement snapping functionality while drawing features on the map. Did you found any information about this? It seems that snapping functionality is not included in ArcGIS Explorer.
... View more
08-11-2015
04:48 AM
|
0
|
0
|
362
|
POST
|
Hello, did you find any solution to your problem? I receive the same error for all my layers in the mxd file although I'm following the steps in ArcGIS Documentation I'm unable to export mobile cache. There is no information about this error message and, as always, is general with no useful information.
... View more
08-27-2014
11:58 PM
|
0
|
0
|
264
|
POST
|
Yes, I'm using my own service, not this from the sample.
... View more
02-13-2014
05:27 AM
|
0
|
0
|
754
|
POST
|
Forgot to tell you that I have created and configured my own Network Analyst service and I don't use the one you mentioned. Maybe the problem is with my configuration but I don't know where to look for the problem.
... View more
02-13-2014
04:18 AM
|
0
|
0
|
754
|
POST
|
Hello, I have the same problem. I'm developing a custom tool for finding closest facility (using this example https://developers.arcgis.com/flex/sample-code/closest-facility.htm) and I receive the error when try to solve the task. If I try inside ArcMap, using the same Network Analyst service it is working. I can't find the reason for this, is it some sort of wrong configuration of the Network Analyst service? Thanks
... View more
02-13-2014
12:23 AM
|
0
|
0
|
754
|
Online Status |
Offline
|
Date Last Visited |
09-23-2022
01:48 PM
|