Hi Paul

Exact this subject where adressed only a week ago. The best way possible in
MapBasic is from what I got out of it:

        *       create a Toolbutton when you press a button i your dialog.
        *       then set the Map window to the front
        *       call the tool with Run Menu Command ID ####(ID from your
create toolbutton definition)
        *       when the user clicks in the map mapbasic processes this in
the toolhandler routine as defined in the toolbutton create command. Use
this handler to store your coordinates by using CommandInfo(CMD_INFO_Y) and
CommandInfo(CMD_INFO_X).
        *       Then call back your dialog from before and remove the
toolbutton by using alter buttonpad statement.

        That should do the trick.

        Regards

        Thomas Brix Lyng
        Frederikshavn County Administration
        Denmark

> ----------
> Fra:  Paul Fildes[SMTP:[EMAIL PROTECTED]]
> Sendt:        22. november 1999 16:11
> Til:  MapInfo List
> Emne:         MI: Getting Co-ordinates
> 
> Dear all,
> 
> Using MapBasic I have created an application for adding/editing/deleting
> map
> data. For adding and editing data I have provided a dialog which prompts
> the
> user for the relevant table information including a co-ordinate set (X,Y).
> If the user doesn't know the exact location, then I have been asked to
> provide a button which the user can click, and take them to the map window
> containing the table, and extract the co-ordinates from the map.
> 
> So far the button in my dialog is defined as having a handler routine
> which
> it calls. Its in this routine where I have already been able to determine
> the MapWindowID for the first instance of the table, and set it as the
> front
> window. 
> 
> Can you please advise me how I might achieve the rest of the above?. How
> do
> I switch back to the map window, recognise a mouse click on the map, and
> then refer back to my dialog?.
> 
> Regards,
> 
> Paul Fildes                                   Phone: +44 121 643 6711
> Technology Applications Group, Maunsell Ltd,  Fax:   +44 121 643 1357
> Attwood House, 1 Worcester Walk,              Email: [EMAIL PROTECTED]
> New Street, Birmingham B2 4NX, UK             URL:   www.maunsell.co.uk
> ----------------------------------------------------------------------
> To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
> "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
> 
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to