Learn ASP.NET MVC, ASP.NET Core, and Design Patterns through our online training programs. Courses conducted by Bipin Joshi on weekends. Read more details here.

<%@ Page %>

Developing Data Navigation Control (VCR) For Windows Forms

Introduction

Under windows forms data bound forms are very common. Many forms have buttons for data navigation such as next, previous, last and first. Such navigation control is commonly called as VCR control as it resembles VCR buttons. This sample code shows how to develop such a VCR custom control that you can use in your projects.

Source Code

The source code contains two files:
  • VCRControl.vb that represents VCR custom control
  • Form1.vb that represents sample client for VCR control
The VCR custom control exposes a property called DataSource that needs to be set to CurrencyManager class of your form. Once that is done you can use navigation buttons to navigate through records. The control also shows current record in the form of "x of y".

Screen Shot

Following image shows VCR navigation control in action




Bipin Joshi is a software consultant, trainer, author and a yogi having 21+ years of experience in software development. He conducts online courses in ASP.NET MVC / Core, jQuery, AngularJS, and Design Patterns. He is a published author and has authored or co-authored books for Apress and Wrox press. Having embraced Yoga way of life he also teaches Ajapa Meditation to interested individuals. To know more about him click here.

Get connected : Twitter  Facebook  Google+  LinkedIn

Posted On : 10 Aug 2002



Tags : Data Access Custom Controls Windows Forms Data Controls