产品/开发中的ASP.Net问题

时间:2022-05-03 23:00:28

I am facing strange problem, Whenever I commented second if condition, it works in Production, but fail in development.

我面临着一个奇怪的问题,每当我评论第二条件时,它在生产中起作用,但在开发中失败。

And when I dont comments second if condtion of code, it works for development and fail for production.

如果我不再评论第二条代码,那么它适用于开发并且无法生产。

    protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                lblDocument.Text = "Document :" + this.Request.QueryString["A_No"].ToString();
                //if (!frmViewer.Action.Contains("?"))
                //{
                //    frmViewer.Action = String.Format("{0}?A_No={1}&A_Format={2}",
                //                                     frmViewer.Action,
                                                     //this.Request.QueryString["A_No"].ToString(),
//                                                     //this.Request.QueryString["A_Format"].ToString());
//                }
            }
        }

Here is Error message:

这是错误消息:

CS0117: 'System.Web.UI.HtmlControls.HtmlForm' does not contain a definition for 'Action'

CS0117:'System.Web.UI.HtmlControls.HtmlForm'不包含'Action'的定义

3 个解决方案

#1


Did you verify that your ASPX file was migrated up to production with the latest changes?

您是否验证了ASPX文件是否已使用最新更改迁移到生产中?

It looks to me that the Action control was added in development, and the DLL file migrated up to production, but not the corresponding ASPX file.

在我看来,Action控件是在开发中添加的,DLL文件已迁移到生产环境,但不是相应的ASPX文件。

#2


Other people that have reported this problem have downloaded the .NET 3.5 SP1 Update, and that fixed their issue.

已报告此问题的其他人已下载.NET 3.5 SP1更新,并解决了他们的问题。

Make sure both production and development are running the latest version of the .NET Framework (currently the version listed above).

确保生产和开发都运行最新版本的.NET Framework(目前是上面列出的版本)。

Also, make sure you 'clean' your solution, then rebuild it.

此外,请确保您“清理”您的解决方案,然后重建它。

#3


Well Barbaros Alp give me following hint to solve this problem...

那么Barbaros Alp给了我一些提示来解决这个问题......

Right Click on the solution > Click Clean Solution then Build Solution –

右键单击解决方案>单击清洁解决方案然后构建解决方案 -

#1


Did you verify that your ASPX file was migrated up to production with the latest changes?

您是否验证了ASPX文件是否已使用最新更改迁移到生产中?

It looks to me that the Action control was added in development, and the DLL file migrated up to production, but not the corresponding ASPX file.

在我看来,Action控件是在开发中添加的,DLL文件已迁移到生产环境,但不是相应的ASPX文件。

#2


Other people that have reported this problem have downloaded the .NET 3.5 SP1 Update, and that fixed their issue.

已报告此问题的其他人已下载.NET 3.5 SP1更新,并解决了他们的问题。

Make sure both production and development are running the latest version of the .NET Framework (currently the version listed above).

确保生产和开发都运行最新版本的.NET Framework(目前是上面列出的版本)。

Also, make sure you 'clean' your solution, then rebuild it.

此外,请确保您“清理”您的解决方案,然后重建它。

#3


Well Barbaros Alp give me following hint to solve this problem...

那么Barbaros Alp给了我一些提示来解决这个问题......

Right Click on the solution > Click Clean Solution then Build Solution –

右键单击解决方案>单击清洁解决方案然后构建解决方案 -