p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   ASP.NET 2.0 Basics (http://p2p.wrox.com/forumdisplay.php?f=136)
-   -   Cannot update textbox.text (http://p2p.wrox.com/showthread.php?t=55904)

John Leo March 27th, 2007 08:45 AM

Cannot update textbox.text
I am trying to update a textbox which is on default.aspx from code within a class. The code is as follows:

            Dim m_control As Control
            Dim NewTextbox As TextBox
            NewTextbox = m_Page.FindControl("txtID")
            NewTextbox.Text = sValID

When I debug this, it seems to work but the textbox shown on the page is not updated and I am unable to see the value from another page using the following:

sString = CType(PreviousPage.FindControl("txtID"), TextBox).Text

Can someone please tell me what I'm doing wrong.



All times are GMT -4. The time now is 06:17 AM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.