|
POST
|
Hi Drew, In ArcGIS Pro1.4 there was no way to get statistics about raster except using geoprocessing. This is a part of code I use in my application: var parameters = Geoprocessing.MakeValueArray(raster, "MINIMUM"); var environments = Geoprocessing.MakeEnvironmentArray(workspace: sWorkspace); return Geoprocessing.ExecuteToolAsync("GetRasterProperties_management", parameters, environments, CancelableProgressor.None, GPExecuteToolFlags.AddToHistory); The worst thing that you can get only one type of statistics at time. To get "MAX" you need to call geoprocessing another time with "MAX" parameter. ArcGIS Pro 2.0 has raster object, but I have not checked if it has statisrtics like IRaster in ArcObjects.
... View more
10-06-2017
01:29 AM
|
0
|
3
|
4464
|
|
POST
|
Hi Thomas, I have a good news for you. I have found workaround for featureclasses but it works with rasters too. Change your workflow upside down and it will work: 1. Create layer from lyrx ( LayerFactory.Instance.CreateLayer(new Uri(uri), map); ). 2. Change created layer datasource to your raster datasource ( rasterLayer.SetDataConnection(updatedDataConnection); ). 3. Clear cache ( rasterLayer.ClearDisplayCache(); ) There is ArcGIS Pro sample how to change datasource. I hope it will help you.
... View more
08-07-2017
05:53 AM
|
2
|
1
|
4772
|
|
POST
|
Hi Thomas, I am not alone Worst thing is that I have tried to make the same workflow from code but without success. That's why I reported bug, sent peace of code and etc. They agreed that it does not work. I have reported many issues before 2.0 release (1.4.1 and 2.0 Beta) and thought that they will be fixed, because solution must be one line of code or something like that. But ... One bug they closed with explanation that it was fixed in 2.0. I have checked and it is not. Geonet is not the right place to report problems. I think the fastest way to have solution is to report the same bug from different users. Please contact your Esri distributer or your company GIS administrator and you will get access to create cases for Esri software issues. This way is not very simple. You must document each case, workflow, data... This way is our chance to solve our problems.
... View more
07-28-2017
11:53 AM
|
1
|
0
|
4772
|
|
POST
|
Hi Charles, Thank you for the explanation. I have wrote method void RunOnMCTThread(Action action) using your information and it works fine.
... View more
07-27-2017
11:40 PM
|
0
|
0
|
1764
|
|
POST
|
Hi, Some ArcGIS Pro samples ( Framework\DockPaneBookmarkAdvanced or Framework\DockpaneSimple) have Utils class with different implementations of RunOnUiThread and IsOnUiThread methods. I thought that it could be useful when you call some methods which must be called on MCT from different places. Sometimes you are on MCT, sometimes not. I have tried methods from both projects, but I failed. IsOnUiThread always said that code is on UI thread, but really it was not. So I started investigate why sample code works, but my not. I have looked at the methods which were used with RunOnUiThread and found that all of them use QueuedTask.Run inside. I have commented QueuedTask.Run and samples failed too. Maybe I didn't understood the working RunOnUiThread functionality or it is bug?
... View more
07-27-2017
05:25 AM
|
0
|
2
|
2337
|
|
POST
|
Hi Thomas, There are many problems with the GeoProcessing Tool "Apply Symbology From Layer" especially from API. Some problems are related to display cache. I reported them to Esri support and they marked them as bugs. That tool in 1.4.1 worked better than in 2.0 (I mean from API). To check if problem related to cache make following workflow: 1. After applying lyrx from API open layer properties 2. Goto Cache tab. 3. Clear cache 4. Set "Don't cache any data locally". 5. Press OK and close layer proeprties
... View more
07-19-2017
11:38 PM
|
1
|
2
|
4772
|
|
POST
|
Hi Vladislav, I think supports. We are using in our ArcGIS Pro addins interop for c++ library
... View more
07-04-2017
07:04 AM
|
0
|
0
|
1013
|
|
POST
|
Group object property appearsOnAddInTab must be set to false
... View more
07-04-2017
02:46 AM
|
1
|
0
|
1061
|
|
POST
|
Hi Max This is a peace of code from snippets (look at notes): https://github.com/esri/arcgis-pro-sdk/wiki/ProSnippets-Raster // Create a FileGeodatabaseConnectionPath using the path to the gdb.
// Note: This can be a path to a .sde file.FileGeodatabaseConnectionPath geodatabaseConnectionPath = new FileGeodatabaseConnectionPath(new Uri(@"C:\Temp\rasters.gdb"));// Create a new Geodatabase object using the FileGeodatabaseConnectionPath.Geodatabase geodatabase = new Geodatabase(geodatabaseConnectionPath);
... View more
07-03-2017
04:40 AM
|
1
|
0
|
1655
|
|
POST
|
Laurentiu, You must use DatabaseConnectionProperties only to find right geodatabase from 1 step. Then you need to read Path property from GDBProjectItem. It contains full path to sde file. I can send you detailed source code sample if you need.
... View more
06-23-2017
12:11 AM
|
0
|
7
|
4172
|
|
POST
|
I would like to reuse query definition building dialog in my application to let user build your own query to collect objects for calculations. That whereclause string will be frequently used and will be saved to database to remember. So customer do not need to make selection by attribute each time. ArcGIS Pro layer Properties command has property page for building queries. Is there API to use that dialog? It is possible to use query definition building dialog from ArcMap ArcObjects.
... View more
06-15-2017
07:59 AM
|
0
|
3
|
1540
|
|
POST
|
Laurentiu, I had the same problem with sde file path. I have made workaround: 1. Read all project geodatabases using Project.Current.GetItems<GDBProjectItem>(). GDBProjectItem contains Path property. 2. Read connection properties from your table object (pTable.GetDatastore().GetConnector() as DatabaseConnectionProperties). 3. Check all GDBProjectItem's from 1 step by comparing connection properties (item.GetDatastore().GetConnector() and try cast to DatabaseConnectionProperties). Equal method does not work for Connector or DatabaseConnectionProperties objects, so you need to check all DatabaseConnectionProperties object properties (DBMS, Database, Instance and etc.) one by one. I hope it helps you Gintautas
... View more
06-15-2017
07:39 AM
|
2
|
1
|
4172
|
|
POST
|
I am looking for equivalent of ArcObjects ILayer Valid method which indicates if the layer is currently valid: http://desktop.arcgis.com/en/arcobjects/latest/net/webframe.htm#ILayer_Valid.htm
... View more
05-18-2017
06:41 AM
|
0
|
0
|
848
|
|
POST
|
I have found that I can use ItemFactory, to create Item from raster path. If there is no raster at specified path then ItemFactory.Create(sResultRaster) returns null. I have noticed too that ArcGIS Pro remembers many different info about your used data. So if you deleted some data using ArcMap or ArcCatalog, but your opened ArcGIS Pro thinks that data still exist and successfully creates Item object and etc. After restarting ArcGIS Pro all goes fine. I think it is not so good thing.
... View more
05-03-2017
07:12 AM
|
0
|
1
|
889
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 2 weeks ago | |
| 1 | 3 weeks ago | |
| 1 | a month ago | |
| 1 | a month ago | |
| 1 | 12-02-2025 11:07 PM |
| Online Status |
Offline
|
| Date Last Visited |
yesterday
|