Skip to content

Commit e459c3c

Browse files
committed
Initial upload
1 parent 1f58f91 commit e459c3c

9 files changed

+492
-1
lines changed

README.md

+42-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,42 @@
1-
# vba_excel_export_code
1+
# Excel - Export code to flat files
2+
> Export every code objects (classes, forms, modules and worksheet code) to flat fliles, in a batch mode
3+
4+
## Table of Contents
5+
6+
- [Description](#description)
7+
- [Install](#install)
8+
- [Usage](#usage)
9+
- [Author](#author)
10+
- [License](#license)
11+
12+
## Description
13+
14+
This VB script will export all code objects (classes, forms, modules and worksheet macro) from an Excel file (can be .xlsm or .xlam) to flat files on your disk.
15+
16+
This way, you'll get a quick backup of your code and you'll be able to synchronize your code on a versionning platform like GitHub.
17+
18+
The script will start Excel (hidden way), open the specified file, process every code object and export them, one by one, in a `\src\your_file.xlsm` folder.
19+
20+
The `src` folder will be automatically created if needed and you'll find a subfolder having the same name of your file (so you can have more than one exported file in the same src folder).
21+
22+
## Install
23+
24+
Just get a copy of the .vbs script, perhaps the .cmd too (for your easiness) and save them in the same folder of your Excel application (containing the code you want to export).
25+
26+
## Usage
27+
28+
Just edit the .cmd file and you'll see how it works : you just need to run the .vbs with one parameter, the name of your file.
29+
30+
![demo](image/demo.png)
31+
32+
## Author
33+
34+
Christophe Avonture
35+
36+
## Contribute
37+
38+
PRs not accepted.
39+
40+
## License
41+
42+
[MIT](LICENSE)

demo.xlsm

13.9 KB
Binary file not shown.

excel_export_code.cmd

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
cscript excel_export_code.vbs demo.xlsm //nologo

0 commit comments

Comments
 (0)