|
POST
|
Hi, I have developed a Arcobjects Tool to fill the titlebar of an .mxd on Visual Studio 2010, the tool works fine. but I am having difficulty deploying this tool to be used in another system directly on ArcMap Please guide me in deplying this command tool..... Santosh V GIS Engineer Pixel Softek PVT LTD
... View more
04-04-2012
08:12 AM
|
0
|
1
|
536
|
|
POST
|
Hi, I have placed the map control inside the busy indicator, its busy till the map loads completely.. Now I want to add a cancel button in the busy indicator and stop the loading of the map when clicked on that button I used a toolkit:BusyIndicator.BusyContentTemplate and added a cancel button and put BusyIndicator.isBusy = false in its click event but the map loading does not cancel and it stays busy What am I missing here Please guide.....
... View more
04-02-2012
06:05 AM
|
0
|
0
|
354
|
|
POST
|
Well I found out the solution here it is If you want the area of the part that is inside the envelope you have to query with esriSpatialRelOverlaps or esriSpatialRelInstersects and perform a clip operation on all the returned geometries using ITopologicalOperator.Clip against the envelope. If you are using another geometry than an envelope to clip against you should be using ITopologicalOperator.Intersect. As always whe performing geometrical operations you should ensure that both geometries have the same spatial reference.
... View more
03-30-2012
03:27 AM
|
0
|
0
|
757
|
|
POST
|
Hi I had a task to get the area of the feature polygon within a boundary So I got the envelope of the boundary and did a spatial query to get the features inside that Boundary but my problem is I am able to get the elements that overlaps the envelope but not exactly inside it.. the polygon is not clipping to the envelope my code goes like this IMxDocument mxDoc = (IMxDocument)GetMxDocumentFromArcMap(m_application);
IEnvelope gridEnvelope = GetGridExtents("Z29");
IFeatureClass featureClass = GetFeatureClassFromShapefileOnDisk("D:\\Projects\\Working\\BMRDA\\data", "Hoskote_Satellite_Polygon");
// Create the spatial filter and set its spatial constraints.
ISpatialFilter spatialFilter = new SpatialFilterClass();
spatialFilter.Geometry = gridEnvelope.Envelope;
spatialFilter.GeometryField = featureClass.ShapeFieldName;
spatialFilter.SpatialRel = esriSpatialRelEnum.esriSpatialRelWithin;
spatialFilter.set_OutputSpatialReference(featureClass.ShapeFieldName, mxDoc.FocusMap.SpatialReference);
// Set the attribute constraints and subfields.
// We want to exclude ramps, highways and interstates.
spatialFilter.WhereClause = "LEVEL3 = 'AGRICULTURE LAND'";
// Execute the query.
IFeatureCursor featureCursor = featureClass.Search(spatialFilter, true);
ESRI.ArcGIS.Geodatabase.IFeature feature; // Automatically initialized to null. Used to test existence of a feature in the featureCursor
double dbArea = 0.0;
int intCount = 0;
while ((feature = featureCursor.NextFeature()) != null)
{
IArea area = (IArea)feature.Shape;
dbArea = dbArea + area.Area;
intCount++;
}
the spatialFilter.SpatialRel = esriSpatialRelEnum.esriSpatialRelWithin; does not work it returns me null I want the polygon to be clipped and get the area of it Am i missing something here? Please guide..
... View more
03-28-2012
11:22 PM
|
0
|
1
|
1068
|
|
POST
|
HI, I have a project where I create a FeatureLayer from a service FeatureLayer featureLayer = new FeatureLayer();
featureLayer.Url = "http://myserver/ArcGIS/rest/services/LRS_CW_SURFACE_TYPE/MapServer/0";
featureLayer.ID = "QueryResult";
featureLayer.OutFields.Add("DESCRIPTION,START_KM,END_KM");
featureLayer.InitializationFailed += new EventHandler<EventArgs>(featureLayer_InitializationFailed);
featureLayer.Initialize();
mainPage.map.Layers.Add(featureLayer);
featureLayer.UpdateCompleted += new EventHandler(featureLayer_UpdateCompleted);
featureLayer.UpdateFailed += new EventHandler<TaskFailedEventArgs>(featureLayer_UpdateFailed); in the mxd from which I created the service I have made the label visible to the map.. then when I create a new Feature-layer why am I not able to get the label as in the mxd also the feature point created in the feature-layer label looses it rotation angle
... View more
03-16-2012
12:48 AM
|
0
|
1
|
1799
|
|
POST
|
HI, I am working on a project where I have a feature class with roads and FromMeasure and ToMeasure with roadid and I have a table with road surface type along with the roadid, FromMeasure and ToMeasure I used MakeRouteEventLayer from Linear Referencing tools to to create a event layer that shows the road surface type on the map I have create symbology(unique values) according to the distinct surfacetypes from the roadsurfacetype table The problem is when a new surface type is added in the table it does not show on the symbology.. Is the method I followed correct or is there another way to show the roadsurfacetype on the map syrfacetypes as the symbology Please guide... Santosh V
... View more
03-14-2012
09:49 PM
|
0
|
1
|
763
|
|
POST
|
Thnx for your reply I saved the XMin, XMax, YMin, YMax from the feature layer calculated the envelope and zoomed to it , it worked fine anywys 🙂
... View more
02-22-2012
07:38 PM
|
0
|
0
|
712
|
|
POST
|
If you are loading multiple layers at runtime at once and you want to do some processing after all of them have finished updating, you'll have to keep a counter to find out when all of them have completed. Then you can calculate the extent from all layers by using Union() and do your zoom ... I hope that's what you are looking for; I'm not quite sure of your scenario. [ATTACH=CONFIG]12111[/ATTACH] Hi thanks you for your reply.. I am sorry I did not give enough information about the query.. I have a query where the input values need me to query upto 3 ranges and I return 3 thematics with different symbology on the map therefore I have created 3 layers with different symbology but same data and created a service to access it.. here I am adding 3 feature layers onto the map .Since the query keysin values in range, for everyvalue keydin I create a new feature layer and display it on the map 1 feature layer for every range. so after adding 3 different feature layers I would like to zoom to its extent. therefore I need to either merge(ie union the feature layer) else add up the extents.. is it possible to add the extents so that I can fix all the 3 feature layer on the map.. Please guide...
... View more
02-21-2012
09:42 PM
|
0
|
0
|
712
|
|
POST
|
Hi, I have a query where I add many feature in runtime.. now i write
if (projFeatureLayer.FullExtent != null)
{
double projectXMin = projFeatureLayer.FullExtent.XMin;
double projectXMax = projFeatureLayer.FullExtent.XMax;
double projectYMin = projFeatureLayer.FullExtent.YMin;
double projectYMax = projFeatureLayer.FullExtent.YMax;
//To also Envelope a single point
double coordOffset = .01;
if (projectXMin == projectXMax && projectYMin == projectYMax)
{
projectXMax = projectXMax + coordOffset;
projectXMin = projectXMin - coordOffset;
}
//Set Zoom Duration (Time)
mainPage.map.ZoomDuration = new TimeSpan(0, 0, Convert.ToInt32(App.Current.Resources["ZoomDuration"]));
Envelope projectEnvelope = new Envelope(projectXMin, projectYMin, projectXMax, projectYMax);
//Set zoom Extents
mainPage.map.ZoomTo(projectEnvelope.Expand(Convert.ToDouble(App.Current.Resources["ZoomExpand"])));
mainPage.panelCustomLegend.Visibility = System.Windows.Visibility.Visible;
//mainPage.boolRefreshCustomLegend = true;
//mainPage.CustomLegend.Refresh();
return true;
} to zoom to one feature layer on "feature layer update-completed event" but how do I zoom to all the feature layers added on the map...?? Please guide
... View more
02-20-2012
07:15 PM
|
0
|
4
|
2441
|
|
POST
|
The default legend style doesn't show disabled scrollbars. Check that there is no implicit style defined for the legend in your project (most generally in app.xaml) that might override the default template. Hey dbroux thanks you were right the legend style was defined in app.xaml I changed it it solved my problem thanks a bunch 🙂
... View more
02-01-2012
02:05 AM
|
0
|
0
|
784
|
|
POST
|
HI, I have website with mouseover information tool where i run a query from the database everytime the mouse moves over the map but when I move the mouse towards the window edges/corners the information texblock is chopped away it is not absolute Please guide me as to how the keep the mouse over information within the map boundary my code goes like this <!--MouseOver Information-->
<Border x:Name="m_maptip" CornerRadius="10,10,0,0"
VerticalAlignment="Top" HorizontalAlignment="Left" Visibility="Collapsed"
Background="White" BorderThickness="3" BorderBrush="#3c91c0" Opacity="0.8">
<StackPanel>
<sdk:Label x:Name="m_txt_maptip_header" FontFamily="Arial" FontSize="16" Foreground="Red"/>
<TextBlock x:Name="m_txt_maptip" Text="Line" Foreground="Black" FontSize="12"/>
</StackPanel>
</Border>
I populate the information into the textblock dynamically KeyValuePair<int, string> kvpIdentifyLayer = (KeyValuePair<int, string>)cmbxLayerIdentify.SelectedItem;
m_txt_maptip.Text = strDisplayInfo;
m_txt_maptip_header.Content = "Layer: " + kvpIdentifyLayer.Value;
m_maptip.Visibility = Visibility.Visible;
m_maptip.Margin = new Thickness(_last_point.X + 10, _last_point.Y + 10, 0, 0);
m_txt_maptip_header.Width = m_txt_maptip.Width;
Please guide
... View more
01-30-2012
03:28 AM
|
0
|
0
|
784
|
|
POST
|
. The default legend template uses a TreeView which has a built-in scrollviewer. But this scrollviewer should not be visible if not needed. Look at this sample : http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#LegendSimple The scrollbars are only visible when needed. If, for any reason, you need to change the default behavior, you can restyle the legend control (using EditTemplate functionalty in Blend) and use any other container to replace the treeview. HI thanks for your reply tried everything but still unable to hide it. the scroll is disabled but is always visible my code goes like this <Grid x:Name="panelCustomLegend" HorizontalAlignment="Right" Margin="0,50,80,0" VerticalAlignment="Top" ScrollViewer.VerticalScrollBarVisibility="Hidden"
Visibility="Visible" Background="Black" >
<Grid.RowDefinitions>
<RowDefinition Height="20"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<sdk:Label Name="lblCustomLegend" Foreground="White" Grid.Row="0" MinWidth="50" MaxWidth="200" HorizontalAlignment="Center" FontSize="12" />
<esri:Legend Map="{Binding ElementName=map}" Grid.Row="1" ScrollViewer.HorizontalScrollBarVisibility="Hidden"
ShowOnlyVisibleLayers="True" x:Name="CustomLegend" Refreshed="CustomLegend_Refreshed" >
<esri:Legend.MapLayerTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<sdk:Label Content="{Binding Description}"/>
<!--<Slider Maximum="1" Value="{Binding Layer.Opacity, Mode=TwoWay}" Width="50" />-->
</StackPanel>
</DataTemplate>
</esri:Legend.MapLayerTemplate>
<esri:Legend.LegendItemTemplate>
<DataTemplate >
<StackPanel Orientation="Horizontal">
<Image Source="{Binding ImageSource}"></Image>
<sdk:Label Content="{Binding Label}" MinWidth="50"/>
<sdk:Label Content="{Binding Tag}"/>
</StackPanel>
</DataTemplate>
</esri:Legend.LegendItemTemplate>
<esri:Legend.LayerTemplate>
<DataTemplate>
<CheckBox Content="{Binding Label}"
IsChecked="{Binding IsEnabled, Mode=TwoWay}"
IsEnabled="{Binding IsInScaleRange}" >
</CheckBox>
</DataTemplate>
</esri:Legend.LayerTemplate>
</esri:Legend>
</Grid> [ATTACH=CONFIG]11518[/ATTACH] Can you please guide me with the modification to hide to scroll .....
... View more
01-30-2012
03:03 AM
|
0
|
0
|
784
|
|
POST
|
Normally this situation happens when the ''event's route id'' is not found in the Route layer. Instead of dropping the unreferenced events, it keeps it but with a geometry equal to 'null'. You could first verify for one of these events that failed, what is the RouteID written. Then look in your Route Layer if you can really find this route ID. Yup you were right thnx 🙂
... View more
01-30-2012
02:43 AM
|
0
|
0
|
500
|
|
POST
|
HI .. I have a issue with creating a layer using Make Route event Layer using an event table When I create a event layer some of the geometry is not created it shows no shape/shape length = 0 but it has an attribute table Because of this I am not able to show this graphic on the map please do guide in fixing this problem...[ATTACH=CONFIG]11465[/ATTACH]
... View more
01-27-2012
02:35 AM
|
0
|
2
|
2410
|
|
POST
|
HI, I have a Legend which shows a disabled scrollbar even if the content is limited within the panel. my XAML is as follows <esri:Legend Map="{Binding ElementName=map}" Grid.Row="1" ScrollViewer.HorizontalScrollBarVisibility="Hidden"
ShowOnlyVisibleLayers="True" x:Name="CustomLegend" Refreshed="CustomLegend_Refreshed" >
<esri:Legend.MapLayerTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<sdk:Label Content="{Binding Description}"/>
<!--<Slider Maximum="1" Value="{Binding Layer.Opacity, Mode=TwoWay}" Width="50" />-->
</StackPanel>
</DataTemplate>
</esri:Legend.MapLayerTemplate>
<esri:Legend.LegendItemTemplate>
<DataTemplate >
<StackPanel Orientation="Horizontal">
<Image Source="{Binding ImageSource}"></Image>
<sdk:Label Content="{Binding Label}" MinWidth="50"/>
<sdk:Label Content="{Binding Tag}"/>
</StackPanel>
</DataTemplate>
</esri:Legend.LegendItemTemplate>
<esri:Legend.LayerTemplate>
<DataTemplate>
<CheckBox Content="{Binding Label}"
IsChecked="{Binding IsEnabled, Mode=TwoWay}"
IsEnabled="{Binding IsInScaleRange}" >
</CheckBox>
</DataTemplate>
</esri:Legend.LayerTemplate>
</esri:Legend> How can I hide the scrollbar Please guide..
... View more
01-24-2012
11:22 PM
|
0
|
5
|
934
|
| Online Status |
Offline
|
| Date Last Visited |
09-07-2025
09:04 AM
|