Dim 去掉,然后以这种形式变化
string  aaa;
Me去掉或者换成this
vbCrlf改为:“\n”
还要注意每行末尾加“;”号

解决方案 »

  1.   

    private void Page_Load (System.Object sender, System.EventArgs e)
    {
    int i = Convert.ToInt32(Interaction.IIf(Information.IsNumeric(Label1.Text), Label1.Text, "0"));
    i = i + 1;
    Label1.Text = i.ToString();
    addRefreshJSScript(5000); //在此处放置初始化页的用户代码
    }private void addRefreshJSScript (int intInterval)
    {
    string strScript;
    strScript = "\n" + "<script language='javascript'>" + "\n";


    strScript += "setTimeout(\"  ";

    strScript += Page.GetPostBackEventReference(this);

    strScript += "\", ";
    strScript += intInterval.ToString();

    strScript += ");" + "\n";

    strScript += "</" + "script>";
    this.Page.RegisterClientScriptBlock("RefreshScript", strScript);

    }