• My Pages
  • Comments
  • Add Link
  • Subscribe
  • Subscribe User
  • Edit (GUI)
  • Edit (Text)
  • Rename Page
  • Copy Page
  • Load Page
  • Save Page
  • Delete Page
  • Attachments
  • Check Spelling
  • Diffs
  • Info
  • Revert to this revision
  • XML
  • Render as Docbook
  • Print View
  • Raw Text
  • Delete Cache
  • Like Pages
  • Local Site Map
  • Remove Spam
  • Package Pages
  • Sync Pages

    DataBinding in the OpenEdge GUI for .NET

    All sourcecode and documentation provided is Copyright (C) 2006-2008 by Consultingwerk Ltd. ("CW") - http://www.consultingwerk.de and other contributors as mentioned. All Rights Reserved.

    Software is distributed on an "AS IS", WITHOUT WARRANTY OF ANY KIND, either express or implied.

    Introduction

    DataBinding is one of the basic features comming with the new OpenEdge Release 10.2A. DataBinding supports rapid building of functional forms that display and update data. This Presentation and Sample code demonstrates usage and basic concepts of DataBinding.

    SmapleForm

    SampleForm

    UpdateFromABLForm

    UpdateFromABLForm

    Installation

    Usage instructions

    UpdateFromABLForm.cls

    Requirements

    • ProBindingSource

    • bindingNavigator
    • ultraNumericEditor (Infragistics)
    • ultraTextEditor (Infragistics)
    • ultraButton (Infragistics)
    • ultraLabel (Infragistics)
    • Connection to a Sports2000 Database

    Example Data

    The schema for the table "sports2000.customer" has been loaded into the ProBindingSource "bsCustomer". At runtime a query is created and attached to the bindingSource.

    DataBindings

    • ultraNumericEditor1:DataBindings:Value = bsCustomer - CustNum

    • ultraTextEditor1:DataBindings:Text = bsCustomer - Name

    • bindingNavigator:BindingSource = bsCustomer

    Description

    You can navigate through the data using the bindingNavigator buttons.

    • Message Buffer Value
      • Displays the current value of the buffer and the current value of the bindingSource.
    • Update Buffer Value
      • Updates the buffer adding an asterisk to “customer.name”. Displays the current value of the buffer and the current value of the bindingSource. ! The current value of the buffer is up to date but the bindingSource is not.
    • Update Buffer Value & Refresh

      • Updates the buffer adding an asterisk to "customer.name". Refreshes the cache of the bindingSource and displays the current value of the buffer and the current value of the bindingSource. ! The current value of the buffer and the bindingSource are up to date.
    • Assign()
      • Updates the bindingSource by setting the value of the field "Name" to the current text of ultraTextEditor1 using the databinding. Displays the current value of the buffer and the current value of the bindingSource. ! The current value of the buffer and the bindingSource are up to date.

    SampleForm.cls

    Requirements

    • ProBindingSource

    • ultraGrid (Infragistics)
    • ultraTextEditor (Infragistics)
    • ultraCombo (Infragistics)
    • ultraLabel (Infragistics)
    • Connection to a Sports2000 Database

    Example Data

    The schema for the tables "sports2000.customer" and "sports2000.salesrep" has been loaded into the ProBindingSources "bsCustomer" and "bsSalesRep". At runtime queries are created for both tables and attached to either of the bindingSources.

    DataBindings

    • ultraGrid1:DataSource = bsCustomer

    • ultraCombo1:DataSource = bsSalesRep

    • ultraCombo1:DisplayMember = RepName

    • ultraCombo1:DataBindings:Value = bsCustomer - SalesRep

    • ultraTextEditor1:DataBindings:Text = bsSalesRep – Region

    Description

    The Grid displays all Customers from the database. If a Row is selected the position in the bindingSouce "bsCustomer" is set to the chosen record. The ultraCombo1 control displays the current "RepName" from the bindingSource "bsSalesRep" and is repositioned due to the rowchange of the ultraGrid cause it’s Value is bound to the field "SalesRep" of bindingSource “bsCustomer”. In the ultraTextEditor1 control the “Region” of bindingSource "bsSalesRep" is displayed due to the reposition of the bindingSource by the ultraCombo1 control.

    Version history

    Version

    Release Date

    Comments

    1.0

    02.12.2008

    Initial release of these samples.

    Known issues

    There are currently no known issues with this tool.

    Download

    Samples/DataBindingInTheOpenEdgeGUIForDotNET (last edited 2008-12-02 11:08:05 by MarkoRueterbories)