Solved

Changing the page form action

Posted on 2009-06-30
4
1,273 Views
Last Modified: 2013-11-08
Hey, in my vs 2008 i am able to do:
this.Page.Form.Action = Request.RawUrl;
no error appears, and it's working.
then ive got with my project to another computer
at my office, and suddenly the ide says he can't find it:
'System.Web.UI.HtmlControls.HtmlForm' does not contain a definition for 'Action' and no extension method 'Action' accepting a first argument of type 'System.Web.UI.HtmlControls.HtmlForm' could be found
they both have asp.net 3.5 version, what can be the problem ?
0
Comment
Question by:elektrobrain
  • 2
4 Comments
 
LVL 8

Accepted Solution

by:
Haris V earned 250 total points
ID: 24752639
It turned out that the hosting service was not running SP1 for ASP.NET .

 They moved my web application to a server with SP1 and it all works

please check this link,
1. https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=361981

0
 
LVL 12

Expert Comment

by:Cyber-spy
ID: 24754064
Just out of interest, why are you setting the Action of the form, especially to what would appear to be its default value anyway?
0
 

Author Comment

by:elektrobrain
ID: 24754190
No it's not default. let me explain. when you using url rewriting
like www.mydomain.com/movies/terminator3.html instead of
www.mydomain.com/movies.aspx?movieid=231
the postback returns to the
original address, and by setting the postback to the raw url i can promise that the postback
will be back to the new rewrited url
0
 
LVL 12

Expert Comment

by:Cyber-spy
ID: 24761317
That makes sense. Thanks - it's a useful tip!
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
Normally the drop down box control found in the .Net framework tools is able to select just one data and value at a time, which is displayed on the text area.   But what if you want to have multiple values to be selected in the drop down box? As …
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now