POST
|
I think I have found a bug in the FeatureLayer code. after creating the feature layer var featureCollection = { layerDefinition: layerDefinition, featureSet: null }; featureLayer = new FeatureLayer(featureCollection); it was found that there was an internal field called _trackIdField that was undefined, yet the _startTimeField field was set to the value from the layerDefinition of "DATETIME". So as a hack I did this after creating the feature layer: featureLayer._trackIdField = 'TrackID'; And I now have 10 distinct tracks with there current position, temporal observations, and track lines showing for each of the track numbers.
... View more
04-19-2016
06:26 AM
|
0
|
0
|
391
|
POST
|
Based on this sample: https://developers.arcgis.com/javascript/jssamples/mobile_geolocaterenderer.html I am not able to render multiple tracks in the same feature layer using the temporal renderer. From the documentation, I was assuming that if there was multiple features in the feature table, then the track renderer would render the track based on the trackID of the feature. TemporalRenderer | API Reference | ArcGIS API for JavaScript "Renderer for the tracks. A track is a collection of events that share a common track ID. A track line is a graphic line that connects the observations. Applicable only for feature layers with a valid trackIdField." Now the sample has a different trackID for each location that is added to the layer, so this doesn't seem to match what the documentation says about the trackRenderer arg of the constructor. The only main change I am making is specifying the trackId as an argument that is paired with the position: attributes.TrackID = trackId; Is there something that I am missing?
... View more
04-19-2016
02:05 AM
|
0
|
1
|
2310
|
POST
|
I have placed graphics on the map using sample code from here: Get started with graphics | ArcGIS API for JavaScript However I am looking to update the position of a point on the map at regular intervals and move the symbol. Is there a way to do this yet with v4.0-beta3 API? I notice that there is no redraw method on the GraphicsLayer yet. GraphicsLayer | API Reference | ArcGIS API for JavaScript
... View more
04-17-2016
04:21 PM
|
0
|
1
|
2815
|
POST
|
We have setup printing feature based on the Client Print Sample provided on GitHub. Everything is working except for the Military Message Layers not being displayed. I am trying to get the most basic sample together with the print sample to display a 2525C symbol on the print preview, but I cannot get anything to work. If I try and programmatically add a message layer to the the print sample it throws an InvalidOperationException "The Message could not be processed. MessageLayer must have been successfully loaded into a View (Map or Scene) before calling ProcessMessage." Hack to ClientPrinting.xaml.cs sample: if (PrintMapView.Extent == null)
{
PrintMapView.MaximumExtent = BaseMapView.MaximumExtent;
PrintMapView.MaxScale = BaseMapView.MaxScale;
PrintMapView.MinScale = BaseMapView.MinScale;
PrintMapView.SetRotation(BaseMapView.Rotation);
PrintMapView.WrapAround = BaseMapView.WrapAround;
PrintMapView.Map = BaseMapView.Map;
await PrintMapView.LayersLoadedAsync();
// create a dictionary to hold message properties
var messageProps = new Dictionary<string, string>();
// define message properties (property name, value)
messageProps.Add("_type", "position_report");
messageProps.Add("_action", "update");
messageProps.Add("_id", "e0ba16ac-cddd-4595-845e-32ca4177d080");
messageProps.Add("_control_points", "-117.187,32.770;-117.191,32.725;-117.097,32.653;-116.944,32.610");
messageProps.Add("_wkid", "4326");
messageProps.Add("sic", "GFGPOAO-------X");
messageProps.Add("uniquedesignation", "IGLOO");
// create the message using the properties
var message = new Esri.ArcGISRuntime.Symbology.Specialized.Message(messageProps);
// get the message layer from the map
var messageLayer = new MessageLayer(SymbolDictionaryType.Mil2525c)
{
ID = "MyMessageLayer"
};
PrintMapView.Map.Layers.Add(messageLayer);
// make sure it's loaded before using it
await PrintMapView.LayersLoadedAsync(new[] {messageLayer});
// call ProcessMessage on the layer
bool success = messageLayer.ProcessMessage(message);
if (!success)
{
Trace.WriteLine("Failed to process message.");
}
} Has anyone managed to print a map with military symbols on it? Note that I am testing this against version 10.2.6
... View more
10-29-2015
07:15 PM
|
1
|
0
|
2638
|
Title | Kudos | Posted |
---|---|---|
1 | 10-29-2015 07:15 PM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:25 AM
|