Specified cast is not valid with setting up SQL Server

Topics: Business Logic Layer, Controls
Jan 3, 2014 at 8:11 PM
I'm trying to set up the blog to use sql server and I'm throwing this Specified cast is not valid error. I'm using the web.config file that was included with the SQL scripts. Any help would be great.
[InvalidCastException: Specified cast is not valid.]
System.Data.SqlClient.SqlBuffer.get_SqlGuid() +72
System.Data.SqlClient.SqlDataReader.GetGuid(Int32 i) +51
BlogEngine.Core.Providers.DbBlogProvider.FillBlogs() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Providers\DbBlogProvider.cs:449
BlogEngine.Core.Blog.get_Blogs() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Blog.cs:422
BlogEngine.Core.Blog.get_CurrentInstance() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Blog.cs:499
BlogEngine.Core.Right.EnsureBlogInstanceDataLoaded() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Security\Right.cs:547
BlogEngine.Core.Right..cctor() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Security\Right.cs:111

[TypeInitializationException: The type initializer for 'BlogEngine.Core.Right' threw an exception.]
BlogEngine.Core.Right..ctor() in c:\rtur\src\Codeplex\be\BlogEngine\BlogEngine.Core\Security\Right.cs:539

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) +0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache) +98
System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean fillCache) +241
System.Activator.CreateInstance(Type type, Boolean nonPublic) +69
System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +1136
System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +111
System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture) +23
System.Web.HttpRuntime.CreateNonPublicInstance(Type type, Object[] args) +60
System.Web.Configuration.HttpModulesSection.CreateModules() +221
System.Web.HttpApplication.InitModules() +28
System.Web.HttpApplication.InitInternal(HttpContext context, HttpApplicationState state, MethodInfo[] handlers) +828
System.Web.HttpApplicationFactory.GetNormalApplicationInstance(HttpContext context) +304
System.Web.HttpApplicationFactory.GetApplicationInstance(HttpContext context) +107
System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) +327