Frage

When I open a VBA-File directly with notepad or notepad++, I only see a bunch of weird characters.

How did I open a VBA-File:

  1. Unzip a *.dotm file
  2. There you'll find a file /word/*.bin
  3. Unzip this *.bin file
  4. There you have the VBA-Project Source Code
  5. Now try to open/view it with your editor of choise

Do someone know a way to view the source code correctly? Using dll or replace characters, etc...

War es hilfreich?

Lösung

The .bin is itself a Zip file that contains OLE Structured Storage/BIFF documents that are somewhat non-trivial to interact with.

http://www.codeproject.com/Articles/15216/Office-2007-bin-file-format

If Word is available on the machine running your application you can use it's COM Automation features to export VBA Projects as plain-text files.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top