Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have map data in the form of Northings and Eastings, and would like to convert this to Lat and Long so I can display on a Map.
I know there are online tools to do this, but does anyone know a Qlik Sense solution/tool I can use?
Thanks,
I am not aware of any QS tool to do that. I would simply convert the data to Long/Lat and then bring that into your QS app via script.
Many years ago I converted a piece of Java code that did the conversion into a QlikView Javascript macro if that's any good? Conversion from/to: lat-long, Eastings/northings and OS grid ref at a rate of about 100,000 a second.
Hi Chris, can you please share the code please.
Regards,
ASP
The wikipedia article shows the conversion formula you'll want to use:
Thanks Ronald, 2 questions
1) I needed something for British co-ordinate system will UTM to Lat/Lon work?
2) If it works can i code the formula given on wiki into Qlik Code?
Regards,
Anwar
Hi Anwar
Sure
I've attached a QVW that does the conversion (only for The Globe Theatre in London but you get the idea) via a (JScript) macro.
Enjoy !
This is Awesome Chris thanks, Only Question is how to the same in Qliksense?
I have tried this code in Qlik Sense from the above post, but can't find much information on ENToLatLng in the community or online. Is this something built into Qlik Sense or do I need to add actual code somewhere ?
LOAD
*,
longitude2 & ',' & latitude2 as LatLonCoor
;
Load *,
SubField(LatLng, '_', 1) as latitude2,
SubField(LatLng, '_', 2) as longitude2
;
Load *,
ENToLatLng(latitude, longitude) as LatLng;
but I get the following Error when trying to load the data: