.NET Questions and Solutions

As a software engineer, I focus on .NET, especially asp.net, C#, WCF and so on, and I am also very interested in Search Engine Optimization.

Entries Tagged ‘microsoft asp’

FIX: You experience out of memory exception errors on a Web server that has ASP.NET 1.1 installed

Symptoms
You experience out of memory exception errors on a Web server that has Microsoft ASP.NET 1.1 installed. ASP.NET 1.1 is installed as part of the Microsoft .NET Framework 1.1 and the Microsoft .NET Framework 1.1 Service Pack 1 (SP1).
Resolution
This problem occurs because the MobileCapabilities object does not expire from the cache as expected. You can use an instance of the MobileCapabilities object to read the capabilities of the requesting browser and device.

Error messages when you use Live Meeting Intranet Portal: “Exception_1013: The Directory Service returned an exception” and “Inner Exception(1): Index was out of range”

Symptoms
When you use Microsoft Live MeetingIntranet Portal, you may receive the following error messages:

Exception_1013: The Directory Service returned an exception

Inner Exception(1): Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: indexThe call stack trace that is generated when this issue occurs may resemble the following call stack trace:

at System.Collections.ArrayList.get_Item(Int32 index)at System.DirectoryServices.ResultPropertyValueCollection.get_Item(Int32 index)at Microsoft. LiveMeeting.DirectoryService.GetDirectoryUser(AuthenticatedUser authUser)at Microsoft.LiveMeeting.Services.GetDirUser(AuthenticatedUser authUser)
Resolution
This issue occurs if you do not use Microsoft ASP.NET version 1.1.4322.
Additionally, this issue may occur if the Live Meeting Intranet Portal virtual directory is not set to use ASP.NET version 1.x.

A System.Resources.MissingManifestResourceException exception occurs when you try to access a localized resource

Symptoms
In a Microsoft ASP.NET application, when you try to access a localized resource, a System.Resources.MissingManifestResourceException exception may occur, and your Web browser may display an error message that is similar to the following error message:

Server Error in ‘/MyApp’ Application.
Could not find any resources appropriate for the specified culture (or the neutral culture) in the given assembly. Make sure “MyApp.strings.resources” was correctly embedded or linked into assembly “MyApp”. baseName: MyApp.strings locationInfo: <null> resource file name: MyApp.strings.resources assembly: MyApp, Version=VersionNumber, Culture=neutral, PublicKeyToken=null
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.Resources.MissingManifestResourceException: Could not find any resources appropriate for the specified culture (or the neutral culture) in the given assembly. Make sure “MyApp.strings.resources” was correctly embedded or linked into assembly “MyApp”. baseName: MyApp.strings locationInfo: <null> resource file name: MyApp.strings.resources assembly: MyApp, Version=VersionNumber, Culture=neutral, PublicKeyToken=nullNotesIn the error message, MyApp is a placeholder for the name of your ASP.NET application.In the earlier error information, VersionNumber is a placeholder for the version number of the primary assembly for your application.
Resolution
This problem occurs if you use a localized resource that exists in a satellite assembly that you created by using a .resources file that has an inappropriate file name. This problem typically occurs if you manually create a satellite assembly.
To manually create a satellite assembly, you must first run the Resource File Generator (Resgen.exe), and then you must run the Assembly Linker (Al.exe). When you run Resgen.exe, if you do not specify the file name of the output file while you convert an XML-based resource format (.resx) file to a .resources file, Resgen.exe creates a .resources file that has the same file name as the input file. If the file name of your XML-based resource format file does not start with the namespace name of your application, the file name of the .resources file will not contain this namespace name either. You may run Al.exe to create a satellite assembly that contains the localized resources that exist in the .resources file. However, when you try to access a localized resource that exists in the satellite assembly, the behavior that is mentioned in the “Symptoms” section occurs.