POST
|
Aaah OK! Found the answer. public void Query()
{
QueryTask queryTask =
new QueryTask("http://discomap.eea.europa.eu/ArcGIS/rest/services/Test/EnvironmentalAtlas_Dyna_WM/MapServer/0");
Query query = new Query();
query.ReturnGeometry = true;
query.OutFields.Add("*");
query.Where = "1=1"; // Return all features
queryTask.ExecuteCompleted += queryTask_ExecuteCompleted;
queryTask.Failed +=new EventHandler<TaskFailedEventArgs>(queryTask_Failed);
queryTask.ExecuteAsync(query);
}
... View more
05-24-2011
06:45 AM
|
0
|
0
|
392
|
POST
|
Hi Im running the following query, but when I iterate through the results, and try to add a graphic to the graphic layer, no graphics are added. I closer inspection I see that each feature.Geometry is null. Is my query wrong? Thanks
public void Query()
{
QueryTask queryTask =
new QueryTask("http://discomap.eea.europa.eu/ArcGIS/rest/services/Test/EnvironmentalAtlas_Dyna_WM/MapServer/0");
Query query = new Query();
query.OutFields.Add("*");
query.Where = "1=1"; // Return all features
queryTask.ExecuteCompleted += queryTask_ExecuteCompleted;
queryTask.Failed +=new EventHandler<TaskFailedEventArgs>(queryTask_Failed);
queryTask.ExecuteAsync(query);
}
private void queryTask_Failed(object sender, TaskFailedEventArgs e)
{
System.Diagnostics.Debug.WriteLine("Error with QueryTask: " + e.Error.Message);
}
private void queryTask_ExecuteCompleted(object sender, QueryEventArgs e)
{
FeatureSet featureSet = e.FeatureSet;
GraphicsLayer graphicsLayer = MyMap.Layers["AtlasPoints"] as GraphicsLayer;
MyMapTip.GraphicsLayer = graphicsLayer;
if (featureSet != null && featureSet.Features.Count > 0)
{
foreach (Graphic feature in featureSet.Features)
{
feature.Symbol = imgSymbol;
graphicsLayer.Graphics.Add(feature);
}
}
}
... View more
05-24-2011
06:24 AM
|
0
|
1
|
2736
|
POST
|
Hi I am rather new to the flexviewer. I have done some work using an earlier version of the flex viewer api. And with that version there was a config file where widgets could be loaded and map serverices added etc. I was having trouble upgrading so I thought I would download the latest version of the API with samples, however it seems very different. I cannot see in the same download any config file. The sample I downloaded is from http://resources.arcgis.com/content/arcgis-flex-viewer-download Did I download the wrong sample, or has the config.xml been removed? Thanks for your help Ah ok, downloaded the wrong samples. Should have been from http://www.arcgis.com/home/item.html?id=3f6a0bfee48949a88df50bf7686ec72a
... View more
05-17-2011
01:31 AM
|
0
|
0
|
118
|
POST
|
Hi I am rather new to the flexviewer. I have done some work using an earlier version of the flex viewer api. And with that version there was a config file where widgets could be loaded and map serverices added etc. I was having trouble upgrading so I thought I would download the latest version of the API with samples, however it seems very different. I cannot see in the same download any config file. The sample I downloaded is from http://resources.arcgis.com/content/arcgis-flex-viewer-download Did I download the wrong sample, or has the config.xml been removed? Thanks for your help
... View more
05-17-2011
01:08 AM
|
0
|
1
|
1024
|
POST
|
Hi Bjorn Thanks for the reply. Are you using one of the viewer code bases or your own API-based application? Im not exactly sure which version the current application is, as I have inherited the task and the originally developer has gone, and also I am not that familiar with flex. I think it is based on the viewer code base. What version are you upgrading from? The package name change from com.esri.ags.symbol to com.esri.ags.symbols was part of the 1.x to 2.0 migration. http://help.arcgis.com/en/webapi/flex/help/index.html#/Migrating_from_1_3_to_2_0/017p0000000z000000/ Is the GeoPortalSearchWidget.swc you are trying to use based on the 1.x API? I am assuming the GeoPortalWidget.swc is based on on the 1.x api. Thanks
... View more
05-16-2011
11:47 AM
|
0
|
0
|
209
|
POST
|
I cannot seem to find the GeoportalSearchWidget.swc file or the code module in the source code (which I assume would be GeoportalSearchWidget.mxml) anywhere. There is a GeoportalSearchWidget.xml file in the source code, but no corresponding .mxml code module to go with it ... The help file assumes that it's included in the source code files (http://help.arcgis.com/en/geoportal_extension/10.0/help/index.html#/Geoportal_Search_Widget_for_Flex/00t00000002v000000/). Anybody know what I may be missing or mis-understanding? Thanks. I also cannot find GeoportalSearchWidget.swc. I went to sourceforge.net and downloaded the geoportal-1.1.zip but I could not find any flex related components there. Did I download the wrong file?
... View more
05-16-2011
06:48 AM
|
0
|
0
|
463
|
POST
|
Hi Ive spent almost 3 days trying to get passed the following error - so I really hope someone here can help. I am getting the following error: component SimpleMarkerSymbol is defined more than once in this namespace. Remove the mapping to com.esri.ags.symbol:SimpleMarkerSymbol or com.esri.ags.symbols:SimpleMarkerSymbol I have searched through the project for "com.esri.ags.symbol:SimpleMarkerSymbol", but cannot find even one reference, so I dont know how I can remove it. When I bring up the class browser (Shfit + Ctrl + T) I get two results for SimpleMarkerSymbol. One result leads to the GeoPortalSearchWidget.swc and the other to the agslib-2.3.1-2011-04-26.swc. If I remove the GeoPortalSearchWidget.swc then I get about 300 errors - so it seems I need this library. Even if I comment out all references to SimpleMarkerSymbol I still get the same number - 20 - of errors. The errors do not have a location, just project errors. Do I need to get an updated version of GeoPortalSearchWidget.swc? If so, where would I get a new version from? Thanks
... View more
05-16-2011
05:59 AM
|
0
|
4
|
596
|
POST
|
Thanks Jennifer, Your work-around fixed the problem.
... View more
12-05-2010
11:10 PM
|
0
|
0
|
161
|
POST
|
Hi I'm using the tooltip (see the following code): <esri:GraphicsLayer ID="AtlasPoints" >
<esri:GraphicsLayer.MapTip>
<Grid x:Name="tipGrid" IsHitTestVisible="True" x:Uid="tooltipGrid" esri:GraphicsLayer.MapTipHideDelay="00:00:0.4" >
<Border CornerRadius="2" BorderBrush="#FF222957"
BorderThickness="1" Background="LightYellow">
<TextBlock x:Name="MapItemToolTip" Margin="5" FontSize="10" Text="{Binding [MapItem].Name}" />
</Border>
</Grid>
</esri:GraphicsLayer.MapTip>
</esri:GraphicsLayer> When someone hovers over a map point the tooltip shows. However, when someone then clicks on a map point a popup window opens. And sometimes the tooltip remains, over top of the pop up window. How can I ensure the tooltip is hidden when a map point is clicked? Thanks
... View more
12-02-2010
12:32 AM
|
0
|
2
|
500
|
POST
|
Are you using MouseClick or MouseLeftButtonDown event? Do you mark e.handled after you've retrieved the point and open/close your child window? Ok thanks. Setting e.handled = true; seems to have fixed it. Thanks for your help.
... View more
11-16-2010
01:58 AM
|
0
|
0
|
126
|
POST
|
Hi I'm working on a silverlight map application that uses the child window control. My map has several points on it. Clicking one of these opens the child window. When the window closes the map is in a dragging mode. Ive tried all sorts of things to stop this from happening such as: when the child window closes it fires a window closing and window closed event. On the handler for these I call map.ReleaseMouseCapture(), I've also tried putting focus onto other controls. Tried also to disable interactivity on the map, but as soon as I re-enable it the dragging begins again. The problem is that the point that is being dragged is where the user clicked to open the child window, so, in order to end the drag they have to click the map, and that then re-opens the child window. So, its a really problem. Any help is appreciated.
... View more
11-15-2010
03:21 AM
|
0
|
2
|
330
|
POST
|
Hi I'm wondering if it is possible to remove the internal rectangle from the OverviewMap control? Thanks
... View more
10-28-2010
04:25 AM
|
0
|
1
|
449
|
POST
|
Did you look at this sample ? http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#GeoRSS The data are coming from an XML feed instead a JSON feed but it looks close of what you need. Thanks for the reply, however this did not help. I already have the data loaded, and icons displayed on the map. I found a solution to my problem, though I don't know if it is the best way to do it. Instead of using icons, I use buttons. And I attach data to the DataContext of each button. Therefore I do not need to have a pixel tolerance, or similar function.
... View more
10-12-2010
06:29 AM
|
0
|
0
|
252
|
POST
|
Hi its my first time using the ESRI silverlight control, so I'm not sure of the best way to achieve this... I have loaded in some map data from a JSON feed. This is then used to display points on the map. when the user clicks on one of those points I need a dialog box to open. I am unsure of how - and what classes to use - to create a rectangle or area around the clicked pixel, and then iterate through the collection (from JSON) to see if the clicked area contains an item from the JSON collection. Is there an example of this, or can someone help me out? Regards,
... View more
10-05-2010
04:31 AM
|
0
|
6
|
710
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|