|
POST
|
Hi, About how to import a rptx file programatically. Have you tried Project AddItem method? var reportToAdd = ItemFactory.Instance.Create(pathToRPTXFile);
QueuedTask.Run(() => Project.Current.AddItem(reportToAdd as IProjectItem));
... View more
03-21-2022
08:05 AM
|
1
|
1
|
2248
|
|
POST
|
Hi, I think you must change two cycles by places: using (Row row = rowCursor.Current)
{
var topHz = Convert.ToInt32(row["hzdept_r"]);
var bottomHz = Convert.ToInt32(row["hzdepb_r"]);
foreach (var compPct in compPcts)
{
rowCursor.Current can be read once.
... View more
03-21-2022
05:19 AM
|
0
|
0
|
959
|
|
POST
|
Two way binding is in RemoveAddins sample <ListBox Height="185"
ScrollViewer.VerticalScrollBarVisibility="Auto"
ScrollViewer.HorizontalScrollBarVisibility="Disabled"
ItemsSource="{Binding AddIns, Mode=TwoWay}"
ItemTemplate="{StaticResource AddInItem}"
SelectionMode="Multiple">
<ListBox.ItemContainerStyle>
<!-- This Style binds a ListBoxItem to a the ViewModelItem. -->
<Style TargetType="ListBoxItem">
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
</Style>
</ListBox.ItemContainerStyle>
</ListBox> Try to check all other settings of listbox. One of them could be ItemTemplate="{StaticResource AddInItem}". They use template for listbox item. You can do the same.
... View more
03-14-2022
08:06 AM
|
0
|
1
|
2120
|
|
POST
|
Hi, The faster way is to make icons yourself from your printscreens. Cut pieces 16x16 or 32x32 (depending on real icon size) with Windows Paint. Save as pngs. Add to your Visual Studio project. Edit them in Visual Studio by changing format to 32bppBGRA. Using eraser tool make space around icon picture transparent. Depending where and how you want to use icon set Build action.
... View more
03-14-2022
08:02 AM
|
1
|
1
|
1149
|
|
POST
|
Hi, I think the problem is with one way binding of LayersFiltered. Try to set two ways as in sample: ItemsSource="{Binding LayersFiltered, Mode=TwoWay}
... View more
03-14-2022
07:29 AM
|
0
|
3
|
2125
|
|
POST
|
Hi, Corehost supports access to GDB and Geometry only. CoreHost application cannot use many of the constructs provided by the ArcGIS.Desktop dlls
... View more
03-14-2022
06:36 AM
|
1
|
0
|
1256
|
|
POST
|
Hi, I think you need to rotate geometry first (before creating cimGraphicElement). It could be done by using GeometryEngine Rotate method. More info here: https://pro.arcgis.com/en/pro-app/latest/sdk/api-reference/#topic8281.html
... View more
03-13-2022
11:20 PM
|
1
|
1
|
1530
|
|
POST
|
Hi, In both cases sde and gdb you should use the same way to get table names. Only database opening differs. // For sde
DatabaseConnectionFile connector = new DatabaseConnectionFile(new Uri(sdePath));
// For gdb
FileGeodatabaseConnectionPath connector = new FileGeodatabaseConnectionPath(new Uri(gdbPath));
// coomon part
using (Geodatabase gdb = new Geodatabase(connector))
{
var defs = gdb.GetDefinitions<TableDefinition>();
foreach (var d in defs)
{
string dsName = d.GetName();
// your code here
d.Dispose();
}
}
... View more
03-10-2022
03:04 AM
|
1
|
6
|
3045
|
|
POST
|
Stop debugger before calling Search. Copy routesQueryFilter.WhereClause value from Watch window to clipboard. Finish your tool work. Open the featureClassOpenedAsTableRoute table in ArcGIS Pro table view and try Select by Attribute with whereclause string from clipboard. Check before that SQL query type is on. If result still 0, try create query with query builder and check for differences
... View more
03-09-2022
06:41 AM
|
1
|
1
|
2542
|
|
POST
|
Hi, The answer could be: no records matching to your query filter. You can check it by adding code line before calling Search method. var count = featureClassOpenedAsTableRoute.GetCount(queryFilter); Count must be equal 0 in your case.
... View more
03-09-2022
05:54 AM
|
0
|
3
|
2553
|
|
POST
|
Hi, Look at the sample here: https://github.com/Esri/arcobjects-sdk-community-samples/blob/master/Net/Server/ServerSimpleSOAPSOE/Readme.md
... View more
03-08-2022
07:11 AM
|
0
|
0
|
875
|
|
POST
|
Sorry. I think you will understand that you can select layer by query directly. Full code for your realization could be like this: private async Task DeletePolygonInPolygon(CancelableProgressorSource cps, uint steps, FeatureLayer polygonLayer, QueryFilter queryFilter)
{
await QueuedTask.Run(async () =>
{
polygonLayer.ClearSelection();
var polyCursor = polygonLayer.Search(queryFilter);
cps.Progressor.Max = (uint)steps;
cps.Progressor.Message = "Probíhá ";
List<Row> features = new List<Row>();
while (polyCursor.MoveNext() && !cps.Progressor.CancellationToken.IsCancellationRequested)
{
cps.Progressor.Value += 1;
cps.Progressor.Status = cps.Progressor.Value + @" z " + cps.Progressor.Max + @" hotovo.";
var lineFeature = polyCursor.Current as Feature;
var polygonGeometry = lineFeature.GetShape() as Polygon;
long oid = polyCursor.Current.GetObjectID();
var spatialQuery = new SpatialQueryFilter()
{ FilterGeometry = polygonGeometry, SpatialRelationship = SpatialRelationship.Within };
spatialQuery.WhereClause = "OBJECTID <> " + oid;
polygonLayer.Select(spatialQuery, SelectionCombinationMethod.Add);
}
object[] listOfPara = { polygonLayer };
await StartATask("management.DeleteFeatures", listOfPara);
}, cps.Progressor);
}
... View more
03-07-2022
11:54 PM
|
1
|
2
|
2178
|
|
POST
|
Hi, For your solution it is better to use "customControl" as in sample RibbonControls . You have to copy all controls you need from docpane xaml to custom control xaml and all code related to xaml to custom control viewmodel.
... View more
03-07-2022
10:30 PM
|
0
|
0
|
5005
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | Tuesday | |
| 1 | Tuesday | |
| 2 | 04-24-2026 08:33 AM | |
| 1 | 03-23-2026 11:44 AM | |
| 1 | 05-22-2024 11:48 PM |
| Online Status |
Online
|
| Date Last Visited |
Tuesday
|