Click here to Skip to main content
15,896,118 members
Articles / Programming Languages / Delphi

Converting Delphi code to C# (Getting Google earth coordinates from mouse cursor - Code included)

Rate me:
Please Sign up or sign in to vote.
4.00/5 (1 vote)
20 Jan 2013CPOL 4.9K  
Hi all,I'm develpoing a small tool using google COM API (I know it's obsolete somehow but it works though)and one of the tasks it does it's to get coordinates from a specific point.I'm using this method://////////////////////////////////GetPointOnTerrainFromScreenCoords(0,0)Info...

Alternatives

Members may post updates or alternatives to this current article in order to show different approaches or add new features.

Please Sign up or sign in to vote.
20 Jan 2013Bernhard Hiller
Your window must subscribe to a mouse event, e.g. MouseClick, MouseDown, or MouseMove. The EventArgs of that event will tell you the mouse coordinates - already relative to your window, not to the screen as with the Delphi function. Hence there's no need to substract the position (RendX, RendY)...

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Web Developer
France France
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions