Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Sep 19, 2012 10:06 AM by mohitjain.0189
Sep 03, 2012 08:18 AM|LINK
We recently migrated from .net 2.0 to .net 4.0. We use web deployment project to build the project. In 2.0, the project was building perfecly. After migrating to .net 4.0, when we build the project using web deployment project, the build fails with following
aspnet_merge : error occurred: An error occurred when merging assemblies: ILMerge.Merge: ERROR!!: Duplicate type 'PopupMaster' found in assembly 'App_Web_popupmaster.master.cdcab7d2'.
PopupMaster is a master page in code.
We have thoroughly checked, that there is no duplicate class named 'popupmaster' in the project.
In our build outputs of .net 2.0, this assembly is not merged with other assemblies and it resides in bin folder.
Is there any way to mark this assembly to not merge in to the .net 4.0 merged output ?
Please provide a solution to this problem.
Sep 03, 2012 11:10 AM|LINK
Have you tried to use 'clean solution'?
Sep 03, 2012 03:45 PM|LINK
What do you mean by 'clean solution' ? Please specify..
Sep 03, 2012 04:39 PM|LINK
Click on Build -> Clean Solution.
Sep 04, 2012 04:27 AM|LINK
Thanks for your reply
Yes, We have tested that. The solution is building fine from there.
But if I want to merge assemblies and add a web deployment project to the solution. There it gives the error that Duplicate type PopupMaster found in assembly App_Web_popupmaster.master.cdcab7d2.
Sep 04, 2012 07:48 AM|LINK
Does it run locally, but fail when trying to run from the 'deployed server'? if so, delete the content of the bin directory in the location you are publishing to, in case you are just overwriting the same files. There's an option to delete existinf files
when publishing, it sounds like this option may not be checked with you?
Sep 04, 2012 09:51 AM|LINK
I have added a web deployment project in the solution. When I try to build web deployment project, it fails with error
Duplicate type PopupMaster found in assembly App_Web_popupmaster.master.cdcab7d2.
Sep 18, 2012 04:46 AM|LINK
please try to delete the asp.net temporary files which is located under "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files" folder or "C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files"
Sep 18, 2012 06:53 AM|LINK
All you need to do is open up the offending aspx and aspx.cs files and update two lines:
1. In the code behind file, rename the partial class. By default Visual Studio will name the class FolderName_Pagename which should result in a unique name
2. The page declaration (first line of the page) in the aspx file. You have to make sure that both the Inherits attribute and CodeBehind reference are correct.
To avoid confusing yourself, open the files independently using the solution browser because if you open the aspx and press F7 to switch to the code behind file before updating the page declaration, you'll end up editing the page you copied rather than the
Hope be helpful!
Sep 19, 2012 10:04 AM|LINK
it desn't help buddy....