Solved

C#  interop

Posted on 2004-04-20
3
361 Views
Last Modified: 2012-08-13
How to convert COM Collection to .Net Collection



I want to assign Datasource to DataGrid in .Net.

ArrayList is not Working.
0
Comment
Question by:shaival_trivedi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 5

Accepted Solution

by:
danielsonchris earned 50 total points
ID: 10879321
>How to convert COM Collection to .Net Collection
Add a reference to the COM object via the menu:  Project->"Add Reference" Dialog.  Select the COM tab and find your library to incorporate.  .Net will quickly convert an interop library set that will be your middle-man in talking with the COM library.  
Next you will need to tell .Net that you want to use the library in your code by declaring...

using Excel;  //let's say I incorporated the office 2000 COM libraries.
//now at this point you can begin making calls into the COM library.

>I want to assign Datasource to DataGrid in .Net.
>ArrayList is not Working.

make sure that you have the following library set at the top of your page..

using System.Collections;

if ArrayList is still not working... is this a Web Application or Windows Application?  When calling the ArrayList can we see a code snippit?
Best of luck,
Chris
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is about my first experience with programming Arduino.
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Introduction to Processes
Starting up a Project

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question