值未传递给函数 [英] value not passing to the function

查看:106
本文介绍了值未传递给函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


有一个处于只读状态的文本字段,其中有文本.现在我正在获取文本并将其传递给method.,但是当进入方法时,文本值未显示,其显示为".可以一个帮助我.

谢谢.


there is a text field which is in read only state and there is text in it.now i am fetching the text and passing it to method.but when coming to method the text value is not showing up, its showing "".can any one help me.

thank you.

推荐答案

尝试一下
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
     TextBox1.Text = Server.HtmlEncode(Request.Form(TextBox1.UniqueID))
End Sub


确保您的文本框具有一定的价值.
尝试通过在函数调用的地方放置断点来调试代码.
看一下堆栈跟踪,看看它们之间是否有一些方法调用.
Make sure your textbox has some value in it.
Try debugging your code by putting break points at the place where the function is called.
Have a look at the stack trace to see if there is some method call in between.


向我们展示您的代码.您是否在引用这样的文本框:CONTROLNAME.Text

您是否尝试过调试代码以确保它能够按照您认为的样子运行?
Show us your code. Are you referencing the textbox like this: CONTROLNAME.Text

Have you tried debugging your code to ensure it''s going where you think it is?


这篇关于值未传递给函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆