Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 57
Default Build Add-in in C++

Hi,

This is most defintely an FAQ, but I'm asking it here because there
seem to be several answers to this question.

I need to write functions in C++ and make them available in Excel
(Excel2002) as wooksheet functions. I already have an elaborate system
written in C++ (albeit in Unix) and I want to use Excel to interface
it.

What is the current recommended solution and what are the necessary
tools for it?

Many thanks in advance.

Bura
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 811
Default Build Add-in in C++

Hi Bura,

For Excel 2002 you've got two choices: XLLs or Automation Add-ins. The
main difference between the two is that Automation add-ins require COM
programming skills, while XLLs don't. Both require a pretty intimate
knowledge of Excel. For more information on XLLs, see the Excel 97 SDK (for
the purposes of XLL programming, everything's still the same):

http://msdn.microsoft.com/library/

under:

Office Solutions Development
Microsoft Office
Microsoft Office 97
Product Documentation
Excel
Microsoft Excel 97 Developer's Kit

The files that go with it can be found at (watch the wrap):

http://download.microsoft.com/downlo...excel97sdk.exe

For Automation Add-ins, a good place to start would be he

http://support.microsoft.com/default...;en-us;Q291392

--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/

* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *


"Bura Tino" wrote in message
om...
Hi,

This is most defintely an FAQ, but I'm asking it here because there
seem to be several answers to this question.

I need to write functions in C++ and make them available in Excel
(Excel2002) as wooksheet functions. I already have an elaborate system
written in C++ (albeit in Unix) and I want to use Excel to interface
it.

What is the current recommended solution and what are the necessary
tools for it?

Many thanks in advance.

Bura



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 57
Default Build Add-in in C++

Thank you for recommendations. I think I will go with the COM+ solution. But
I can't seem to get started! Is there a sample which does something trivial,
like create a function that adds two numbers, and makes that function
available for use in Excel? I know C++ well, but only in unix. I don't know
anything about COM objects, .NET, etc.

Maybe one of you gurus can supply an example like that. It would be very
useful for many people...

Many thanks in advance,

Bura

"Dag Johansen" wrote in message
...
Hi,

as you point out there are several answers to this
question.

I do belive that the easiest way to interface Excel with
code written in C++ would be to create a COM+ plug-in.
Unfortunately that can mean quite a lot of tedious (albeit
not very difficult) coding.

Were I in your shoes, I'd consider porting the existing
library to C# or writing a wrapper in C#. (Assuming you
have only used single inheritance.) If you are familiar
with .Net you might know that programming COM+ has become
a lot easier, and most of all less tedious, thanks to the
System.EnterpriseServices namespace.

Doing it this way would also give you a great deal of
flexibility in terms of future development; as a COM+
component you could run the component on a server and
install just a proxy on each client. If you were to find
that you need to handle distributed transactions, COM+
does it for you. Should you need queing or loosely coupled
events, it's there.

In the end it all depends on your scenario. You could set
up a web service and make requests from Excel using the
XmlHttp ActiveX object. But unless your data is also on
the web server that would amount to moving the data to the
processing rather than the other way round, with rather
obvious implications for performance.

Maybe you can be a little bit more verbose about your
requirements and get more useful input than this. Still, I
hope this can be of some use.

Happy coding,

Dag


(I'm looking for work in the US by the way... if anyone
should need a .Net man I'm interested!)

-----Original Message-----
Hi,

This is most defintely an FAQ, but I'm asking it here

because there
seem to be several answers to this question.

I need to write functions in C++ and make them available

in Excel
(Excel2002) as wooksheet functions. I already have an

elaborate system
written in C++ (albeit in Unix) and I want to use Excel

to interface
it.

What is the current recommended solution and what are the

necessary
tools for it?

Many thanks in advance.

Bura
.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to build a If statement dlbooks Excel Worksheet Functions 3 October 13th 09 10:08 PM
Build a Table jxbeeman Excel Discussion (Misc queries) 2 August 12th 09 11:19 PM
Build too for ordering luckytr New Users to Excel 2 December 11th 08 06:14 PM
Build Formula lynnc Excel Worksheet Functions 4 February 13th 06 11:24 PM
How would I build an "if" formula... CMS1W8 Excel Worksheet Functions 1 January 28th 05 03:21 PM


All times are GMT +1. The time now is 04:09 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"