-
Book Overview & Buying
-
Table Of Contents
ArcGIS By Example
By :
We have learned in the previous chapters how we can add a button and a tool to the toolbar. However, we can actually add more useful control to the toolbar that doesn't exist by default, by extending ArcObjects project in a similar way to a textbox or a dropdown menu. We can add almost any control in windows to the ArcGIS toolbar (as long as it fits of course). Here we will see how to add a textbox and use it to filter the map later. First we will add a new form, add a textbox to it, and resize the form to fit the text. Then we will add a button to the toolbar and replace it with the text control. Follow these steps to do so:
If necessary, open Visual Studio Express in administrator mode.
Go to File, then click on Open Project, browse to the Bestaurants project from the C:\ArcGISByExample\bestaurants\Code, and click on Open.
From the Project menu, click on Add Windows Form and name it txtSearchForm.vb.
In the form properties, scroll until you find FormBorderStyle...
Change the font size
Change margin width
Change background colour