Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Data Binding with DataSets
Message
General information
Forum:
ASP.NET
Category:
Forms
Miscellaneous
Thread ID:
00685491
Message ID:
00685576
Views:
14
Bill,

Yes, we have a DataBind() method in each base class, like a TextBox. Here's some sample code:
// -- in the base class (ie. a TextBox):
public virtual void DataBind(System.Data.DataTable Data, string Path)
{
  this.DataBindings.Add("Text", Data, Path);
{
// -- in the Load() of the form where the object has been dropped:
  this.MyTextBox.DataBind(this.MyDataSet.MyTable, "FirstName");
~~Bonnie



>>don't recall right now what they are) and so, like JVP, we also have our own DataBind() method in all of our base objects. Is this the "right" way to
>
>Does this DataBind() method exist in the base classes of your user controls? ie: TextBox? Are you setting properties and evaluating them at run time to bind the controls? Or are you talking about the same kind of DataBind() method at the form level holding data binding .Clear() and .Add() calls?
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Reply
Map
View

Click here to load this message in the networking platform