Re: How to bind a class property to a textbox

Tech-Archive recommends: Fix windows errors by optimizing your registry



<asp:textbox runat="server" text=<%# person.Name %> />

Look here for details:
http://msdn2.microsoft.com/en-us/library/bda9bbfx(VS.71).aspx

--
Eliyahu Goldin,
Software Developer
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


<cbtechlists@xxxxxxxxx> wrote in message
news:bb1279be-a07e-45b9-8f71-285fbca80a5a@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I have a person class that has a 'name' property. I want to bind that
property to a textbox on an ASP.NET form.

In a winform, I can do something like this:

dim nameBinding as binding = new binding("text", me.person, "name",
true)
me.nameTB.databindings.add(nameBinding)

Is there an equivalent in ASP.NET?

Thanks,

Chris


.



Relevant Pages

  • Re: Binding a textbox to current date
    ... Don't forget to call DataBind method for either the page or the textbox. ... Software Developer & Consultant ... Microsoft MVP ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Pass Value from Textbox on Form to VBA Code
    ... Thank you very much Chris! ... actually had an error at first, and realized that the "ME" keyword only works ... Microsoft MVP ... What I’d like to do is enter the name of a query, in a textbox on a form, ...
    (microsoft.public.access.modulesdaovba)
  • Re: How to bind a class property to a textbox
    ... Thanks, Eliyahu! ... Software Developer ... Microsoft MVP http://msmvps.com/blogs/egoldinhttp://usableasp.net ... property to a textbox on an ASP.NET form. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: sharing control data between pages
    ... Software Developer ... Microsoft MVP ... what is the best way to share the data of lets say a textbox text between ... for example if I fill the textbox in one page and later redirect to a new ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: streaming images
    ... Software Developer & Consultant ... Microsoft MVP ... I have a ADO.NET dataset that contains a jpeg (blob data) and some ...
    (microsoft.public.dotnet.framework.aspnet)