"Payload file does not exist" compile error


  • In Visual Studio 11 Beta I have a project that contains a xaml page, which I can use from another project.. It compiles properly and referencing it from another project in the same solution works too.

    But when I reference the dll only (so I don't have to load the project) I get a compile error:

    "Payload file 'C:\Users\Michael\Documents\....\bin\Release\TCD.Windows8.Pages\DetailsPage.xaml' does not exist."

    Note that following to \Release there's one more directory (the pages namespace), that does not exist, because the compiler does not create subdirectories in Release..

    The very same approach used to work in Visual Studio 11 Developer Preview!

    is this a bug or something? Or am I missing something?



    Life is unsure - always eat the dessert first!

    Tuesday, March 20, 2012 9:05 AM


All replies

  • Please see http://social.msdn.microsoft.com/Forums/en-US/winappswithcsharp/thread/b20ca4a5-8293-4da7-859e-6759a2a76f9d and let m eknow if you have any further questions.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator

    Tuesday, March 20, 2012 7:59 PM
  • yes, that's the issue. So all I have to do is to remove the user control xaml file from the debug directory of the application and then it compiles?

    Do I have to do this every time? (and why doesn't it work the first time I compile, when no debug directory exists?)

    Will there be an ultimate solution for this? Its absolutely necessary that user controls can be referenced in a single DLL!!



    Life is unsure - always eat the dessert first!

    Wednesday, March 21, 2012 11:31 AM
  • 1) There's a bug in the folder layout in VS2011 for this scenario - that's why you have to do it every time.

    2) You're going to hate this - this is the ultimate solution.  Metro apps do not allow for embedded content, and that includes XAML pages.  Distributing classes is going to have to be done as a package of dlls and other resources, not a single dll.  Those responsible for this behavior have heard all of the issues around this, and it's not going to change.

    Matt Small - Microsoft Escalation Engineer - Forum Moderator

    Wednesday, March 21, 2012 2:24 PM