{"id":38,"date":"2015-02-25T06:37:32","date_gmt":"2015-02-25T06:37:32","guid":{"rendered":"https:\/\/jmrowe.com\/blog\/?p=38"},"modified":"2015-02-26T00:57:01","modified_gmt":"2015-02-26T00:57:01","slug":"simple-data-sqlite-referencing-wrong-version-solved","status":"publish","type":"post","link":"https:\/\/jmrowe.com\/blog\/simple-data-sqlite-referencing-wrong-version-solved\/","title":{"rendered":"Simple.Data.SQLite referencing wrong version [SOLVED]"},"content":{"rendered":"<p>I started to use Simple.Data.SQLite and would install through Nu-get and noticed Simple.Data tried to reference System.Data.SQLite version 1.0.91.0 while Nu-get would only install vserion 1.0.94.0<\/p>\n<p>This would cause an error while trying to compile and it would fail.<\/p>\n<p>The error would be described as below:<\/p>\n<p>&nbsp;<\/p>\n<p>System.IO.FileLoadException: Could not load file or assembly &#8216;System.Data.SQLite, Version=1.0.91.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139&#8217; or one of its dependencies. The located assembly&#8217;s manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)<\/p>\n<p>SOLUTION<\/p>\n<p>To fix this, I added an entry into the app.config file to point version 1.0.91.0 to the newer version 1.0.94.0<\/p>\n<p>&nbsp;<\/p>\n<pre class=\"lang:default decode:true  \">&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;\r\n&lt;configuration&gt;\r\n  &lt;configSections&gt;\r\n        &lt;!-- For more information on Entity Framework configuration, visit http:\/\/go.microsoft.com\/fwlink\/?LinkID=237468 --&gt;\r\n    &lt;\/configSections&gt;\r\n\t&lt;startup useLegacyV2RuntimeActivationPolicy=\"true\"&gt;\r\n\t\t&lt;supportedRuntime version=\"v4.0\" sku=\".NETFramework,Version=v4.5\" \/&gt;\r\n\t&lt;\/startup&gt;\r\n&lt;runtime&gt;\r\n\t &lt;assemblyBinding xmlns=\"urn:schemas-microsoft-com:asm.v1\"&gt;\r\n\t&lt;dependentAssembly&gt;\r\n &lt;assemblyIdentity name=\"System.Data.SQLite\" publicKeyToken=\"db937bc2d44ff139\" \/&gt;\r\n &lt;bindingRedirect oldVersion=\"1.0.91.0\" newVersion=\"1.0.94.0\"\/&gt;\r\n&lt;\/dependentAssembly&gt;\r\n\t \t    &lt;\/assemblyBinding&gt;\r\n\t \r\n\t&lt;\/runtime&gt;\r\n&lt;\/configuration&gt;<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I started to use Simple.Data.SQLite and would install through Nu-get and noticed Simple.Data tried to reference System.Data.SQLite version 1.0.91.0 while Nu-get would only install vserion 1.0.94.0 This would cause an error while trying to compile and it would fail. The error would be described as below: &nbsp; System.IO.FileLoadException: Could not load file or assembly &#8216;System.Data.SQLite, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-38","post","type-post","status-publish","format-standard","hentry","category-c"],"_links":{"self":[{"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/posts\/38","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/comments?post=38"}],"version-history":[{"count":2,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/posts\/38\/revisions"}],"predecessor-version":[{"id":40,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/posts\/38\/revisions\/40"}],"wp:attachment":[{"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/media?parent=38"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/categories?post=38"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jmrowe.com\/blog\/wp-json\/wp\/v2\/tags?post=38"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}