I can confirm that this is a limitation in the Android SDK. Eclipse suffers the same problem, it can't handle layout files which have a BOM. I'm going to add a check for this specific issue and show a more meaningful error message when it happens. To fix it you can just remote the <?xml..> header in the included file, or you can remove the BOM by opening the file with the hex editor (Open With->Hex Editor) and deleting the first 3 bytes.
Lluis. El 17/05/2012, a las 09:27, Lluis Sanchez Gual escribió: > The problem seems to be with files which have a byte order mark. MonoDevelop > creates new files without a BOM, and that's why it then works. At least I > know what's the issue now. > > > El 17/05/2012, a las 05:08, NebulaSleuth escribió: > >> >> Lluis Sanchez Gual wrote >>> >>> >>>> I am unable to reproduce this problem. Can you send me a sample layout >>>> (+included files) I could use to reproduce the error? >>>> >>> >> >> So I was going to give you an example, but I wanted to simply it first. So >> what I found was very strange indeed. >> >> If I created a NEW layout using "rightclick on layout->add->new >> item->Android Layout" and then copied the contents from an included layout >> that didn't work, and then changed the include to refer to the new file. >> Voila it started to work. >> >> The contents of the new file are identical to the original file, just that >> it is a different file. If I change the include to point back to the old >> file, it fails again. >> >> So I suspect, if I give you the files, it will probably work for you. >> >> The project was converted from a Mono 4.0.6 project, so it might have >> something to do with it. Not sure what is confusing it, but there is a >> workaround. :) >> >> I also am using VS2010 on Win7 x64. >> >> >> >> >> >> -- >> View this message in context: >> http://mono-for-android.1047100.n5.nabble.com/Designer-Error-tp5709771p5709841.html >> Sent from the Mono for Android mailing list archive at Nabble.com. >> _______________________________________________ >> Monodroid mailing list >> Monodroid@lists.ximian.com >> >> UNSUBSCRIBE INFORMATION: >> http://lists.ximian.com/mailman/listinfo/monodroid > _______________________________________________ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid