Ask a Question related to ASP.NET Building Controls, Design and Development.
-
KJ #1
Dynamically Added TextBoxes
Is there anyway to get the value of a dynamically added textbox that
was added after OnInit in Page_Load on Postback?
Page_Load
Dim tb As New Textbox
page.controls.add(tb)
tb.text = "ASP.NET"
End Sub
But1_Click
label1.text = tb.text
End Sub
My problem is tb.text is blank ("")
Is there anyway to save the value between postback?
Thanks
KJ Guest
-
saving text values of dynamically created textboxes
I have many textboxes that are created dynamically as child controls of my custom control. I know that I must recreate them after each postback... -
textboxes in dynamically loaded WUC not repopulated during PostBack
i am building a webform that dynamically loads one of two web usercontrols during the webform's page_load event. i am using label, named TabId, on... -
Dynamically create non-fixed number of TextBoxes in Composite Control
Hi, I have a composite control(TextBoxControl.cs) in my DynamicTextBox.aspx. On the Page_Load of the DynamicTextBox.aspx page, I am calling a... -
Why is my dynamically added TemplCol so slow?
Hey. I'd appreciate if someone could improve the performance of my TemplateColumn. It runs nicely with one template, and very slow with another. ... -
Positioning Dynamically added controls
Hi I am adding a textbox control at runtime that allows a user to enter a date. I also want to add a calendar icon beside the textbox so that the... -
Kishor #2
Re: Dynamically Added TextBoxes
Hi KJ,
one way to do this is to save the value in the textbox into the viewstate.
kishor.
"KJ" <klj_mcsd@hotmail.com> wrote in message
news:d83a9214.0312031032.163991a8@posting.google.c om...> Is there anyway to get the value of a dynamically added textbox that
> was added after OnInit in Page_Load on Postback?
>
>
> Page_Load
>
> Dim tb As New Textbox
>
> page.controls.add(tb)
> tb.text = "ASP.NET"
> End Sub
>
>
> But1_Click
>
> label1.text = tb.text
>
>
> End Sub
>
>
> My problem is tb.text is blank ("")
>
> Is there anyway to save the value between postback?
>
> Thanks
Kishor Guest



Reply With Quote

