I'm working with asp.net (I'm a designer) and at some point during debugging it'll throw me and I'll get to an Exception objErr in the code - and when I hover it says "file not found". I assume it's an image but I've been searching and can't find anyway to pinpoint which file is missing. I hope this is enough information - if anyone could give me a direction I'll really appreciate it!
AB
Find FileMon which is in the SysInternals package from Microsoft and run it when you get near to your file issue, maybe add a filter to filter out all of the OS file operations.
You'll be able to see a file not found or access denied entry for the file if you have it set up right.
I use FileMon all the time, it is free and really helps when troubleshooting permission and file IO problems.
Ryan
I think you have not given full path for the image which you are searching.
Another problem which might be possible is when it throws an error check the page in your url and check if that page exists in your project. I wish I could help you more but I need more info for that,
Do you really have no information on which file is not found?
It is probably a misspelled filename (1 character typo's can be hard to find). So if you don't have the missing filename, debugging can be a real horror.
Take a look at the IIS log produced, Found at: C:\WINDOWS\system32\LogFiles\W3SVC1\ and search for a 403 or similar.
When referencing a file inside your project always add a "~" in front. This means that the path after the "~" sign is relative to the projects root folder.
Example:
If an .Aspx file called "Example.asp" is located in the Pages folder inside the project you want to reference it as
<asp:HyperLink ID="lnkExample" runat="server" NavigateUrl="~/Pages/Example.aspx"> Example</asp:HyperLink>
I hope this helps a bit.
Related
I am trying to publish a web app to IIS and I am getting this error in my publishing profile.
Underneath that it gives me the path to my dotnet-tools.json file and says, "...dotnet-tools.json came from another cmputer and might be blocked to help protect this computer. For more information, including how to unblock, see https://aka.ms/motw.
I went to the site listed, but frankly everything there was way over my head. I have Googled and read multiple posts, but cannot seem to find a solution. One post said to right click on the file, the properties and on the General tab, check the "unblock" box near the bottom. I have no such box on my file!
Any assistance would be greatly appreciated! Thank you.
Clean the solution then rebuild the solution
or go to the project folder find "bin" folder and delete it, then clean and rebuild the solution.
I am a super beginner and am learning as I go, so please be patient with me!
So here goes:
I am trying to make some edits on a Magento theme (removing buttons - Twitter, to be exact) and am using FireBug (Firefox Add-On) to locate the directory to remove the button.
Firebug will allow me to find the CSS directory in order to change certain things but does not show the file to make edits in to remove the button. From other similar questions, I have gathered that it is not possible to find server directory paths from apps like Firebug (or is it?); however, is there any advice or easier method to go about finding the location of the button?
Any information helps, thanks in advance.
Indeed, you cannot use firebug to find in which file that button is inserted. You have to go to magento admin, system- > configuration -> developer. Select your website in view top left. then in template path hints select yes. Now go into frontend and refresh. You will see a lot of red lines with the path to the folders where everything is. Do not do this in production as it is a negative experience for customers.
try saving the file locally by doing ctrl + s. That may give you the css file to make changes.
Check this step by step instruction:
Step 1: System >> Configuration >> Developer
your current configuration scope is set to “Default Config.” You cannot setup Magento Template Path Hints globally. You’ll need to set the Configuration Scope to a website or store configuration. When you do, you’ll see a screen like this:
Change Template Path Hints no to yes and save the configuration. Reload your front page.
For more info
When I tried to modify Microsoft forefront Unified access login.asp page and pages that comes with it ,
I prepared my custom files for css; inc files ; InstallAndDetect ..etc
but When i inserted those files under CustomUpdate folders i got this error :
" An error occurred on the server when processing the URL. Please contact the system administrator. "
I tried files i prepared before by putting them in the place of the default files propvided by the system.
Ofc the naming is respecting when using customupdate files!!
Do you have any idea how can I solve this issue??
I'm afraid I don't have a proper picture of what exactly might have caused the problem in your case.
But I just went through resolving the same error message on my system (2012 R2, IIS 8) (while searching for the solution I came across your post)
And it turned out that what was causing my problems was the use of classic ASP parent paths (with "../" in them)
Switching to absolute and virtual paths solved the issue for me.
See here: http://www.iis.net/learn/application-frameworks/running-classic-asp-applications-on-iis-7-and-iis-8/classic-asp-parent-paths-are-disabled-by-default
Thank you for your answer.
Actually there was a bug with the product itself.
It didn't recognize the path to the CustomUpdate folder for any of custom folders in InternalSite folder.
I had to ask for a hot fix from Microsoft support to be able to use customized files (CSS , asp, images ).
Once the fix was installed, everything was working fine and I was able to see the customization I have done to the login page.
error CS0433: The type 'ucTerms' exists in both 'c:\Users\satyajit.singh\AppData\Local\Temp\Temporary ASP.NET Files\eoc\f63b2378\43228109\App_Web_cez09cff.dll' and 'c:\Users\satyajit.singh\AppData\Local\Temp\Temporary ASP.NET Files\eoc\f63b2378\43228109\App_Web_frn_iozf.dll'
I can see that theere is a User Control "ucTerms" which is contained in the "User Control" folder under also under the root (main solution) . I researched a lot and tried different solutions like setting the "batch = false", deleting the temporary folder but none have worked.
The web site builds successfully but this error pops up when I try to publish the website.
can anyone help me on this. I have been working on this error for last 3 days.
Thanks in advance,
Satyam
have you tried these?
Error: The type exists in both directories,
http://www.pgs-soft.com/the-type-x-exists-in-both-y1-dll-and-y2-dll.html,
http://forums.asp.net/t/980517.aspx
if none of these help, try to isolate the issue:
remove your user control from the project (make sure you save it somehwere else) to see if its only this one user control that has the issue, or every other one as well, this information may be helpful
I'm seeing this error several times an hour on my production site and am not quite sure how to fix it. I've grepped the source code and I am not using "../" anywhere in my code to generate a path.
My application is running on IIS6 on Win2003 Server. It's using URLRewriter.Net to allow the site to have friendly URLs, and I'm wondering if this could be contributing to the problem.
I've already Googled for a solution and have found several possibilities but none have worked for me.
I've tried creating a new App_Browser file to force the tagwriter settings to use a specific HtmlTextWriter, as suggested in one of the most popular solutions, but that hasn't worked for me. I haven't seen any other likely solutions.
It's probably due to using "~/something", probably on a Hyperlink control. When the physical file is at a different directory level from the friendly URL, ASP.NET uses too many ../'s in the relative URL that it generates, giving this error. If you can't just use an absolute URL instead, I believe that you can use Page.ResolveUrl("~/foo/bar") to get the proper relative URL.
Just set the Enable Parent Paths to True in the ASP settings from your website
That solved the problem for me
Use reflector to dig into the URLRewriter.Net code.
I would give your rewrite paths another once through and see if maybe there is a path that contains a folder that either doesn't exist, has been flubbed or is in fact outside the web application. Can you post the rewrite rule here?
Are you sure that you are causing the error?. Some scripts (Code Red/Nimda) troll the internet looking for a URL traversal that looks like that error.
Is this internal or external? Is it possible that your machine is getting scanned?
I was able to resolve this issue by installing .NET 3.5 SP1.