W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #1 小弟在 delphi的 websnap中用到ado时会提示出“尚未调用 CoInitialize”这个错误是怎么回事啊,那位大侠给小弟指点一下啊!!
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #2 小弟在 delphi的 websnap中用到ado时会提示出“尚未调用 CoInitialize”这个错误是怎么回事啊,那位大侠给小弟指点一下啊!!
X xianguo Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #3 Uses ActiveX; initialization CoInitialize(Nil); finalization CoUnInitialize;
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #4 initialization CoInitialize(Nil); finalization CoUnInitialize 这亮句话应该放在哪啊?
X xianguo Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #7 在end.之前 initialization CoInitialize(Nil); finalization CoUnInitialize end.
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #8 [Error] Unit2.pas(53): Statement expected but 'FUNCTION' found [Error] Unit2.pas(81): Identifier redeclared: 'Finalization' 会出现这个错误啊?
[Error] Unit2.pas(53): Statement expected but 'FUNCTION' found [Error] Unit2.pas(81): Identifier redeclared: 'Finalization' 会出现这个错误啊?
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #9 运行没错了 可是在用到ado时还是会出现 尚未调用 CoInitialize
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #11 initialization if WebRequestHandler <> nil then WebRequestHandler.AddWebModuleFactory(TWebAppPageModuleFactory.Create(Tloginhome, TWebPageInfo.Create([wpPublished {, wpLoginRequired}], '.html'), caCache) ); CoInitialize(Nil); finalization CoUnInitialize; end. 这里
initialization if WebRequestHandler <> nil then WebRequestHandler.AddWebModuleFactory(TWebAppPageModuleFactory.Create(Tloginhome, TWebPageInfo.Create([wpPublished {, wpLoginRequired}], '.html'), caCache) ); CoInitialize(Nil); finalization CoUnInitialize; end. 这里
X xianguo Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #12 //CoInitialize(Nil);放在前面 initialization CoInitialize(Nil); if WebRequestHandler <> nil then WebRequestHandler.AddWebModuleFactory(TWebAppPageModuleFactory.Create(Tloginhome, TWebPageInfo.Create([wpPublished {, wpLoginRequired}], '.html'), caCache) ); finalization CoUnInitialize; end.
//CoInitialize(Nil);放在前面 initialization CoInitialize(Nil); if WebRequestHandler <> nil then WebRequestHandler.AddWebModuleFactory(TWebAppPageModuleFactory.Create(Tloginhome, TWebPageInfo.Create([wpPublished {, wpLoginRequired}], '.html'), caCache) ); finalization CoUnInitialize; end.
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-08 #13 试过了 还是 不行 提示:尚未调用coi..:
Y ymkj Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-09 #14 你的ADOQuery放那里了,感觉是好象放在WEBSNAP Application里,要放在WEBSNAP Data Module中,在WEBSNAP Application里引用WEBSNAP Data Module就可以了,WEBSNAP Application不是数据容器,WEBSNAP Data Module才是数据容器
你的ADOQuery放那里了,感觉是好象放在WEBSNAP Application里,要放在WEBSNAP Data Module中,在WEBSNAP Application里引用WEBSNAP Data Module就可以了,WEBSNAP Application不是数据容器,WEBSNAP Data Module才是数据容器
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-09 #15 没有放在application里是放在data module里了 代码是这样的 webdatamodule3.adoquery1.Close; webdatamodule3.adoquery1.SQL.Clear; webdatamodule3.adoquery1.SQL.Add('select * from Tuser'); webdatamodule3.adoquery1.Active; webdatamodule3.adoquery1.Open;
没有放在application里是放在data module里了 代码是这样的 webdatamodule3.adoquery1.Close; webdatamodule3.adoquery1.SQL.Clear; webdatamodule3.adoquery1.SQL.Add('select * from Tuser'); webdatamodule3.adoquery1.Active; webdatamodule3.adoquery1.Open;
X xianguo Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-09 #16 你让下面一段代码在其它代码(包括datamodule的创建)的前面执行 initialization CoInitialize(Nil); finalization CoUnInitialize
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-09 #17 我在 application里的DataSetAdapter 的dataset属性设成WebDataModule3.ADOQuery1 就会提示“尚未调用..” 如果不用DataSetAdapter 就没问题! 要在 datamodule 创建之前 是应该放在哪啊,project里吗?
我在 application里的DataSetAdapter 的dataset属性设成WebDataModule3.ADOQuery1 就会提示“尚未调用..” 如果不用DataSetAdapter 就没问题! 要在 datamodule 创建之前 是应该放在哪啊,project里吗?
W wbf810207 Unregistered / Unconfirmed GUEST, unregistred user! 2005-05-09 #19 试过了 还是不行 还是不能把application里的DataSetAdapter 的dataset属性设成WebDataModule3.ADOQuery1