POST
|
Terry, Thank you very much for your reply. After study your codes and the concept. View attachments use Identify tool is working now. You were the first person to post code on the forum to discuss this function. Your post help me to make the function working on my app . I would like to express my appreciate to you for your kindness to teach me and answer my questions on the forum. Mark Ma
... View more
08-02-2011
06:11 AM
|
0
|
0
|
10
|
POST
|
Terry, Thank you again for your help. Actually, I do have 6 layers with attachments that I need to display but I use only one layer to do testing. after add more layers in xaml and modify my C# code with you posted code, urlLayer and token value displayed. however, When I run the app and click a point layer to Identify. I got "Identify faild. Error:ESRI.ArcGIS.Client.Tasks.ServiceException:Unable to complete operation". When I click OK on the error message, the error point to the line "_dataLinks[linkId].Add(new DataLink() { Link = ai.Uri, Caption = ai.Name });" with error said. "The given key was not present in the dictionary". I debug the line and found "ai.Uri" path is correct and "ai.Name" point to a pdf name is correct. In the code I have "Dictionary<string, List<DataLink>> _dataLinks { get; set; }" Do I need to add anything into Dictionary or class? Please teaching me. Thanks Mark
... View more
07-12-2011
12:16 PM
|
0
|
0
|
10
|
POST
|
Terry, Thank you very much for teching me to construct the MapUtils Class. After implement the class there is no error message. However, When I run the application and click a point the application point to error on "urlLayer = MapUtils.GetLayerURL(MyMap.Layers[Convert.ToInt32(token.ToString())]) + "/" + result.LayerId;" I setup debug and find that the string valuable "urlLayer" is empty and "token" is null. But MyMap.Layers count is correct, result is displayed and LayerId is correct. The Error message is "Object reference not set to an instance of an object" I have tried to debug but I don't kown why urlLayer is empty and token is null. but I belive that we are very close to solve the problem I have attachment the C# code and xaml and screen in doc. Would you please teach where I may go wrong. Thanks Mark
... View more
07-08-2011
11:45 AM
|
0
|
0
|
10
|
POST
|
Terry, Thank very much for reply . follow your instructions error message 2, 3, 4 solved. But I can not solve the number 1. You mensioned that you made the MapUtils Class. I have tried to construct the class but I can not make it work. Would you please teaching me for how to contruct the Class? Here is the Class that I tried. public class MapUtils { internal static string GetLayerURL(ESRI.ArcGIS.Client.Layer layer) { } } 1. "The name 'MapUtils' does not exist in the current context". MapUtils is a utility class I made and the function GetLayerURL simply returns the URL of a layer in the map. Thanks. Mark
... View more
07-05-2011
12:58 PM
|
0
|
0
|
10
|
POST
|
Terry, Thank you very much for your reply. I attached a zip file which including xaml, C#,error messages and MapServer service information that you may needed to see where my errors. I have used ESRI Resource Center Silverlight Interactive SDK Query/Identify " http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Identify " as basemap and input my MapServer and apply your sample code. I appreciate your efforts and time for help me. Happy 4th of July. Mark
... View more
07-04-2011
07:36 AM
|
0
|
0
|
40
|
POST
|
Terry, I am very interested your code and tried to use the code that you have posted. But I can not get it to work. Did I missing anything? A class or method? Would you please teaching me what I need to do to make it work. I would like to use Silverlight Identify Tool to display attachments link and open attachments (pdf or txt) use MapServer REST Endpoint. I have published REST MapServer with "HasAttachments" is true. I am use ArcGIS Server 10 with Oracle 10g R2 for ArcSDE. API for SL 2.1. & VS 2010 & SL SDK 4. Thank you in advance for you help. Mark Ma GMB Engineers & Planners.
... View more
07-01-2011
12:29 PM
|
0
|
0
|
40
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|