I am currently creating a MVC 4 web application.
I have an action that has a basic background image that always matches the arrow image, which changes in degrees depending on the information that is collected in the action.
I invoke this action using
<img src="@Url.Action("trend-image", "NonReg_Reports")" alt="background" width="245" height="105" />
This works great when it is called and just displays an HTML web page. This gives me HTML.
<img src="/nonreg-report/01495344/trend-image" alt="background" width="245" height="105">
Then I use Rotativa / Wkhtmltopdf to convert this HTML page to a PDF file. This works with the same code as above.
The problem is that I just get a white square with alternative text in it if I use the code above.
If I use <img src="~/Content/images/trend_back_medium.png" alt="astuff" /> , which is the actual background image in my project, it works fine.
The image from the above code cannot be saved anywhere due to how it is used. I think this is a problem with paths, but having tried a lot of different things, I still can't get it to work.
Any suggestions or help would be greatly appreciated. Thanks.
user1866606
source share