| | |
Change code in vbaProject.bin programmatically with C#
Please support our C# advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jan 2009
Posts: 7
Reputation:
Solved Threads: 0
Hi,
I'm trying to insert vba code in a word .docm file through vbaProject.bin. I'm planning to use C# for this task. The part to change it to zip or use the System.IO.Packaging to open up the file doesn't seam to be a problem.
Through this tutorial:
http://www.codeproject.com/KB/cs/off...select=2005497
I understand that the vbaProject.bin is a OLE document container tree and that the vba code is inside a stream.
If I convert the byte array stream to a string I get a lot of junk and not a clear vba code string.
I hope this can be solved without installing any office product because I'm forced to run solution as lightweight as possible.
I would appreciate your advice on this.
I'm trying to insert vba code in a word .docm file through vbaProject.bin. I'm planning to use C# for this task. The part to change it to zip or use the System.IO.Packaging to open up the file doesn't seam to be a problem.
Through this tutorial:
http://www.codeproject.com/KB/cs/off...select=2005497
I understand that the vbaProject.bin is a OLE document container tree and that the vba code is inside a stream.
If I convert the byte array stream to a string I get a lot of junk and not a clear vba code string.
I hope this can be solved without installing any office product because I'm forced to run solution as lightweight as possible.
I would appreciate your advice on this.
![]() |
Similar Threads
- Emailing piping error... (PHP)
- printing - auto change code number (Windows Software)
- help me on how to change this code (PHP)
- Do you listen to music while you code/design/work? (Geeks' Lounge)
- noobie asking for assistance with file parsing... (Perl)
- Guestbook help. Post in two different spots. (Perl)
- Two Build Errors involving my code. (C++)
- HELP -my Date code isnt working (ASP)
- Urgent! Change using class (C++)
Other Threads in the C# Forum
- Previous Thread: Compare the context from two table of Database
- Next Thread: Retaining the changes made to the backcolor property
| Thread Tools | Search this Thread |
.net 2007 access ado.net algorithm array barchart bitmap box broadcast buttons c# camera check checkbox client color combobox control conversion cs4 csharp custom database datagrid datagridview dataset date datetime degrees development draganddrop drawing encryption enum event eventcloseformc# excel file form format forms function gdi+ httpwebrequest image index input install java label list listbox listener listview load mandelbrot math mouseclick mysql operator path photoshop picturebox pixelinversion post programming radians regex remote remoting richtextbox search security serialization server sleep socket sql statistics stream string table text textbox thread time timer update usercontrol validation view visual visualstudio webbrowser windows winforms wordautomation wpf xml





