MapWindow 4 - Plugins : MapWindow Discussion Forum
Hey Paul, First, accept my congratulations on writing such a simple and effective c# sample plugin template (TemplatePluginVS2), even the first time user also gets the way without any issues. Ok, I am facing a small problem, I am adding a toolbar and menu through the plugin ro
plugin template - missing toolbar
Posted by: grooves ()
Date: April 03, 2012 01:36AM

Hey Paul,
First, accept my congratulations on writing such a simple and effective c# sample plugin template (TemplatePluginVS2), even the first time user also gets the way without any issues.

Ok, I am facing a small problem, I am adding a toolbar and menu through the plugin route. However, the toolbar goes missing when I initiate the MapWindow for second time (and onward). The toolbar reappears if I go back to Plug-ins/{myPlugin}, unselect it and then re-select it.

This problem is not visible in the template where the toolbar is visible every time the map-window starts. Am I doing something wrong or missing something?

Secondly, is it possible for me to designate a position while appending my toolbar. For example, I would like my toolbar to appear as a first entry (write below) Menu/Project or for some other purpose, it should be the last one in the tool-bar stack???

Thanks.
grooves

Options: ReplyQuote
Re: plugin template - missing toolbar
Posted by: pmeems ()
Date: April 03, 2012 02:04PM

Why would you initiate the plug-in for a second time?

The Initialize method is called when you load the plug-in in the plug-ins menu and the Terminate method is called when you unload the plug-in.
No need to call the Initialize method yourself.

The location of the toolbars are maintained by Microsoft. Sometimes the default toolbars may end up at different locations. It's a 'feature' of Microsoft.
And you are right. By default new toolbars are placed at the end.
You can reorder them. When you close MapWindow the locations are saved and most of the times when you reopen MapWindow the locations are restored.

--
Paul

--
Don't forget to read the new documentation: www.mapwindow.org/documentation/mapwingis4.8
Join us Google+: MapWindow GIS Google+ Community
Join the MapWindow Group on LinkedIn! LinkedIn - MapWindow Group

Download the latest beta installer at:
tinyurl.com/mwMonthly 32-Bit
tinyurl.com/mwMonthlyx64 64-Bit
Follow me on Twitter MapWindow_nl to read when a new installer is published.

---
Paul Meems
The Netherlands
[www.bontepaarden.nl]
Release manager, configuration manager and
forum moderator of MapWindow GIS

Owner of MapWindow.nl - Support for
Dutch speaking users: www.mapwindow.nl

*******
Everything I say or write is my personal opinion and
not the opinion of the company I work for.
*******
View my profile on LinkedIn

Options: ReplyQuote


Sorry, only registered users may post in this forum.





Banner Exchange




GISCP.com




Send us your banner logo (160x120) for the space above, and add this MapWindow banner ad to your site:

Just paste this text in your page: