R
RSH
I have a situation where I have a user control (Called TopOrangeMenu) that
has an Hidden HTML Field called "txtU"
I am trying to get at the value of that hidden field control from within the
User Control.
Hidden Field Control as it apears in the HTML of the User Control:
<INPUT id="txtU" type="hidden" runat="server">
Trace Output (partial) from the browser:
__PAGE ASP.ReferenceCenter_Main_aspx 16608 56
ImageJavascript ASP.EmployerServicesJS_ascx 1643 0
ImageJavascript:_ctl0
System.Web.UI.ResourceBasedLiteralControl 1643 0
Form1 System.Web.UI.HtmlControls.HtmlForm 14260 0
TopGreenMenu ASP.TopGreenMenu_ascx 2351 0
TopGreenMenu:Label1 System.Web.UI.WebControls.Label 2349 0
TopGreenMenu:_ctl0 System.Web.UI.LiteralControl 2 0
SearchMenu ASP.SearchMenu_ascx 659 0
SearchMenu:_ctl0 System.Web.UI.LiteralControl 190 0
SearchMenu:SearchBox System.Web.UI.WebControls.TextBox 176
96
SearchMenu:_ctl1 System.Web.UI.LiteralControl 5 0
SearchMenu:SearchButton
System.Web.UI.WebControls.ImageButton 263 196
SearchMenu:_ctl2 System.Web.UI.LiteralControl 25 0
TopOrangeMenu ASP.TopOrangeMenu_ascx 2637 0
TopOrangeMenu:Label1 System.Web.UI.WebControls.Label 2537
0System.Web.UI.HtmlControls.HtmlInputHidden 98 0
TopOrangeMenu:_ctl0
I System.Web.UI.LiteralControl 2 0
I have tried everything I can think of but the value is always
nothing:
Private Sub Page_PreRender(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.PreRender
dim str as string
str = Request.Form("txtU")
str = Request.Form("TopOrangeMenu:txtU")
str = Request.Form("TopOrangeMenu_txtU")
str = MyBase.Request.Form("txtU")
str = MyBase.Request.Form("TopOrangeMenu:txtU")
str = MyBase.Request.Form("TopOrangeMenu_txtU")
str = Page.Request.Form("txtU")
str = Page.Request.Form("TopOrangeMenu:txtU")
str = Page.Request.Form("TopOrangeMenu_txtU")
End If
End Sub
Thanks for any help!
Ron
has an Hidden HTML Field called "txtU"
I am trying to get at the value of that hidden field control from within the
User Control.
Hidden Field Control as it apears in the HTML of the User Control:
<INPUT id="txtU" type="hidden" runat="server">
Trace Output (partial) from the browser:
__PAGE ASP.ReferenceCenter_Main_aspx 16608 56
ImageJavascript ASP.EmployerServicesJS_ascx 1643 0
ImageJavascript:_ctl0
System.Web.UI.ResourceBasedLiteralControl 1643 0
Form1 System.Web.UI.HtmlControls.HtmlForm 14260 0
TopGreenMenu ASP.TopGreenMenu_ascx 2351 0
TopGreenMenu:Label1 System.Web.UI.WebControls.Label 2349 0
TopGreenMenu:_ctl0 System.Web.UI.LiteralControl 2 0
SearchMenu ASP.SearchMenu_ascx 659 0
SearchMenu:_ctl0 System.Web.UI.LiteralControl 190 0
SearchMenu:SearchBox System.Web.UI.WebControls.TextBox 176
96
SearchMenu:_ctl1 System.Web.UI.LiteralControl 5 0
SearchMenu:SearchButton
System.Web.UI.WebControls.ImageButton 263 196
SearchMenu:_ctl2 System.Web.UI.LiteralControl 25 0
TopOrangeMenu ASP.TopOrangeMenu_ascx 2637 0
TopOrangeMenu:Label1 System.Web.UI.WebControls.Label 2537
0System.Web.UI.HtmlControls.HtmlInputHidden 98 0
TopOrangeMenu:_ctl0
I System.Web.UI.LiteralControl 2 0
I have tried everything I can think of but the value is always
nothing:
Private Sub Page_PreRender(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.PreRender
dim str as string
str = Request.Form("txtU")
str = Request.Form("TopOrangeMenu:txtU")
str = Request.Form("TopOrangeMenu_txtU")
str = MyBase.Request.Form("txtU")
str = MyBase.Request.Form("TopOrangeMenu:txtU")
str = MyBase.Request.Form("TopOrangeMenu_txtU")
str = Page.Request.Form("txtU")
str = Page.Request.Form("TopOrangeMenu:txtU")
str = Page.Request.Form("TopOrangeMenu_txtU")
End If
End Sub
Thanks for any help!
Ron