Shweta,There is an example here but it will require you doing soming coding:http://www.arcgis.com/home/item.html?id=173870a7926c4ef9b2a5121be0b46211regardsAnthony
Hi Parvaz,I developped a widget that is doing what you want. It reads a CSV file that contains two columns with coordinates x and y. It can be in any coordinate system. The coordinate system is identified by the user through a combox box before the file is read and parsed. The parsing result is push into an array and for every record a MapPoint is created and projected on the map. Here are some code elements:var outSR:SpatialReference = new SpatialReference(wkid.selectedItem.data);for (var i:int = 0; i < donnees.length; i++){var X:Number = donnees[abs];var Y:Number = donnees[ord];var point:MapPoint = new MapPoint(X, Y, outSR);geometryService.project([point as Geometry], new SpatialReference(32198));}private function handlerProjectComplete(e:GeometryServiceEvent):void{ if (incremente < donnees.length) { var pt:MapPoint = (e.result as Array)[0] as MapPoint; var myGraphic : Graphic = new Graphic(); myGraphic.geometry = pt; myGraphic.symbol = graphicPointSym; myGraphic.addEventListener(MouseEvent.MOUSE_OVER, handlerMouseRollOver); graphicsLayer.add(myGraphic); donnees[incremente].push(myGraphic); points.push(myGraphic); incremente++;}The comboxBox dataProvider comes from this list that link the wkid number to project in the map's projection: private const projectionList:ArrayCollection = new ArrayCollection( [ { data: 4326, label: "Géographique WGS84" }, { data: 4269, label: "Géographique NAD83" }, { data: 102113, label: "Web_Mercator WGS84 (Google)" }, /* Use 102100 instead */ { data: 26917, label:"UTM fuseau 17N NAD_1983" }, { data: 26918, label:"UTM fuseau 18N NAD_1983" }, { data: 26919, label:"UTM fuseau 19N NAD_1983" }, { data: 26920, label:"UTM fuseau 20N NAD_1983" }, { data: 26921, label:"UTM fuseau 21N NAD_1983" }, { data: 32183, label:"MTM fuseau 3 NAD_1983" }, { data: 32184, label:"MTM fuseau 4 NAD_1983" }, { data: 32185, label:"MTM fuseau 5 NAD_1983" }, { data: 32186, label:"MTM fuseau 6 NAD_1983" }, { data: 32187, label:"MTM fuseau 7 NAD_1983" }, { data: 32188, label:"MTM fuseau 8 NAD_1983" }, { data: 32189, label:"MTM fuseau 9 NAD_1983" }, { data: 32190, label:"MTM fuseau 10 NAD_1983" }, { data: 32198, label: "Lambert conique conforme - Québec" } ]);Hope that helped.pdio
ShwetaMAttached is a zip file containing both the compiled and uncompiled code. All you should need is an excel file that has a minimum of two columns one holding your x coords and the other your y coords (in the same spatial reference as your base map). All other columns will come across as attributes. In the config xml specify the column names used for your coords and a title field if required.Place the images under assets in your assets/images folder. RegardsAnthony
ShwetaM,Just to keep you up to date, I have just about finished creating a widget that allows you to upload data from an excel spreadsheet. I just need to test it a bit more. Unfortunately I am away from work next week so I will not be able to complete till the week begining the 11th June, hope this is ok.RegardsAnthony
Shweta,Sorry I haven't implemented a solution to this problem to date but it is something that I want to do soon. I will post up the solution once I have done the work unless there is someone else out there that has already done this and doesn't mind sharing their compilied/uncompilied code (Zahid if you are reading this!!!).RegardsAnthony
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.