Adi wrote:
> Can I assign a sql, to a toolbar button, (Like we can customize
> and assign a macro to a button in words and excel ).
Well, it's easy enough to add buttons, but they are limited to
functions that are resident in the current instance of MapInfo. For
example, open the mapbasic window and enter:
alter buttonpad "Tools" add pushbutton icon 231 calling 302
and you'll see a new button on the "Tools" tool bar that allows you
do an SQL select. On that SQL Select dialog there's a place to load
or save an SQL template, so that is the answer to your question.
Of course, you are probably wondering how to stick a *particular*
SQL function on a custom button. You need MapBasic for that, but
it's pretty easy to rig up a button to simply execute an SQL query.
I find it easier to just open the mapbasic window, run the query
once (which copies it into the MB window), and then simply select it
and press enter any time you want to run the query again.
But for the brave and curious, take a (careful) look at the file
mapinfow.mnu in your MapInfo directory. You can alter the MapInfo
interface by entering any of these commands either through the
mapbasic window or a workspace. If you get carried away with all
this new-found power and get things mucked up beyond all recognition
(MUBAR it, in other words), then enter this in the mapbasic window:
create menu bar as default
create buttonpads as default
and all will return to its pristine state.
Happy New Year!
- Bill Thoen
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]