Click here to Skip to main content
15,895,829 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my web site i have a master page. all the pages are working fine in root folder. and i have set of pages inside a folder called "User". these pages requires a login. after the login the first time i try to navigate to one of these pages, work fine. after that when i try to navigate to any other page it gives me an error like this..




.................................Error........................................

Server Error in '/ADWMM' 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: /ADWMM/User/User/Search.aspx

..............................................................................

im using Visual Studio Professional SP1 with Windows 7 32bit

if anyone know how to solve this please help me..
Posted
Updated 12-Jan-20 2:01am

It looks like you have a relative link error.

as you have already been to a file in /user, the next page is trying to add another /user to the path.
 
Share this answer
 
The URL you are requesting seems to be adding a second User directory:

/ADWMM/User/User/Search.aspx

Which is probably why it can't find the right page. Do your hyperlinks have an extra User directory in them?
 
Share this answer
 
Comments
ruknil 5-Jul-10 5:56am    
they are not hyperlinks i simply used a href="User/Search.aspx" for every page. i think that's why this happen. do you know how to solve this? i used a href=" because then i can give onmouseover with another picture.
Shining Legend 5-Jul-10 6:19am    
in the anchor tag mention runat="server" attribute it should work.
ruknil wrote:
they are not hyperlinks i simply used a href="User/Search.aspx" for every page



I guess you are doing this from some of the Logged in page which is inside 'User' directory. So the current location becomes ApplicationRootDir/User. And adding a link User/Search.aspx will make it ApplicationRootDir/User/User/Search.aspx
So instead, just write href="/KB/answers/Search.aspx" (or the relevant link).

Hope this helps!
 
Share this answer
 
v2
If you add them as asp:hyperlinks and set the navigateURL property in the code behind, Visual Studio will give you a drop down to select the page you want to link to. If you do this, VS will put in the correct link for you which will probably be "~/somepage.aspx".
 
Share this answer
 
Comments
ruknil 5-Jul-10 7:29am    
yes Rhys Jacob that is the solution. thank you so much for pointing out my fault.
thanks lot mate..cheersss..
Rhys Jacob 5-Jul-10 8:14am    
My pleasure Ruknil

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900