Skip to content
Fabian edited this page Dec 18, 2016 · 2 revisions

Guide: How to build the solution

When you're cloning this repository, Nuget package restore will automatically change some settings unfortunately, which you will have to change back manually. The following steps should be done to build the solution correctly:

Step 1

Open the solution and restore nuget packages (e.g. build solution).

Afterwards, in project "ExcelScript" under "References", Click on "ExcelDna.Integration" and in the Properties window, set "Copy Local" to "True".

Step 2

Now you should restore the correct build events for the ExcelScript project:

In the solution explorer, right click on "ExcelScript" -> Project Properties -> Build Events

Set Post-build event command line to:

xcopy "$(SolutionDir)\packages\ExcelDna.AddIn.0.33.9\tools\ExcelDna.xll" "$(TargetDir)ExcelScript-AddIn.xll*" /C /Y xcopy "$(SolutionDir)\Resources\Examples.xlsm*" "$(TargetDir)Examples.xlsm*" /C /Y xcopy "$(TargetDir)ExcelScript-AddIn.dna*" "$(TargetDir)ExcelScript-AddIn64.dna*" /C /Y xcopy "$(TargetDir)ExcelScript-AddIn.xll.config*" "$(TargetDir)ExcelScript-AddIn64.xll.config*" /C /Y

Step 3

Now, once again go into the solution explorer, right click on "ExcelScript" -> Project Properties -> Command line arguments

If you're running Excel 64bit, change this to:

"ExcelScript-AddIn64.xll" "Examples.xlsm"

If you're running Excel 32bit, change this to:

"ExcelScript-AddIn.xll" "Examples.xlsm"

Now you should be ready to build & run the solution.

Clone this wiki locally