以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  连接数据库出错,请看下如何解决啊!  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=110435)

--  作者:wcs
--  发布时间:2017/12/2 22:11:00
--  连接数据库出错,请看下如何解决啊!
开发版打包发布的程序,在WIN10,64位电脑中,启动时出错,不能连接accdb数据库。正常的是选定这个accdb文件以后,就打开OK了的。

以开发者身份按CTRL登录,提示窗口(这是我写的连接字符串,在别的电脑中能正常运行):

Provider=Microsoft.ACE.OLEDB.12.0;Data Source=F:\\极简阅账\\示例.accdb;Persist Security Info=False

点击“生成器”,直接报错,提示:

有关调用实时(JIT)调试而不是此对话框的详细信息,
请参见此消息的结尾。

************** 异常文本 **************
System.InvalidOperationException: 在创建窗口句柄之前,不能在控件上调用 Invoke 或 BeginInvoke。
   在 System.Windows.Forms.Control.MarshaledInvoke(Control caller, Delegate method, Object[] args, Boolean synchronous)
   在 System.Windows.Forms.Control.Invoke(Delegate method, Object[] args)
   在 Foxtable.O  o OoO.O0o0_0o_(Exception A_0, String A_1)
   在 Foxtable.O O0   o.oo O   0(Object A_0, EventArgs A_1)
   在 System.Windows.Forms.Control.OnClick(EventArgs e)
   在 System.Windows.Forms.Button.OnClick(EventArgs e)
   在 System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
   在 System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   在 System.Windows.Forms.Control.WndProc(Message& m)
   在 System.Windows.Forms.ButtonBase.WndProc(Message& m)
   在 System.Windows.Forms.Button.WndProc(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   在 ...............................

很长!







--  作者:有点甜
--  发布时间:2017/12/3 14:11:00
--  
你这个电脑,有没有安装MS Office?什么版本的?32位还是 64位的?
--  作者:wcs
--  发布时间:2017/12/3 18:00:00
--  
有安装OFFICE2010,64位或32位的,有影响吗?
操作系统是64位的。

--  作者:wcs
--  发布时间:2017/12/3 23:14:00
--  
再顶一下
--  作者:有点甜
--  发布时间:2017/12/3 23:36:00
--  
以下是引用wcs在2017/12/3 18:00:00的发言:
有安装OFFICE2010,64位或32位的,有影响吗?
操作系统是64位的。

 

office尽量安装32位的版本,64位操作系统可以安装32位office的。