Syed Tayyab Ali
Syed Tayyab Ali

Reputation: 3681

ASP.Net Problem in Prod/Dev

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'

Upvotes: 0

Views: 897

Answers (3)

Syed Tayyab Ali
Syed Tayyab Ali

Reputation: 3681

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

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

Upvotes: 0

George Stocker
George Stocker

Reputation: 57877

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

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

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

Upvotes: 0

Dillie-O
Dillie-O

Reputation: 29725

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

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.

Upvotes: 1

Related Questions