DotNetTools for VBA

DotNetTools brings all the convenience of the .NET framework to VBA in a centralized tlb file. One library contains everything you need. DotNetTools are free to use to anyone. Send us an email for suggestions here.


Getting Started:

  1. Download the binaries. You don’t need Step 2 if you are doing the windows installer package library. Please go to Step 3.
  2. Run RegAsm.exe on the CADHero.dll to register the types in your machine:
    Open your command prompt as administrator
    Type cd c:\Windows\Microsoft.NET\Framework64\v4.0.30319  (Framework if Windows 32 bits)
    Command Prompt will change to c:\Windows\Microsoft.NET\Framework64\v4.0.30319>
    Now Type RegAsm.exe /codebase <Path_To_CADHero.dll>
    You’ll be prompted by a warning message saying the assembly is not signed. What’s important is that you see the message saying that types have been registered.
  3. Reference the CADHero tlb file in your VBA macro.

Simply instantiate the class CADHero.DotNetTools
All the .NET class are organized as properties in the DotNetTools object. For example if you wants to check if a file exists, try this following:

Example 1:

Browsing to a folder has never been easy. If you do this with VBA, you’d need to call the Windows API in order to use the Windows native browse to folder dialog. This can be accomplished in this fashion.

While this may be easty for advanced developers, this may look intimidating for new developers or occassional macro users.

With DotNetTools, we can accomplish that in a few lines

Example 2:

DotNetTools has support date time operations such culture aware parse.




Download latest version (Installer):
Latest X64 (Windows Installer)


Exposed methods: