Docmd.openquery中使用哪个名称空间以及在哪里使用它? [英] Which namespace is used in Docmd.openquery and where it is used?

查看:260
本文介绍了Docmd.openquery中使用哪个名称空间以及在哪里使用它?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Docmd.openquery 中使用哪个命名空间,在哪里使用?

请回答我的问题...我不知道在哪里以及如何使用它.

Which namespace is used in Docmd.openquery and where is it used?

Please answer my question... I don''t know where and how it is used.

推荐答案

这是Access命令,在Microsoft Access VBA中使用代码.

您要从.NET自动执行Access吗?
That''s an Access command, used in Microsoft Access VBA code.

Are you automating Access from .NET?


好吧,设置对COM库的引用

Microsoft Access x.x对象库

然后像

Well, set a reference to COM library

Microsoft Access x.x Object Library

Then something like

using Access = Microsoft.Office.Interop.Access;

Access.Application app = new Access.Application();
app.DoCmd.OpenQuery("YourQueryName");




真的不知道为什么要这么做!




Don''t really know why you''d want to do this though!


这篇关于Docmd.openquery中使用哪个名称空间以及在哪里使用它?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆