Unable t cast... IView

5 views
Skip to first unread message

Josh Coffman

unread,
Nov 20, 2009, 3:50:09 PM11/20/09
to spark-dev
Hi,

  I'm using/attempting to precompile my views.  I'm getting closer in that it compiles but I get a runtime error stating it cant cast to an IView type.  It happens in SparkViewFactory.BuildResult(..) at entry.CreateInstance().  Odd that it should compile but not run.  The only thing I can think is that I'm using System.Web.MVC from the GAC and have it set to copy local.  Maybe I have to use the version Spark was built with?

  Also, I used the source to make a debug build of Spark so I could debug the problems I've been having.  Any chance that's part of my problem.  The error detail is below.  I appreciate any help.

Thanks,
Josh


Error:
System.InvalidCastException occurred
  Message="Unable to cast object of type 'ToasterWeb.Controllers.View455cc0092e144fb08fe4d44670b2ac69' to type 'System.Web.Mvc.IView'."
  Source="Spark.Web.Mvc"
  StackTrace:
       at Spark.Web.Mvc.SparkViewFactory.BuildResult(RequestContext requestContext, ISparkViewEntry entry) in c:\dev\oss-git\spark\src\Spark.Web.Mvc\SparkViewFactory.cs:line 197
  InnerException:



Josh C.
480-270-4578 | josh [at] computeristsolutions [dot] com | http://computeristsolutions.com

Josh Coffman

unread,
Nov 20, 2009, 3:52:33 PM11/20/09
to spark-dev
Also, looks like the request path is for {ASP.default_aspx}
Reply all
Reply to author
Forward
0 new messages