locked
.designer.cs and .resx RRS feed

  • Question

  • What kind of file is this?

    the one in the black block ?

    why does it have a .design to it 


    Sunday, March 16, 2014 10:35 PM

Answers

  • Start in .NET v2, implementation of partial class is possible. This means you can have multiple files carrying different part of any given classes.

    The VS2005+ IDE take adventage of this to put all "Window designer" generated code in seperate file, in order to eliminate the problem that "Window designer occasionally removed code you write" found in VS2003 era. Since this file will be regenerated everytime you "Save" in window designer, you're advised not to put any custom code in there.

    The resx file contains your Form settings in XML format that can be used to reconstruct the form. In most case it could be ignored (In my experience just the proper .Designer.cs file is enough to regenerate the Form in the designer), but I'd advise you to leave it alone anyway.

    Monday, March 17, 2014 1:44 AM
    Answerer