Zum PortalStatistikMeine LinksMein PhotostreamMeine GalerieMein Lifestream (beta)
 
AboutEquipmentWeblogSit Back & Joy » 2007 » June
Weblog
 

Unable to get the project file from the webserver

Sometimes when working with Web-Projects in Visual Studio 2003 i’m getting this error message while all settings of IIS and the project files seem to be ok. Now I found one solution for this problem: clear up the VSWebCache folder in your documents and settings folder and it should work again. The cache seems to be poorly maintained by VS2003 so it could cause problems when the project structure has been reworked.

ResourceManager again…

So I think I found out the reason for the curious naming conventions of the resource namespaces: if you compile your project with visual studio, the full default namespace of the project and the resource filename build the resource name. If you build it with NAnt only the filename of the resx-file builds the resource name. This is very annoying because at development time we build mostly with visual studio and at deployment time we build and pack our projects with NAnt.

So what’s the solution? When you create a Windows Form or an ASPX Webpage within Visual Studio it will link code and resource files together. The compiled in resources then have the namespace of the class from the form or page. You can clean up the code to have only a class definition in it so you do not have to compile in all the references a WinForm needs ;-)

Using .NET Resourcemanager

Everytime I give the ResourceManager a chance I’m running into the same problem: usually I get a ManifestException ” Could not find any resources appropriate for the specified culture”. So, what’s the problem? When you create an instance of ResourceManager you have to supply the root name of the resources and the assembly of them.

The difficult thing is the root name! I thought this is given in the form <AssemblyName>.<ResourceFile> (without a file extension). But that’s not always true. To make sure you have the right name just open ildasm and examine the assembly with your embedded resources. The manifest contains an entry beginning with .mresource public. The name after these words is the right resource root name (without the .resources extension).

Here’s an example. The manifest contains the entry .mresource public De.Speedesign.CustomMessages.resources. So you have to create the ResourceManager this way:

ResMngr = new ResourceManager("De.Speedesign.CustomMessages", typeof(MyClass).Assembly);

Usually it’s a good practice to hold the ResourceManager in a static variable and create it only once.

News from Ed & Fred

SonnenalleeIn February I introduced Ed & Fred which came to me in three sorts of flavours (Classico, Ed & Fred and Sonnenallee). On this morning I made a cup of the Espresso “Classico” which was the last of the three sorts I was testing. I am stunned about the fine but full flavoured taste of this Espresso. So my favourite out of the three Ed & Fred espresso’s is “Classico” by far!

 

Suche im Blog

Letzte Kommentare

Achim (About)
Hallo, wenn Du Bilder aus meinem Flickr-Photostream meinst, da ist die Lizenz bei dem jeweiligen Bild angegeben. Ansonsten halt wie immer: bei konkretem Interesse nachfragen mit Angabe des Bildes ...
saemideluxe (About)
Hallo Achim Eine Frage bezugs copyright der Bilder in deiner Gallery: Darf ich Bilder von deiner Gallery auf meiner Seite verwenden? Und wenn ja, unter welchen Bedingungen? mfg saemideluxe
Daniel (Und noch ein bisschen Vintage Hifi...)
Hier meine Tips zum Thema Vintage Hifi Tuner von K+H (Klein+Hummel) und Bandmaschine + Verstärker von Revox (A77 und A75)
Achim (EOS 7D, Lightroom 3 und ein Nachmittag)
Hi. Die Automatik ist (mit meinem 17-40L an der 7D bei 17mm) hervorragend. Das Kameraprofil ist ja auch nicht soo wichtig. Jedenfalls musste ich nur einen Haken setzen und Verzeichnung und Vignetti...
det hol (EOS 7D, Lightroom 3 und ein Nachmittag)
automatischen Objektivkorrektur, alles gut und schön aber für die 7D gibt es keine Daten. Und es ist fraglich ob dies Automatik wirklich so gut ist. Weil ein Objektiv, sagen wir mal ein 70-200mm,...
 
 
 
© 1999-2009 by speedesign.de - Alle Rechte vorbehalten
powered by Wordpress und dem SitBackAndJoy-Theme v1.4
Theme Icons (Diagona Iconset) by pinvoke.com

Entwickelt mit Eclipse auf einem Mac
Danke an Nicole (meine grosse Liebe) für die ehrliche und schonungslose Kritik.