JRO Dependencies

StewartBW 745 Reputation points
2024-06-18T04:26:39.89+00:00

Hello

In vb.net WinForms .net fw 4.0 app, when I add a reference to: Microsoft Jet and Replication Objects 2.6 Library (Interop.JRO.dll) another component is also force added among with together:

Microsoft ActiveX Data Objects 2.8 Library (Interop.ADODB.dll)

I only need JRO.JetEngine.CompactDatabase and nothing else, so:

  1. If I remove the force added Interop.ADODB.dll the app will still run, still required?
  2. Which dlls to copy and distribute with the app? Interop.JRO.dll only or other are needed as well?
  3. Any idea why CopyLocal property of those are False and cannot be changed? Thanks.
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,642 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Jiachen Li-MSFT 28,001 Reputation points Microsoft Vendor
    2024-06-18T08:17:20.1566667+00:00

    Hi @StewartBW ,

    When you add a reference to the Microsoft Jet and Replication Objects 2.6 Library (Interop.JRO.dll), it implicitly requires the Microsoft ActiveX Data Objects 2.8 Library (Interop.ADODB.dll) because JRO relies on ADO for certain operations, including database compaction. Therefore, removing Interop.ADODB.dll will likely cause runtime errors when the JRO library attempts to use ADO functionality.

    Distribute both Interop.JRO.dll and Interop.ADODB.dll along with ensuring msjro.dll and msado15.dll are registered on the target machine.

    The CopyLocal property for COM interop assemblies is typically set to False because of their expected registration in the system.

    Best Regards.

    Jiachen Li


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments