thotlename.Value   是页面上的一个控件,我判断它的值是不是为空。

解决方案 »

  1.   

    thotlename.Value 是什么东西呢?
    该返回为null的话,估计是if   (thotlename.Value   ==   "") 
                    { 
                            return   f; 
                    } 
    这里没有进去根本就没有返回f,你最好调试看看
      

  2.   

    是我没有描述清楚。
    thotlename.Value是页面上的一个控件,我是想在提交的时候判断它的值是不是为空,进行返回提示。我猜想是不是在使用ajaxpro提交的时候并没有提交thotlename.Value,所以就不能进行判断啊?
      

  3.   

    thotlename 页面上的控件需要你传递参数进去吧.public   string   getvalue(int   a,int   b,string value) 
            { 
                            string   f   =   Convert.ToString(a   +   b); 
                            if(value == "")
                               return f;
                            else
                               return "";
            } 
    _Default.getvalue(1,2,document.getElementById("thotlename")).value;