POST
|
Hello all, I am working on a research project for tunnelling in which I have to use winforms as input pages through configuration add-in but I am having a problem with winforms. When I click an add-in button and the winform pops up it doesn't let me add the text into the text boxes. I have checked and readonly property for the text box, it is set to false. I cannot figure out the problem. Kindly help me with this issue. Picture added are showing before the map load and after the map load states.
... View more
02-26-2020
03:17 AM
|
0
|
2
|
948
|
POST
|
Hello, I am trying to run a Feature class to Feature class conversion tool for a CAD imported file. But I am running into an error I am not aware of. Error comes from Value array, might be from the database connection but I am unable to understand the reason behind it. I have attached the screen shots for the given problem, code snippet for geoprocessing tool and a helper for datasource connection. Thanking for the possible help.
... View more
11-16-2019
03:06 AM
|
0
|
0
|
396
|
POST
|
Thanks for the help. I will look into it and if any problem occurs, I will ask here. Thanks again.
... View more
10-25-2019
05:54 PM
|
0
|
0
|
836
|
POST
|
Hi, I am working on a project with two main add-in modules, that contain many tools and buttons. One module is Excavation and the other is tunnelling. I want to activate and deactivate the add-in tools based on the module selection. for example if I select tunnel module then excavation module add-in tools should be deactivated and vice versa. If someone can guide me about how to execute this customization, it would be very helpful. Thank in advance.
... View more
10-21-2019
07:40 PM
|
0
|
2
|
1013
|
POST
|
Hello, I have a grid points layer. I want to select all the features within the layer without actually selecting from the map. Then using inspector I want to insert the values in the columns or field in the attribute table. I know how to select the features under geometry but without geometry I am struggling. Also I can add field in the attribute table but unable to find the way to insert values in the fields. Requesting a kind help. Thanks.
... View more
06-07-2019
08:53 AM
|
0
|
0
|
491
|
POST
|
Thanks, I will try your code and let you know if I need further assistance. Thanks again.
... View more
05-29-2019
11:55 PM
|
0
|
0
|
1797
|
POST
|
Thanks Gintautas Kmieliauskas, Can you please explain it a little. what is "featureClass" and "fidIndex"? and coordinates data is not stored in the attribute table? how can we retrieve coordinates from attribute table then? the double value looks like the object id?
... View more
05-29-2019
11:40 PM
|
0
|
2
|
1797
|
POST
|
In my add-in project I have many layers (points, polylines, polygons). I want to get the coordinates of a feature selected from any feature layer in the list through a map tool and show into the text boxes of a winform. Until now I could only find a sample to return the coordinates of a point clicked on the map.
... View more
05-29-2019
07:00 PM
|
0
|
4
|
3186
|
POST
|
Thanks, Uma I will try this and I would like to bother you if further help required.
... View more
04-11-2019
06:34 AM
|
0
|
0
|
593
|
POST
|
Thanks, Bill I will try this and I would like to bother you if further help required.
... View more
04-11-2019
06:34 AM
|
0
|
0
|
593
|
POST
|
Hello, I have to build an add-in for ArcGIS Pro, I know that I have to use Pro SDK. But for start up I need an exe file that initiate a process to ask for required layer files to be loaded, when I give the files these files automatically open in ArcGIS Pro within a new map project. What should I do for this? I can make an add-in but how do I make an exe file that starts ArcGIS Pro on click? does the Runtime SDK supports this kind of functionality? P.S: I am doing this on C# platform using VS 2017.
... View more
04-08-2019
06:54 PM
|
0
|
4
|
698
|
POST
|
Hello, I have to build an add-in for ArcGIS Pro, I know that I have to use Pro SDK. But for start up I need an exe file that initiate a process to ask for required layer files to be loaded, when I give the files these files automatically open in ArcGIS Pro within a new map project. What should I do for this? I can make an add-in but how do I make an exe file that starts ArcGIS Pro on click? does the Runtime SDK supports this kind of functionality? P.S: I am doing this on C# platform using VS 2017.
... View more
04-08-2019
06:40 AM
|
0
|
2
|
367
|
POST
|
Hello all, I am working on an add-in that calculates the ground deformations induced due to underground tunnel. After that I have some buildings (Polygon feature layer) on the surface that are prone to damage by the deformations. I am calculating the damage and for assessment purpose, based on calculated damage for each building I want to fill in different colours in different building polygons. Currently I applied buffer for convenience but buffer colours all the polygons at once and also, I cannot change the buffer colour as well. If someone can help that will be helpful. the lower picture shows the buffered buildings along the tunnel route. private async void button1_ClickAsync(object sender, EventArgs e) { Strain(); string layerName = "BuildingsD"; var sectionLayer = MapView.Active.Map.GetLayersAsFlattenedList().FirstOrDefault((lyr) => lyr.Name.StartsWith(layerName)) as FeatureLayer; if (sectionLayer == null) { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show("Buildings not found"); //return; } else { try { string st_in = Convert.ToString(sectionLayer); //string st_out = "BuildingD_Buffer"; //string Distance = "Field, OBJECTID"; var args = Geoprocessing.MakeValueArray(st_in, null, @"7 Meters"); string tool_path = "analysis.Buffer"; IGPResult ret = await Geoprocessing.ExecuteToolAsync(tool_path, args/*, envArray*/); if (ret.IsFailed) { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show($@"Error {ret.ErrorCode} in GP Tool: {ret.ErrorMessages}"); } } catch (Exception) { } The above code I used to buffer the buildings but I can't get how do I select individual building and fill the colour or change the buffer colour for the selected building feature.
... View more
01-07-2019
12:51 AM
|
0
|
0
|
355
|
POST
|
Yes, I already checked out my csv file. It worked in the toolkit. I somehow changed the code and it is working. try { string st_in = @"C:\Users\Aizaz\Documents\ArcGIS\Projects\MyProject\new.csv"; string st_out = @"C:\Users\Aizaz\Documents\ArcGIS\Projects\MyProject"; //var envArray = Geoprocessing.MakeEnvironmentArray(null); var args = Geoprocessing.MakeValueArray(st_in, "Lat", "Long", st_out, "", "Settlement"); string tool_path = "MakeXYEventLayer_management"; IGPResult ret = await Geoprocessing.ExecuteToolAsync(tool_path, args); if (ret.IsFailed) { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show($@"Error {ret.ErrorCode} in GP Tool: {ret.ErrorMessages}"); } // var rset = Geoprocessing.ExecuteToolAsync(tool_path, args, null, null, GPExecuteToolFlags.Default); } catch (Exception) { } Can you give your comments about this, why the error was happening in the previous code?
... View more
12-10-2018
01:07 AM
|
0
|
1
|
1185
|
POST
|
Hello, I have created a .csv file through following code. public void CreateCSV(DataTable dataTable, string filePath, string delimiter = ",") { if (!Directory.Exists(System.IO.Path.GetDirectoryName(filePath))) throw new DirectoryNotFoundException($"Destination folder not found: {filePath}"); var columns = dataTable.Columns.Cast<DataColumn>().ToArray(); var lines = (new[] { string.Join(delimiter, columns.Select(c => c.ColumnName)) }) .Union(dataTable.Rows.Cast<DataRow>().Select(row => string.Join(delimiter, columns.Select(c => row )))); File.WriteAllLines(filePath, lines); } File created successfully and I can manually load and make XY to Point conversion using Geoprocessing tool. It also goes successful but when I try to achieve this through C# code it gives the following error. GP tool code is given below try { string st_in = @"C:\Users\Aizaz\Documents\ArcGIS\Projects\MyProject\new.csv"; string st_out = @"C:\Users\Aizaz\Documents\ArcGIS\Projects\MyProject\Settlement_m"; //var envArray = Geoprocessing.MakeEnvironmentArray(null); var args = Geoprocessing.MakeValueArray(st_in, "Long", "Lat", "Settlement", st_out, ""); string tool_path = "XYTableToPoint_management"; IGPResult ret = await Geoprocessing.ExecuteToolAsync(tool_path, args/*, envArray*/); if (ret.IsFailed) { ArcGIS.Desktop.Framework.Dialogs.MessageBox.Show($@"Error {ret.ErrorCode} in GP Tool: {ret.ErrorMessages}"); } var rset = Geoprocessing.ExecuteToolAsync(tool_path, args, null, null, GPExecuteToolFlags.Default); } catch { } Any idea what this error means? because I cannot find anything about it in ArcGIS Pro examples or online resources etc.....
... View more
12-08-2018
09:09 PM
|
0
|
0
|
464
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:25 AM
|