The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,740 other followers

Archive for August 8th, 2012

.NET/C#: workaround to solve small glitch with Visual Studio 2010, CodeRush with and string resources

Posted by jpluimers on 2012/08/08

CodeRush has a nice refactoring to extract a C# string into a resource.

There is a small glitch that when you press undo after that, and there was no string file in your project, then the empty resource file is not always saved.

Upon building your project, you will get an error like this:

---------------------------
Microsoft Visual Studio
---------------------------
The item 'Resources.resx' does not exist in the project directory. It may have been moved, renamed or deleted.
---------------------------
OK
---------------------------

The Resources.resx file is not visible in your Solution Explorer, so you cannot delete it there.

You have to manually edit your .csproj file and remove the Resources.resx reference there.

I’ve had this happen only a couple of times, and cannot yet reproduce this. Until I can reproduce, this is a workaround to remedy the effects.

–jeroen

Posted in .NET, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, Development, Software Development | Leave a Comment »

 
%d bloggers like this: