|
POST
|
Apologies all for being so slow to update the widget. It's fixed per Robert's guidance--thanks! Updated source and binary versions are now on the widget page: http://www.arcgis.com/home/item.html?id=75d3bf48976c44ef986a70e0dcad0f75
... View more
02-07-2014
02:45 PM
|
0
|
0
|
582
|
|
POST
|
I can work around this partially like this: application1_initializeHandler(event:FlexEvent):void {
[INDENT]editorComponent.attributeInspector.width = 300;[/INDENT]
} This narrows the inspector panel to a usable size, but the edit field border is cut off on the right side.
... View more
03-08-2013
09:02 AM
|
0
|
0
|
693
|
|
POST
|
I apologize for replying to a really old thread, but I'm having the same problem: the attribute editor panel stretches several screens to the left and to the right when it opens after a feature gets created. I also was unable to use the editor component in a mobile project at first; then I added the mx.swc and sparkskins.swc libraries to my project and it compiled and ran.
... View more
03-07-2013
12:45 PM
|
0
|
0
|
693
|
|
POST
|
Another approach might be to use the AsyncToken that comes back from the call to execute. If you grab that AsyncToken, you can add an event listener to it like this (here I'm using an HTTPService call, but it should work similarly for your Task): var iCallId:int = 0;
var responderToken:Object = { callId : iCallId++ };
var asyncToken:AsyncToken = configService.send();
asyncToken.addResponder(new AsyncResponder(configResult, configFault, responderToken)); And you can now put your result-handling logic in a different event listener, configResult(), which will be passed the token (type Object--anything you want) you sent in right after you made the request. You can add any kind of property you want to this token, including an incremental counter or unique ID for the call. More info: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/rpc/AsyncToken.html Edit: Here's an example from Adobe, showing how to do the same thing in an even simpler way than I demonstrated above: http://cookbooks.adobe.com/post_Tracking_results_from_multiple_simultaneous_servic-922.html
... View more
01-09-2013
11:10 AM
|
0
|
0
|
726
|
|
POST
|
Xinato, Here's a FlexViewer widget I wrote; it calls an elevation data SOE through REST and then handles the resulting JSON. http://www.arcgis.com/home/item.html?id=b9d247c297f144459854751740f59f68 The SOE URL is here: http://sampleserver6.arcgisonline.com/arcgis/rest/services/Elevation/WorldElevations/MapServer/exts/ElevationsSOE_NET/ElevationLayers/0/GetElevations I use a Flex HTTPService object to make the call. I do it this way because I wrote the code a while ago. You might also use a BaseTask to do the same thing. Here's the MXML declaration: <s:HTTPService showBusyCursor="true" method="POST" id="websvcElevations" url="{_configXML.elevationSOEURL}" resultFormat="text"/> And here's a bit of the code that makes the call and handles the response: var sGeoms:String = JSONUtil.encode( [ event.graphic.geometry ] );
var oParams:Object = {
"f" : "json",
"geometries" : sGeoms
}
// Send geometries off to SOE to get elevations
var atToken:AsyncToken = websvcElevations.send( oParams );
atToken.addResponder( new AsyncResponder(
//--- Handle results from elevation profile SOE ---//
function( event:ResultEvent, token:Object ):void {
try {
var oResult:Object = JSONUtil.decode( event.result.toString() );
if ( oResult.hasOwnProperty( "error" ) )
showError( "The server returned an error:\n" + oResult.error.message );
else { ... }
I hope that helps.
... View more
01-09-2013
07:22 AM
|
0
|
0
|
1008
|
|
POST
|
I found it very difficult to troubleshoot GP parameter issues until I pointed my device to a Fiddler proxy running on my PC. Once I was able to spy on the JSON requests going over the wire, I was able to copy/paste those parameters into a web browser at the GP service REST endpoint. The problems quickly became apparent...
... View more
05-21-2012
11:47 AM
|
0
|
0
|
2236
|
|
POST
|
Nice--thanks for that, Andy. That's the other route I was considering, as it's safer and probably more efficient. Am I mistaken in thinking that it's creating a worker thread? If that's true, then any UI-related work would have to be run/posted to the UI thread, if I remember correctly. That includes things like showing toasts or adding graphics to the map...?
... View more
05-11-2012
03:54 PM
|
0
|
0
|
2236
|
|
POST
|
Coincidentally, I just found myself needing to call an async GP service, too. In some other Esri APIs (such as Flex), the mechanism for using synchronous and asynchronous services is almost identical. But in Android, there's no event that calls a listener when processing is done, so it's up to you, the developer, to create a loop of some sort to check for results. Here's a little incomplete bit of code; I adapted the Viewshed sample in the appropriate places. I hope it helps you. gpJobID = gp.submitJob(params).getJobID();
// If no response in 60 seconds, cancel out
gpTimeout = new Timer();
gpTimeout.schedule(new TimerTask() {
@Override
public void run() {
uiHandler.sendEmptyMessage(CANCEL_LOADING_WINDOW);
}
}, 60000);
// Check periodically for results
checkGPResults = new Timer();
checkGPResults.scheduleAtFixedRate(new TimerTask() {
@Override
public void run() {
try {
GPJobResource gpJR = gp.checkJobStatus(gpJobID);
if ( gpJR.getJobStatus() == JobStatus.succeeded ) {
uiHandler.sendEmptyMessage(CLOSE_LOADING_WINDOW);
checkGPResults.cancel();
lyrOutputResults.removeAll();
GPParameter result =
gp.getResultData( gpJobID, "SewerMainsTraced" );
GPFeatureRecordSetLayer resultFeats = (GPFeatureRecordSetLayer) result;
for (Graphic feature : resultFeats.getGraphics()) {
Geometry geom = feature.getGeometry();
final Graphic g = new Graphic(geom, new SimpleLineSymbol(Color.CYAN, 2));
lyrOutputResults.addGraphic(g);
}
}
else if ( gpJR.getJobStatus() == JobStatus.failed ) {
uiHandler.sendEmptyMessage(CLOSE_LOADING_WINDOW);
checkGPResults.cancel();
showToast( "Error in tracing: " + gpJR.getMessages()[ gpJR.getMessages().length-1 ].toString(), Toast.LENGTH_LONG );
}
}
catch (final Exception exc) {
Log.e(TAG, exc.getMessage());
showToast("Error in tracing: " + exc.getMessage(), Toast.LENGTH_LONG);
}
}
}, 2000, 2000);
... View more
05-11-2012
02:01 PM
|
0
|
0
|
2236
|
|
POST
|
I built a simple one-layer "Hello World" app; it deploys to Android and runs well. I notice, however, that the pinch/open gestures invoke the corresponding zoom action only after the gesture is complete (no feedback occurs during the gesture to indicate what will happen). Is this expected behavior, or am I perhaps not including a critical library or event handler? Thanks. --Mark
... View more
12-20-2010
09:38 AM
|
0
|
0
|
628
|
|
POST
|
It works for me at 2.2...but without a bing key (as in your example) I get only a white screen.
... View more
12-14-2010
01:14 PM
|
0
|
0
|
343
|
|
POST
|
The REST API that the Flex API depends on didn't come along until 9.3+. In theory you could still write a Flex app to use the SOAP services exposed by ArcGIS Server 9.2 and below. But (a) you wouldn't get the benefits of the nice ArcGIS Flex object model, and (b) in practice I've found that the Flex SOAP tools do a very poor job of building code from ArcGIS SOAP.
... View more
06-01-2010
08:37 AM
|
0
|
0
|
350
|
|
POST
|
I'm also running into this issue in a .NET/winforms app that updates a feature service using REST. Since there's no JSON encoding built-in to .NET, creating a JSON-compatible date is cumbersome. Have you given any thought to allowing standardized date strings for these kinds of parameters?
... View more
05-03-2010
08:50 AM
|
0
|
0
|
1338
|
|
POST
|
That's good to know about, thanks. In my case, though, the data source is a GraphicsLayer that's not a FeatureLayer, so it unfortunately doesn't support the DisableClientCaching method.
... View more
04-20-2010
08:54 AM
|
0
|
0
|
546
|
|
POST
|
I am having problems using the FeatureDataGrid with the Silverlight API 2.0 beta and Silverlight 3. I bind the grid to a graphics layer; once the layer is populated, the text at the bottom of the control shows the correct number of features, but nothing (not even column headers) show up in the body of the control. I see correct behavior with API 1.2. Is this a known issue? Thanks.
... View more
04-19-2010
03:57 PM
|
0
|
3
|
837
|
|
POST
|
I've been trying to update a custom app I built for 9.3.1; it looks as if some of the libraries/method calls have changed, but the SDK page referenced in the initial message in this thread has gone missing: http://resourcesbeta.esri.com/content/arcgis-mobile-94 Any idea how to get to it? Thanks, Mark
... View more
02-22-2010
07:46 AM
|
0
|
0
|
1310
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 08-19-2019 08:58 AM | |
| 5 | 03-15-2018 11:27 AM | |
| 2 | 03-06-2018 12:27 PM | |
| 1 | 10-04-2017 02:58 PM | |
| 3 | 05-26-2017 02:35 PM |
| Online Status |
Offline
|
| Date Last Visited |
04-05-2024
04:43 PM
|