By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,679 Members | 2,763 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,679 IT Pros & Developers. It's quick & easy.

Activator.CreateInstance as CreateObject in VB -> late bind and COM+

P: n/a
Hi, I have a small problem I solve easily in VB.NET but now I need to
implement it in C#. The problem is:

I have a COM component written in C++ and the methods are like this:

STDMETHOD(get_OpeningBalance)(double *pVal);
In VB.NET I do the following:

MyLoanCalculator = CreateObject("LoanLib.Loan.1")

And then I use MyLoanCalculator normally and since VB allows latebinding I
can access all methods and properties easily. However when I use C# I use
Activator.CreateInstance but then I haven't been able to invoke properties
or methods that receive parameters by reference.

An important detail is that the COM library needs to be registered as a
server application in COM+.

Any ideas?

Nov 16 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.