Enhancing a Windows Control
The example you worked through earlier in this chapter introduced the concepts involved in creating a custom Windows control by combining existing controls into a single object. However, you can also create “new” controls simply by adding capabilities to an existing control. This means that you are working with a single base control but adding properties, methods, and events to provide additional capabilities to the user. For example, you might want to create a special scrollbar control that uses letters instead of numbers or a text box that accepts only certain characters.
Placing the code that performs these tasks into a separate Windows control makes it easier to use the code in future programs. For example, rather ...
Get Special Edition Using Microsoft® Visual Basic® .NET now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.