1

I have an .ascx file embedded in my MVC app using this extension. In the ascx there is a asp:Chart object.

When I open my page http://localhost:56854/Machines/Details/1 there is no chart image. Looking at page source I've found that there is problem with path to ChartImg.axd. The image got

src="/Machines/Details/ChartImg.axd?i=chart_8b0e12daec9447feb9986442e53243d2_0.png&g=becaa2f59bec483eab9e9103620711eb"

Accesing just

localhost:56854/ChartImg.axd?i=chart_8b0e12daec9447feb9986442e53243d2_0.png&g=becaa2f59bec483eab9e9103620711eb

in web browser gave me correct image. My question is: how to change this path?

johnatann
  • 145
  • 11

1 Answers1

1

I've found the solution. Just add these line to the RouteConfig.cs file:

routes.IgnoreRoute("{resource}.axd/{*pathInfo}");        
routes.IgnoreRoute("{controller}/{resource}.axd/{*pathInfo}");
routes.IgnoreRoute("{controller}/{action}/{resource}.axd/{*pathInfo}");
johnatann
  • 145
  • 11