I am messing around trying to swap our the getpoint to use a window coordinate instead. I am not having much luck and thought I might get a direction.
Currently it will take the point and convert it to a LONG and LAT then over to a web browser map.
The new map I am trying to get needs to have 2 coordinates instead of the one.
(defun c:LiDar (/ COORDS LONGLAT LONG LAT PROJDEST PROJSRC)
(Alert "A Coordinate System Must be set.")
(setq PROJSRC (ade_projgetwscode))
(if (/= (getvar "ctab") "Model") (command "_layout" "Set" "Model"))
(ade_projsetsrc PROJSRC)
(ade_projsetdest "LL84")
(setq COORDS (getpoint "\nPick a Point within Modelspace: "));;; Pick a Window?
(setq LONGLAT (ade_projptforward COORDS))
(setq LONG (car LONGLAT))
(setq LONG (rtos LONG 2 6))
(setq LAT (car (cdr LONGLAT)))
(setq LAT (rtos LAT 2 6))
(setq PROJDEST (ade_projgetinfo "LL84" "description"))
(princ (strcat
"\n X,Y: " (rtos (car COORDS) 2 6) "," (rtos (cadr COORDS) 2 6)
"\n Projection SOURCE : " PROJSRC
"\n Projection CIBLE(Target) : " PROJDEST
"\n Longitude,Latitude: " LONG "," LAT
"\n"))
(setq Website (strcat "https://portal.opentopography.org/datasets?minX=" LONG "&minY=" LAT "&maxX=" LONG "&maxY=" LAT ""))
(command "_browser" Website)
(princ)
)
(C:LiDAR)
Thanks guys.