Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
MM in user controls
Message
From
17/05/2004 13:50:42
Jason Mesches
Ocean Systems Engineering Corporation
Carlsbad, California, United States
 
 
To
17/05/2004 12:36:33
Rex Mahel
Realm Software, Llc
Ohio, United States
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Miscellaneous
Thread ID:
00894909
Message ID:
00904628
Views:
23
Rex,

By default, each control has its BindingSourceMember populated with the field name to which its bound. Then, in the customer method, we prepend the dataview name to it:
public void BindControls(string bindingBizObjName, string bindingSourceMember)
{
   //If we're not on a page here, can't run the binding method.
   if(this.Page != null)
   {
      mmBusinessWebPage page = (mmBusinessWebPage)this.Page;
      this.txtAccountNumber.BindingSource = bindingBizObjName;

      //BindingSourceMember = ".cAccount" by default
      //so prepending "DataTable.DataViewName" works.
      this.txtAccountNumber.BindingSourceMember = bindingSourceMember + 
         this.txtAccountNumber.BindingSourceMember;
      page.RegisterBoundControl(this.txtAccountNumber);
   }
}
Hope that makes sense,
---J

>Jason,
>
>How do you get the BindingSourceMember?
>
>TIA
>
>Rex
Previous
Reply
Map
View

Click here to load this message in the networking platform