"Steve Barnett" <noname@nodomain.comwrote in message
news:eZXHG2X4GHA.3556@TK2MSFTNGP02.phx.gbl...
Quote:
>I copied and paste a form in my solution and renamed the copy (all done in
>the solution explorer) and now, when I compile the app, I get the following
>error:
>
-----------
The item "obj\Debug\SingleInstance.UnlockDlg.resources" was specified more
than once in the "Resources" parameter. Duplicate items are not supported
by the "Resources" parameter. SingleInstance
-----------
>
I have no idea what it's trying to tell me and even less idea how to fix
this. Any suggestions? Double clicking on the error takes me nowhere, so I
take it it's a build error, but where to look?
>
If I remove the form from the solution, it compiles Ok, but that's
somewhat unhelpful since I need the form!! I'm using VS2005/C#.
>
Thanks
Steve
>
It would appear that when you copy and paste a form, then rename the copy,
that VS 2005 inappropriately alters code in <first form name>.cs and <first
form name>Designer.cs.
I'd not seen this behavior, as I don't copy forms, but I'll bet it has
already been reposted as a bug (Somebody will correct me if I'm wrong, I'm
sure :) ).
To fix it, edit the files cited above, which incorrectly use the name of
your new, renamed form, to use the original form name. Your project should
then compile.
--
Peter [MVP Visual Developer]
Jack of all trades, master of none.