I want to know if its possible to make an msi which creates a new macro button in Excel/Word
Im using wise 7.0 sp1 and have tried to capture it but so far no luck[:@]

Have anyone any idea of doing this?
I guess its only some regkeys i need to add
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Macros are stored in document templates. You are *strongly* advised to use a template other than NORMAL.DOT to store your personal macros (and any other customisations, come to that), since that file is so crucial to Word's well-being. Excel doesn't have a similar "global" file.

IIRC, the buttons graphics are stored in binary files which, again IIRC, live in the Windows folder. I just can't recall the extension used for those files...The problem is that the one file (i.e. one for Word, one for XL) is used for all the toolbar buttons so, if your package overwrites an existing one, the user's other tollbars will be trashed. So, the best option is to control the button-building with script. The stuff here http://www.experts-exchange.com/Software/Office_Productivity/Office_Suites/MS_Office/Q_20905530.html looks like it might provide a start.
Answered 02/27/2008 by: VBScab
Red Belt

Please log in to comment
0
Thx for the help VBSCab. I did not know that macros were stored in the documents templates.

I still have not figured it out how i can do this by buiding a script though.
I tried to autoIT making the script but this is no good idea since i have to use the mouse for making a button, can
can't use only keystrokes. So i guess this will be a problem if the users running different resolutions on their desktops.

So if anyone have done this please let me know how i shoul proceed
Answered 02/27/2008 by: Bankeralle
Second Degree Blue Belt

Please log in to comment
0
ORIGINAL: Bankeralle
I still have not figured it out how i can do this by buiding a script though.
Forget AutoIt. As you seem to be feeling your way, I think your best option is to record the button-creation process in the two products as a macro (the code produced will be slightly different) - which will produce VBA (Visual Basic for Applications) code - and adapt it to VB Script. After recording, Alt+F11 takes you into the VBA Editor. Browse to the new module which will have been created, double-click the module name in the left-hand pane of the editor and you'll see the code.

Sounds daunting? It's really not: the essence is to simply remove any data-typing from the VBA code. For example, where a line goes 'Dim objOL As Object', you would remove the ' As Object'. It's not a 100% rule and you may need to tailor the code further but it's mostly pretty straightforward.
Answered 02/28/2008 by: VBScab
Red Belt

Please log in to comment
Answer this question or Comment on this question for clarity