Questions tagged [webforms-routing]

Routing related to Webforms. Mostly related to Friend- and/or Clean-URL routing, no matter the web server utilized.

WebForms routing is closely related to ASP.Net but could also include other Web Server languages (like PHP, JSP, etc.).

This process allows a web developer to remove the file extension from the page navigation URL and allow for the name of the page to only be displayed. This is in effect transforming domain.com/Contact.aspx to domain.com/Contact.

In the Web Forms world, this type of routing could include a QueryString or JSON data package for the URL specified.

32 questions
6
votes
1 answer

Razor view Type does not inherit from 'System.Web.WebPages.WebPage'

I have a problem with configuring asp.net mvc application: [HttpException (0x80004005): Type 'ASP._Page_Currency_Index_cshtml' does not inherit from…
3
votes
3 answers

ASP.NET 4.0 webforms routing

I have an existing site that I'd like to convert to use routing, and after reading Scott Guthrie's post here, I built a working sample that works for most circumstances. However, since not all of the pages on the existing site match a particular…
Eyeball
  • 1,322
  • 2
  • 16
  • 26
2
votes
1 answer

Routing error mixing Web Forms and MVC

I am working on a Web Forms Web Application with mixed in MVC. I have followed the instructions from this page http://www.packtpub.com/article/mixing-aspnet-webforms-and-aspnet-mvc and it works fine in VS2010 developer server but when I try to…
2
votes
3 answers

ASP.NET HyperLink instead of LinkButton - how to avoid border around image?

I have an ASP.NET web site which contains some ImageButton controls that cause postbacks used to filter a list of products to certain groups of products. The ImageButton was created something like this: ImageButton _myImageButton = new…
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
2
votes
4 answers

Routing to an anchor on another page

I am using Web Forms Routing in ASP.NET 4 and I am trying to route to a specific location on a page. On that page I have an element like
and I'd like to jump to this anchor from another page. For this purpose I have defined a Route in…
Slauma
  • 175,098
  • 59
  • 401
  • 420
2
votes
1 answer

ASP.NET WebForms URLRouting - All Routes Receiving 404

All routes within my ASP.NET URL Routing web application are receiving a 404. However, the actual pages that exist are showing up correctly. I'm using IIS7. Any ideas?
2
votes
2 answers

Handling return URLs with ASP.NET Web Forms and Routes

I have an ASP.NET web forms application (not MVC) set up utilising routes which are defined in my Global.asax file like so; routes.Add("Login", New Route("login", New CustomRouteHandler("~/authenticate.aspx"))) routes.Add("AdditionalInfo", New…
Dooie
  • 1,649
  • 7
  • 30
  • 47
1
vote
1 answer

URL Routing and IIS6. How can I test it?

I can't seem to understand how I can find out what is erroring out when I implement URL Routing on IIS6 and Webforms. I continue to get 404 errors when I try to access a route. I add the ISAPI module as described…
Armstrongest
  • 15,181
  • 13
  • 67
  • 106
1
vote
1 answer

ASP.NET 4.0 webforms routing within master page

I just want to asked if there's a workaround in url routing using masterpage. I put the links in my masterpage (i.e. first link is a href="Bookstore/CSS" and the other link is a href="tools/toolx") if i click the first link it redirect me to the…
1
vote
1 answer

Routing in MVC application- Forcing route to go to MVC route rather than physical web form folder

I have solution with co-existing MVC and Web forms. I have a folder called New in my UI project with page as default.aspx. By default mydomain/New lands me to tohis default.aspx page. Now i want to land it to MVC controller i have created. New…
Sahil Sharma
  • 3,847
  • 6
  • 48
  • 98
1
vote
0 answers

How to do GetRouteUrl?

I want open "aspnet.pdf" file but in url show "Report.pdf" do not show the original file name on url please help me how i can do this. This is on click event dr.Read(); filePath = dr[1] + ".pdf"; string fn =…
Gurpreet Gill
  • 174
  • 1
  • 13
0
votes
1 answer

Asp.net 3.5 Sp1 Sub-Domain routing?

I was wondering is there is a way to introduce sub-domains in Asp.net 3.5 routing All i found as this http://blogs.securancy.com/post/ASPNET-MVC-Subdomain-Routing.aspx But i was looking for something more complex to allow doing wild-card…
0
votes
2 answers

Need Suggestions for ASP.Net or IIS Request URL Mangling

Environment: Server 2008 IIS 7, integrated mode .Net 4 ASP.NET WebForms Routing (which uses the same .dll as MVC routing, though I'm not sure which version) Cookieless sessions (session ID travels around on the user's URL). We have an application…
dudeNumber4
  • 4,217
  • 7
  • 40
  • 57
0
votes
1 answer

Why does my ASP.Net 4.8.1 Webform URL still show the query string?

I'm attempting what seems like a trivial set up for friendlier looking URLs with routing. I'm not getting the formatted URL, always the usual one with query strings. Here is the relevant code for the Global.asax.cs page: protected void…
0
votes
2 answers

Is there an equivalent to GetRouteUrl() at application/class level (.Net 4.8)?

Within classic webforms ASPX pages, I create URL routes using the following: var url = this.GetRouteUrl("MyRouteName", new {UserId = 123}); // Generates /UserId/123 MyRouteName is defined within the Routes.RegisterRoutes() method used at…
EvilDr
  • 8,943
  • 14
  • 73
  • 133
1
2 3