Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Using COM objects in Excel or VBA?

Hello everybody there,

I wan to use a COM (I've written in VC++) in Excel using its VBA. I
want to retreive some data with this COM and add it to a Excel
worksheet.
Is it possible? How?

Thanks in Advance,
Afshar Mohebbi

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Using COM objects in Excel or VBA?


Hello Afshar Mohebbi,

Your question is really to in depth to answer by post. Microsoft has a
good site that should answer your questions. Here is the site to visit
http://tinyurl.com/ltl2w

Sincerely,
Leith Ross


--
Leith Ross
------------------------------------------------------------------------
Leith Ross's Profile: http://www.excelforum.com/member.php...o&userid=18465
View this thread: http://www.excelforum.com/showthread...hreadid=557658

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Using COM objects in Excel or VBA?

Hi Leith,
But this link seems to be about the COM itself, not using it in Excel.
I've already written and used COM in several cases.

Regards,
Afshar

Leith Ross wrote:
Hello Afshar Mohebbi,

Your question is really to in depth to answer by post. Microsoft has a
good site that should answer your questions. Here is the site to visit
http://tinyurl.com/ltl2w

Sincerely,
Leith Ross


--
Leith Ross
------------------------------------------------------------------------
Leith Ross's Profile: http://www.excelforum.com/member.php...o&userid=18465
View this thread: http://www.excelforum.com/showthread...hreadid=557658


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Using COM objects in Excel or VBA?

Afshar,
Basically, you need to add a reference to your components from the Excel
VBEToolsReferences.
Then :
Dim MyInstance As MyCom.MyClass
Set MyInstance=New MyCom.MyClass

With MyInstance
.Dosomething argument1,etc...
End With

'Finished, so free up
Set MyInstance=Nothing

NickHK

"Afshar Mohebbi" wrote in message
oups.com...
Hi Leith,
But this link seems to be about the COM itself, not using it in Excel.
I've already written and used COM in several cases.

Regards,
Afshar

Leith Ross wrote:
Hello Afshar Mohebbi,

Your question is really to in depth to answer by post. Microsoft has a
good site that should answer your questions. Here is the site to visit
http://tinyurl.com/ltl2w

Sincerely,
Leith Ross


--
Leith Ross
------------------------------------------------------------------------
Leith Ross's Profile:

http://www.excelforum.com/member.php...o&userid=18465
View this thread:

http://www.excelforum.com/showthread...hreadid=557658



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Using COM objects in Excel or VBA?

Hi after a month!!

NickHK,
It was very helpfull, I use it in ESRI ArcGIS (ArcMap) a GIS
application and it worked well.

Thanks Again
Afshar


NickHK wrote:
Afshar,
Basically, you need to add a reference to your components from the Excel
VBEToolsReferences.
Then :
Dim MyInstance As MyCom.MyClass
Set MyInstance=New MyCom.MyClass

With MyInstance
.Dosomething argument1,etc...
End With

'Finished, so free up
Set MyInstance=Nothing

NickHK

"Afshar Mohebbi" wrote in message
oups.com...
Hi Leith,
But this link seems to be about the COM itself, not using it in Excel.
I've already written and used COM in several cases.

Regards,
Afshar

Leith Ross wrote:
Hello Afshar Mohebbi,

Your question is really to in depth to answer by post. Microsoft has a
good site that should answer your questions. Here is the site to visit
http://tinyurl.com/ltl2w

Sincerely,
Leith Ross


--
Leith Ross
------------------------------------------------------------------------
Leith Ross's Profile:

http://www.excelforum.com/member.php...o&userid=18465
View this thread:

http://www.excelforum.com/showthread...hreadid=557658




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
Excel and Busines Objects . . Rachel Costanza[_2_] Excel Discussion (Misc queries) 2 November 11th 08 07:06 AM
Objects in Excel [email protected] Excel Programming 2 June 26th 06 12:43 PM
Dynamically Assign Objects to Form Objects. The Vision Thing Excel Programming 2 December 11th 04 04:02 PM
Unable to remove Sheet objects in the Microsoft Excel Objects Adrian[_7_] Excel Programming 1 August 26th 04 10:49 PM
Objects in VBA and Excel Stephen Bianchi Excel Programming 2 September 1st 03 07:36 PM


All times are GMT +1. The time now is 09:42 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"