Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net Web Controls (http://www.velocityreviews.com/forums/f63-asp-net-web-controls.html)
-   -   .NET Databinding a textbox in a webform (http://www.velocityreviews.com/forums/t772637-net-databinding-a-textbox-in-a-webform.html)

Nikerz Inc 02-13-2004 11:14 AM

.NET Databinding a textbox in a webform
 
Hi there,

This must be simple but I can't figure it out. All I want to do is bind a
text box to a column in my dataset. I have a dataset that has First name,
Last name, Address ect.......


I want each text box to have the field so I can also update the database as
well. This seems like mission impossible please help!!



Ken Cox [Microsoft MVP] 02-16-2004 01:34 PM

Re: .NET Databinding a textbox in a webform
 
Hi,

If you know the structure of your dataset and its tables, you can "walk"
down through the tables, rows and columns to get any piece of data that you
want:

TextBox1.Text = ds.Tables(0).Rows(0).Item("Address")


For a more elaborate method, try here:

http://msdn.microsoft.com/library/en..._howtodatabind

Ken
Microsoft MVP [ASP.NET]
Toronto


"Nikerz Inc" <nikerzinc@hotmail.com> wrote in message
news:eWU4CKi8DHA.2952@TK2MSFTNGP09.phx.gbl...
> Hi there,
>
> This must be simple but I can't figure it out. All I want to do is bind a
> text box to a column in my dataset. I have a dataset that has First name,
> Last name, Address ect.......
>
>
> I want each text box to have the field so I can also update the database
> as
> well. This seems like mission impossible please help!!
>
>




All times are GMT. The time now is 03:33 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.