Please tell me what is use of:
<add assembly="*"/>
because of this i am getting error:
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Exception of type 'System.OutOfMemoryException' was thrown.
Source File: C:\Windows\Microsoft.NET\Framework\v2.0.50727\Config\web.config
Thanks
As per MSDN:
you can specify the asterisk (*) wildcard character to add every assembly within the private assembly cache for the application, which is located either in the \bin subdirectory of an application or in the.NET Framework installation directory (%systemroot%\Microsoft.NET\Framework\version)
Since you most likely don't need to add all assemblies to your application I would suggest adding only the ones you are actually using and leave the <add assembly="*" /> part out, which should solve your problem.
The Indexing Service may cause such a problem. If Indexing Service is running on your computer then, you should exlude it from indexing directories:
Open Computer Management from Administrative Tools on your computer.
Navigate to Indexing Service under Services and Applications.
Select "Web" under Indexing Service.
On the right pane Right Click mouse and chose New > Directory.
Add the paths where your web pages are (Ex: c:\inetpub).
Repeat this for all virtual directories not under inetpub.
Related
I got following error while hosting Web API in IIS 10.0
Error Code : 0x800700b7
Config Error : Cannot add duplicate collection entry of type 'add'
with unique key attribute 'FileExtension' set to '.idq'
Please tell me the solution
I think the port number is used by another project. You can try with different port.
Adding the same mime types at the application level (which IIS will place into a web.config file) and the site level (which IIS will place into the applicationHost.config file) may cause a conflict.
One solution would be to simply remove one of the two conflicting mimeMap extensions from one of the config files. However, in some rare scenarios, the IIS administrator may need to not remove one of the two conflicting mime mappings. If both mine maps are needed, the way to get around the conflict is to make one simple addition to the web.config which will do a REMOVE immediately prior to doing an ADD.
So if your application installation adds the following line to the web.config. . .
… And this line creates a conflict with the same mime map in the applicationhost.config file, all you have to do is add the following line ABOVE that line so that it will look like the following:
<remove fileExtension=".xyz" />
<mimeMap fileExtension=".xyz" mimeType="xml/text" />
Doing the removal before the add should be fine even when the .xyz mime map doesn't exist at a higher level.
you could also do it by using iis GUI.
1)open iis manager.
2)select your site or application.
3)double click mime type from the middle pane.
4)Remove the MIME Type entry ".idq".
I created a project (ASP.NET empty web application) WebApplication1.
I also have Default.aspx/login.aspx/GoogleCallBack.aspx
when I run the application, the error shows
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: Could not load type 'WebApplication1.Global'.
Source Error:
Line 1: <%# Application Codebehind="Global.asax.cs" Inherits="WebApplication1.Global" Language="C#" %>
Source File: /global.asax Line: 1
Does anyone know how to fix it ? thank you
Just Check Project -> Properties -> Web
Project Url --- Click on (Create Virtual Directory)link => This will ask you to map to correct folder location say ok.
This problem Occured when we move our project to different directory and IIS still refers to old directory.
Does your project have a "Global.asax.cs"? If so, does it compile?
F5 is for "Debug." This is about building the solution. Ctrl+Shift+B would be the hot-key combination to build and look for compiler errors.
This topic is a duplicate of "Parser Error Message: Could not load type" in Global.asax.
The most voted answer is provided by Facio Ratio: Your local web server is running different code than what you're actually working on. Ensure you have stopped debugging, stop your local web server, clean and rebuild as Peter suggested, double-check your global.asax and global.asax.cs, and try again. If this doesn't work and you are using local IIS, try removing the site in IIS Manager and recreating it manually.
I have currently moved my asp.net 4.0 web application onto IIS7 (windows 2008 server). I used a test folder to hold files from a directory on the localhost machine, however; when I moved the aspx file over and changed the code(on the server), the application keeps throwing this error
Could not find a part of the path 'C:\Users\***\Desktop\TestFolder\'.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\Users\****\Desktop\TestFolder\'.
I only have two functions that deal with directories and neither function points to that test directory anymore.
private int checkForFileNumbers()
{
string url = "c:/***/realfolder";
DirectoryInfo directory = new DirectoryInfo(url);
return directory.GetFiles().Length;
}
private void checkForFiles()
{
string url = "c:/***/realfolder";
DirectoryInfo dir = new DirectoryInfo(url);
foreach (FileInfo files in dir.GetFiles())
{
FileDropDownList.Items.Add(files.Name);
}
}
I have tried commenting everything in this aspx file out, only to find that this problem still occurs. I performed the issrestart from the cmd line and nothing changed. Any help would be appreciated.
This is a deployment problem. Your error message is clearly out of sync with your current code. The actual code that is being run from IIS must be coming from an out-of-date binary. As a starting point, I would delete all DLLs in your bin directory on the server and redeploy fresh DLLs. The may also require you to refresh your aspx files depending on what kind of project type you're using.
Once you get this sorted out, I would take another look at how you are deploying updates to your site. Visual Studio and IIS 7 offer some neat deployment options if you want to go that way. Also, you could deploy via Git or SVN. But deployment by manual replacing single files is going to lead you to the type of trouble you are currently experiencing.
If realFolder directory exists under root of your web-app or itself is root then use Server.MapPath method to get real path of virtual folder.
For instance,
String rootPath=Server.MapPath("~"); // It will return real path of current web-app's root.
//OR - In case if want use Server property from separate code file.
String rootPath=HttpContext.Current.Server.MapPath("~/testFolder");
Since you're not referencing the path in your code, it's probably either in one of your config files, HttpModules, Global.asax, or perhaps a DLL.
What other components are you using?
Before moving it to a server, have you tried running the site under IIS on your local machine? Maybe attach a debugger and see where the error is thrown?
Oh, FWIW, the IIS AppPool identity will need to have read permission for your C:/***/whatever folder.
Problem Description:
Publishing JSP pages work with the following for broker.config.
<Publications DefaultRootLocation="/apps/tridion/wwwroot"
DefaultRootDataLocation="/apps/tridion/wwwroot/data">
Publication pages and directories (based on structure groups) will publish under the wwwroot directory.
I changed the root location for for pages to the following (no longer using "/apps/tridion/wwwroot").
<Publications
DefaultRootLocation="/apps/ekibemobile/jboss-eap-5.1.0/jboss-eap-5.1/jboss-as/server/default/deploy/MobileTermsConditions.war/basic"
DefaultRootDataLocation="/apps/ekibemobile/jboss-eap-5.1.0/jboss-eap-5.1/jboss-as/server/default/deploy/MobileTermsConditions.war/basic/data"
>
Publishing now returns:
A processing error occurred processing a transport package Could not deploy page
[Page id=tcm:493-637128-64 Title=010. Privacy Policy],
IO error creating new page, No such file or directory, No such file or
directory, IO error creating new page, No such file or directory, No
such file or directory
I confirmed the required permission on the above folder on the Linux webserver. I also tried the following in the node of broker.config
<Publication Id="493"
DocumentRoot="/apps/ekibemobile/jboss-eap-5.1.0/jboss-eap-5.1/jboss-as/server/default/deploy/MobileTermsConditions.war/basic"
DataRoot="/apps/ekibemobile/jboss-eap-5.1.0/jboss-eap-5.1/jboss-as/server/default/deploy/MobileTermsConditions.war"
/>
I get the same error with this config. Please suggest what I'm missing!
Some suggestions:
Double check that the directories you've specified do exist.
Ensure that the user running the deployer process has access to write to the directory
Edit both the deployer and broker configs to enable debug logging. Restart everything and repeat your test, then check the logs.
Note that the locations you have specified are configured in the broker configuration, but the deployer process is the relevant one because it will instantiate a broker.
Your best bet would be to make the changes on the deployer.config (cd_deployer_config.xml) on the Tridion Presentation Server.
I've got a C# 3.5 web service that works fine when its accessed at http://domain/foo/bar/WS.asmx
The /foo/bar part could change in the future so I want to give people a more stable URL that I could update without requiring any changes from them. I created a site in IIS and set it's Home Directory to where WS.asmx is. Now when I try to access it from http://domain2/WS.asmx, I get:
Description: An error occurred during
the parsing of a resource required to
service this request. Please review
the following specific parse error
details and modify your source file
appropriately.
Parser Error Message: Could not create
type 'Namespace.WS'.
Source Error: Line 1: <%# WebService
Language="C#" CodeBehind="WS.asmx.cs"
Class="Namespace.WS" %>
The assemblies in both cases are at http://domain/bin but when I come from domain2 it doesn't seem to know where to find the \bin that is 3 folders up in the file system.
The namespace/classes are more descriptive than that, I just made them basic for the purposes of this question.
Sorry, AFAIK you can't pull DLLs from explicit file paths outside the root of your website. You generally have two choices:
1) use the /bin directory of the current app (make a copy of the other app's /bin)
2) put the DLL into the Global Assembly Cache (GAC)
BTW, this has been asked in a few other spots on SO, like here.
One thing you could do, if your /bin DLLs are only used inside /foo/bar/, is to convert into an IIS application, and then move the DLLs into a new /foo/bar/bin directory. Then you'd only have one copy of the DLL's to manage.