Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How would I get messages back from my GP Service to the Silverlight client? I am passing the GP service some data to process and I want to have the GP service give some response that the Silverlight client would interpret and message to the user. Would a json response to do this.

By the way I still haven't figure out how to get the gp service instances' unique arcgisjobs folder id. I imagine I'll have to have the json data there as the Silverlight client would be subscribing to ArcGIS sever at that spot.


Per comments below, I do now know how to get the unique scratch space in the arcgisjobs folder. To clarify my question:

I am setting a result parameter in the python gp-service, a featureset, for the sl client to pick up. I would like to also give some verbal details back to the sl client to dialogue to the user. Along the lines of:

"Your two points calculated a percent slope of {percentSlope}" -- comes from python script

Do I set another output parameter in my python script as a txt file and have the sl client iterate through the results parameters and find the featureset and do A and then find the txt file and read it and do B? Thanks.

geoprocessorTask.GetResultDataCompleted += (s1, ev1) =>
                GraphicsLayer graphicsLayer = MyMap.Layers["ReturnedGraphicsLayer"] as GraphicsLayer;

                if (ev1.Parameter is GPFeatureRecordSetLayer)
                    GPFeatureRecordSetLayer gpLayer = ev1.Parameter as GPFeatureRecordSetLayer;
                    if (gpLayer.FeatureSet.Features.Count == 0)
share|improve this question
I had a similar question some time ago with a Flex client, so see if this is relevant to your question:… – Baskinomics Mar 9 '12 at 17:13
Thanks Sean, combing through your code answered another of my questions about %SCRATCHWORKSPACE% in gp services. – Justin Mar 9 '12 at 18:34
Glad to be of help. I wasn't entirely clear what you were asking in this question or the comment on mine, but if you could clarify your question (maybe with some code) I could post a real, direct answer. Then we could call it case-closed ;) – Baskinomics Mar 10 '12 at 19:22
See edits Sean. Thanks. – Justin Mar 11 '12 at 18:35
I would recommend returning the result as an output parameter and then doing some coding on the client side to output it in the desired format. It would be more useful for me to see the Python script. I have enough programming experience (w/ ESRi web APIs) to understand what you're doing with the Silverlight code, but without knowing what you're GP task is doing I cannot offer any more insight. – Baskinomics Mar 12 '12 at 19:55

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.