先下载并安装.net的 Visual Studio .NET Framework Bootstrapper Plug-in然后看下面的文字。我翻译的在家里的机器上。
To install MDAC with a Setup project
Make sure that the Visual Studio .NET Framework Bootstrapper Plug-in is installed.
Select the Setup project in Solution Explorer. From the View menu, point to Editor and choose Launch Conditions.
Select the Requirements on Target Machine node. From the Action menu, choose Add Registry Launch Condition.
Select the Search for RegistryEntry1 node. In the Properties window, select the RegKey property and type Software\Microsoft\DataAccess.
Select the Root property and select vsdrrHKLM.
Select the Value property and type FullInstallVer.
Select the Property property and type MDACSEARCH.
In the Launch Conditions Editor, select the Condition1 node. In the Properties window, select the Condition property and select MDACSEARCH>="2.6".
Select the Setup project in Solution Explorer. On the Project menu, choose Properties.
Set the Bootstrapper property to Windows Installer Bootstrapper.
Both the .NET Framework redistributable and MDAC will be packaged with the Setup.exe for the Setup project when it is built.