Getting

Discussion in 'ASP.NET 2.0' started by Tonyg, Aug 4, 2007.

  1. Hello.


    I have an ASP.NET 2.0 web site with a master page that works fine when itest it in VS2005, but when i upload it tomy discountasp.netsite, it gives the error at the end of this postfor one of the links. Here is the line that has the link:
    <div class="readmore"><a href="/CoyneWebServices/File Maintenance/Warehouses.aspx" title="More info">&amp;raquo; more</a></div>


    I tried putting a tilde"~" after the href=", but it gives an error for that line.

    Any help would be gratefully appreciated.


    Thanks,
    Tony


    Server Error in '/' Application.





    The resource cannot be found.


    Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.

    Requested URL: /CoyneWebServices/File Maintenance/Warehouses.aspx






    Version Information:Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.210
     
  2. Tony,

    Have you tried making the <a> tagan <asp:HyperLink> tag instead?By adding a '~' to your <a> tag you'll definately get a server error. The '~' will only resolve the root directory if it is used in a server control such as an <asp:HyperLink>.

    Making the link a asp:HyperLink should fix the problem.

    Rookie
     

Share This Page