Monday, November 05, 2007

VS.NET IDE Issue - ASPX gets separated from codebehind

Sometimes in VS.NET 2005 the codebehind for the aspx file show up in the solution explorer not connected.

To Solve this problem:

  1. Close Visual Studio
  2. Open up the proj file with a text/XML editor.
  3. Scroll down till you find the <EmbeddedResource> section.
  4. Find around where you need to enter in a new resource in relation to the file you're having issues with.
  5. add this for each file except the aspx file:
    <EmbeddedResource Include="Admin\Author\MassUpload\upload.aspx.cs">
<DependentUpon>upload.aspx</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Admin\Author\MassUpload\upload.aspx.resx">
<DependentUpon>upload.aspx.cs</DependentUpon>
</EmbeddedResource>

Related Links

Form & Designer File Becoming Separated


Name
E-mail
Home page

Comment (Some html is allowed: a@href@title, b, blockquote@cite, em, i, strike, strong, sub, super, u)  

Enter the code shown (prevents robots):

Blog Posts by:

Currently Viewable:

My Twitter Updates

View Twitter Page