Thread: Excel and C/C++
View Single Post
  #3   Report Post  
Posted to microsoft.public.office.developer.vba,microsoft.public.excel.programming,microsoft.public.excel.misc,microsoft.public.excel
cfman cfman is offline
external usenet poster
 
Posts: 36
Default Excel and C/C++


"Chip Pearson" wrote in message
...
There are a variety of techniques you could use, depending on specifically
what you want to accomplish and what version(s) of Excel you need to
support.

XLL
This will work in any version of Excel, but you are limited to writing
functions that return a value or using the XL4 Macro language features.
XLLs don't support much in object model of current versions of Excel.
However, an XLL has very fast performance, the fastest of any method.
There are a number of template frameworks available on the net that do
much of the housekeeping task for you.

COM Add-In
This will work in Excel 2000 and later and provides full object model
support.

Automation Add-In
This will work in Excel 2002 and later. You can call functions in an
Automation Add-In directly from worksheet cells.

Visual Studio Tools For Office
This will work in Excel 2003 and 2007. This gives you full access to the
Excel object model plus the entire NET framework.

--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
(email address is on the web site)


Great! Thanks a lot for your help!

Which approach is the easiest considering my lack of experiences in
Excel/VBA coding?

My goal is to specify a bunch of parameters in Excel, and hit a button in
Excel to send the parameters to the back-end C++ computational engine, and
then send results back to Excel, and then hopefully Excel will generate a
plot, let's say a 2D plot, etc.

I know how to design a button in Excel, but that's linked to a macro in VBA;
I don't know how to link that button to C++, and how to let the Excel
program wait for the results and display a plot afterwards...

Could you please elaborate?

Thanks a lot and have a great weekend!