My Fix for the “CreateRiaClientFilesTask task failed unexpectedly. — Attempted to access an unloaded AppDomain” error

I finally found a solution to the “CreateRiaClientFilesTask task failed unexpectedly. — Attempted to access an unloaded AppDomain” problem in Visual Studio which had been affecting me for many weeks on my current project.

Googling it seems many people are struggling with it; it seems like this is a catch all error, not necessarily related to unloaded domains.

What worked for me was to close ALL xaml editor windows in visual studio, and close all browser windows that have silverlight open.

 Then try the build and see if it works. Sometimes it may take 30-60 seconds before it works.  The key seems to be making sure there are no WPF or Silverlight classes loaded at ALL in the system, then try the build.

 Let me know if that works for you,


About postagilist

Architect, Manager, Developer, Musician, Post-Agile thought leader
This entry was posted in Uncategorized and tagged , , , , . Bookmark the permalink.

3 Responses to My Fix for the “CreateRiaClientFilesTask task failed unexpectedly. — Attempted to access an unloaded AppDomain” error

  1. Mivoat says:

    That didn’t work in my case but then it seems this error can be caused for many different reasons.

    This time I read further into the error message and saw that there was an invalid child element in web,config

    When I fixed that, the “CreateRiaClientFilesTask task failed unexpectedly” error went away.

    • Kishor says:

      this worked like magic. Weird but true, I removed <Authenticaltion mode= xxx and <identity impersonate =XXx tags from web.config and the build succeeded. Then i remembered it only started after i added those tags in the web.config

  2. Edison says:

    Error –> “The createriaclientfilestask task failed unexpectedly”
    VS 2010
    Framework 3.5
    Agregar IIS
    SQL 2005 Full
    Microsoft Silverlight 4 Developer Runtime
    Microsoft Silverlight 4 Tools for Visual Studio 2010
    Microsoft Silverlight 4 SDK
    Microsoft Silverlight 4 Tools Package
    WCF RIA Services RC

    Tuve el problema por 2 semanas; la solución, en le menú de vs2010 actualizé telerik y listo funcionando

    I had the problem for 2 weeks, the solution, we un updating vs2010 telerik menu and ready to operate

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s