最近做一个winform项目,因为数据库用的表很少,所以用的是轻量级数据库sqlite。sqlite的优点很多,但是他要分两个版本,32位或者64位,不能同时兼容。

我遇到的问题是,我在开发端用的是.net4.5的开发版本的dll:

Precompiled Binaries for 64-bit Windows(.NET Framework 4.5)

我在开发端直接调用这个dll都是OK的,没有问题。但是我把程序部署到客户机上的时候,就会出现报错

Could not load file or assembly System.sqlite.dll or one of it's depedencies 无法找到模块

网上另外一个人zhu2695说的是缺少一个Visual C++ runtime library,这个我没试,我不知道我的客户机是不是这个原因。我的解决方法是在客户机安装相应的sqlite的安装程序,安装之后,就可以解决问题了,下面附上32位和64位的下载链接,直接安装就可以了。

32位:http://system.data.sqlite.org/downloads/1.0.96.0/sqlite-netFx45-setup-bundle-x86-2012-1.0.96.0.exe

64位:http://system.data.sqlite.org/downloads/1.0.96.0/sqlite-netFx45-setup-bundle-x64-2012-1.0.96.0.exe

要下载混合模式的安装文件,否则不能起作用。

我还想翻译一下sqlite官网.net版本下载的第一段话:

大体的意思是所有这页面的下载文件都没有包含“static”这个词,所以为了在目标机器上成功的执行你的程序,你需要安装合适的版本的Microsoft Visual C++ Runtime Library。同时应该注意到那些包含"setup"的安装包,已经包含了Microsoft Visual C++ Runtime Library的安装包。

这大概就解释了为什么我安装了sqlite的setup文件之后我的客户机就正常的原因了吧。

Could not load file or assembly system.data.sqlite.dll or one for it's depedencies的更多相关文章

  1. IIS中发布后出现Could not load file or assembly'System.Data.SQLite.dll' or one of its depedencies

    [问题]在我本机的开发环境c#连接sqlite3没有问题,可是release版本移植到其他的机器就提示Could not load file or assembly'System.Data.SQLit ...

  2. Could not load file or assembly'System.Data.SQLite.dll' or one of its depedencies

    安装对应的 Microsoft Visual C++ 2010 Redistributable Package (x86)   If your download does not start afte ...

  3. SQLite 解决:Could not load file or assembly 'System.Data.SQLite ... 试图加载格式不正确的程序/or one of its dependencies. 找不到指定的模块。

     Could not load file or assembly 'System.Data.SQLite.dll' or one of its dependencies. 找不到指定的模块. 错误提示 ...

  4. Could not load file or assembly 'System.Data.SQLite' or one of its dependencies

    试图加载格式不正确的程 异常类型 异常消息Could not load file or assembly 'System.Data.SQLite' or one of its dependencies ...

  5. Could not load file or assembly 'System.Data.SQLite' or one of its dependencies. An attempt was made to load a program

    今天同事在一个服务器(winserver 2008 x64)上新建了一个IIS(7) 网站,但是报了如下错误: Could not load file or assembly 'System.Data ...

  6. Could not load file or assembly 'System.Data.SQLite ... 试图加载格式不正确的程序

    坑爹的System.Data.SQLite. 先给出下载地址:http://system.data.sqlite.org/index.html/doc/trunk/www/downloads.wiki ...

  7. Could not load file or assembly 'System.Data.SQLite' or one of its dependencies. 试图加载格式不正确的程序。

    出现上述问题的原因是,所加载的程序集中有32位的,也有64位的,IIS 7 程序池 在Windows下.Net FrameWork是64位的,要想正确使用,需要对程序池进行配置.如下图所示:

  8. Could not load file or assembly'System.Data.SQLite.dll' or one of its depedencies

    [问题]  在我本机的开发环境c#连接sqlite3没有问题,但是release版本号移植到其它的机器就提示Could not load file or assembly'System.Data. ...

  9. Could not load file or assembly 'System.ServiceModel.DomainServices.Hosting'.系统找不到指定文件

    项目部署到服务器后出现如下错误信息: Parser Error Message: Could not load file or assembly 'System.ServiceModel.Domain ...

随机推荐

  1. handy源码阅读(六):udp类

    分为UdpServer类和UdpConn类. struct UdpServer : public std::enable_shared_from_this<UdpServer>, priv ...

  2. linux运维、架构之路-Kubernetes本地镜像仓库+dashboard部署

    一.部署docker registry            生产环境中我们一般通过搭建本地的私有镜像仓库(docker registry)来拉取镜像. 1.拉取registry镜像 [root@k8 ...

  3. HTML和CSS实现图片翻转效果

    实现图片翻转,首先来分析一下我们希望实现的是怎样的翻转效果?又该如何去实现呢? 一.希望实现的效果 页面上的图片在光标悬停在上面的时候会发生翻转效果,翻转过后显示出背面的说明文字. 鼠标没有悬停在上面 ...

  4. JavaScript性能优化之小知识总结

    1.避免全局查找 在一个函数中会用到全局对象存储为局部变量来减少全局查找,因为访问局部变量的速度要比访问全局变量的速度更快些 2.定时器 如果针对的是不断运行的代码,不应该使用setTimeout,而 ...

  5. 超大文件上传方案(ASP.NET)

    ASP.NET上传文件用FileUpLoad就可以,但是对文件夹的操作却不能用FileUpLoad来实现. 下面这个示例便是使用ASP.NET来实现上传文件夹并对文件夹进行压缩以及解压. ASP.NE ...

  6. R 配色(挑花眼的色卡19色)

    cols =c("#999999","#FF0099", "#E69F00", "#56B4E9", "#00 ...

  7. CF1012F Passports

    http://codeforces.com/problemset/problem/1012/F 题解 考虑\(p=1\)的情况. 我们可以把题意理解成平面上有一些线段,你需要给每条线段分配一个长度给定 ...

  8. 编写灵活、稳定、高质量的HTML代码的规范

    一.唯一定律 无论有多少人共同参与同一项目,一定要确保每一行代码都像是唯一个人编写的. 二.HTML 2.1 语法 (1)用两个空格来代替制表符(tab) -- 这是唯一能保证在所有环境下获得一致展现 ...

  9. fengmiantu2

  10. 20160513--js 弹出窗口带有iframe控件 备忘

    需要引用JQuery. /*! * 主 题:<页面弹出窗口> * 说 明:用于页面弹出的窗口. * 功能描述: * 1.生成弹出窗口,窗口内包括iframe控件: * 2.窗口弹出时,生成 ...