RAD Studio 10.4.1 is now available! Learn more. Looking for discounts? Visit our Special Offers page!
C++CodeDelphi

Quick Way To Bind Your Database To UI Components With BindLinkVCL Delphi Sample App

The BindLinkVCL Sample demonstrates the use of a TBindLink. In general, it is used for linking operations, for example, linking dataset fields to various lists.

You can find Delphi and C++ code samples in GitHub Repositories. Search by name into the samples repositories according to your RAD Studio version.

Components used in BindLinkVCL App:

  • TBindingsList: Built on the TCustomBindingsList component and publishes additional properties that can be accessed from within the Object Inspector. Add a new binding and select TBindLink under Quick Bindings. 
  • TBindLink : Built on the TCustomBindLink class and publishes a set of additional properties that can be accessed from within the Object Inspector.
  • TBindingSourceDB:  Nonvisual component that provides a way to make data contained by the specified data source available to all components that want to access it, using LiveBindings.
  • Along with these TDBNavigator, TDataSource,TClientDataset and other UI components such as TLabel, TEdit ,TImage were used.

Implementation Details :

  • Use the DBNavigator1 TDBNavigator to navigate through the dataset.
  • TBindingsList is used to create managed binding among the different components. TBindLink is used to create bindings to the columns of the dataset.
  • The ImageWithHander TImage displays the Graphic Field of the selected fish within the dataset.
  • The EditWithHandler TEdit displays the Category Field of the selected fish within the dataset.
  • The MaskEditWithHandler TMaskEdit displays the Category Field of the selected fish within the dataset.
  • The ListBoxWithHandler TListBox displays the different Categories of the dataset.
  • The MemoWithHandler TMemo displays the Notes Field of the selected fish.
  • The LabelBind TLabel displays the Category, and Species Name of the selected fish. The LabelPosition TLabel displays the position of the selected fish within the dataset. The information these two TLabels display is defined in the Binding Expression Editor.
  • The CheckBoxDatasetActive TCheckBox enables or disables the TDataSource.

 Check out the full article in the DocWiki about the BindLinkVCL Sample.

BindLinkVCL Sample App

Check out the full source code for the BindLinkVCL projects for Delphi and C++Builder over on GitHub.


Reduce development time and get to market faster with RAD Studio, Delphi, or C++Builder.
Design. Code. Compile. Deploy.
Start Free Trial   Learn More About Upgrading

Related posts
C++CodeDelphi

Manage Your Collection Of Pages Easily With TCardPanel Component For Your Delphi VCL Application

DelphiShowcase

Lovingly Crafted Software To Plan And Simulate Virtual Model Railroads Is Built In Delphi

Delphi

Flexible VCL Style Utils Library Made It Easy To Modernize The Dev-C++ Dialogs With VCL Styles In Delphi

DelphiShowcase

Powerful Visual Optimizer For Investment Portfolios Built In Delphi

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

IN THE ARTICLES