Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default HELP - Communicating between C++ and VBA

Hi,

I have an Excel Spreadsheet that needs to be populated by
information coming from a C++ code. I know I could have
the C++ code create an output such as a .csv file and have
the VBA code subsequently read this file. However, the
trick is that the whole process needs to be very fast,
where are talking pretty much about live updating… The C++
code will continuously be computing and modifying the
results so unless using an intermediary such as a .csv
file can be made so that it is really fast I think it
would be better to have the VBA code directly talking with
the C++ code or something similar. So does anybody has a
clue how a VBA code doing such a thing could be achieved?

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 280
Default HELP - Communicating between C++ and VBA

http://support.microsoft.com/default...NoWebContent=1


"Benoit" wrote in message
...
Hi,

I have an Excel Spreadsheet that needs to be populated by
information coming from a C++ code. I know I could have
the C++ code create an output such as a .csv file and have
the VBA code subsequently read this file. However, the
trick is that the whole process needs to be very fast,
where are talking pretty much about live updating… The C++
code will continuously be computing and modifying the
results so unless using an intermediary such as a .csv
file can be made so that it is really fast I think it
would be better to have the VBA code directly talking with
the C++ code or something similar. So does anybody has a
clue how a VBA code doing such a thing could be achieved?

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 30
Default HELP - Communicating between C++ and VBA

If you're supporting Excel XP and later, use the RTD function, which allows
a COM component to return real-time data (sort of) to Excel.

If you need to support older versions, you can use DDE (not recommended) or
COM server (using Excel as an automation server) or COM client (using VBA
code within Excel to control a COM object implemented in C++).

Regards,
Aaron Queenan.

"Bob Kilmer" wrote in message
...
I don't know as much C++ as I'd like to but I'd be surprised if C++

couldn't
talk directly to Excel. Don't we call the likes of Excel an ActiveX

(a.k.a.,
COM) automation server? C++ should be able to create an instance of Excel
and, using its object model, pour the data right in, I would think.

Bob Kilmer

"Benoit" wrote in message
...
Hi,

I have an Excel Spreadsheet that needs to be populated by
information coming from a C++ code. I know I could have
the C++ code create an output such as a .csv file and have
the VBA code subsequently read this file. However, the
trick is that the whole process needs to be very fast,
where are talking pretty much about live updating… The C++
code will continuously be computing and modifying the
results so unless using an intermediary such as a .csv
file can be made so that it is really fast I think it
would be better to have the VBA code directly talking with
the C++ code or something similar. So does anybody has a
clue how a VBA code doing such a thing could be achieved?

Thanks





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



All times are GMT +1. The time now is 10:06 PM.

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

About Us

"It's about Microsoft Excel"