Hey everybody,
I was wondering if it is possible to get the WKT if you have a WKID.
I know that it is possible to create a new SpatialReference | API Reference | ArcGIS API for JavaScript if you know either the WKT or WKID, but is it possible to retrieve a WKT if your spatial reference was created via a WKID?
Thanks,
Tim
Solved! Go to Solution.
Tim,
My past experience on this is NO you can not. If you are working on WAB there is a folder client\stemapp\jimu.js\SpatialReference that has util.js and a getCSStr function that will give you a WKT string for a WKID
Tim,
My past experience on this is NO you can not. If you are working on WAB there is a folder client\stemapp\jimu.js\SpatialReference that has util.js and a getCSStr function that will give you a WKT string for a WKID
Robert,
yes this is where I am working in. In my widget I want to get that text via a wkid.
Do you have any code snipped that would do that? I don't think my skills are quiet at that level yet, to access util.js
Thanks!
Tim
Tim,
Sorry I was doing some traveling today and did not see your question. Based on your other thread it looks like you have this figured out though.
Yes, you showed me the right path! Thanks!
If there were a way to download this table, you could probably run a query to get the value that you want: ArcGIS REST API That was projected and here is the table for geographic: ArcGIS REST API
You can use epsg.io to look up WKTs for a given WKID.