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

COM Interop

P: n/a
Please forgive me, I'm sure this is an easy question for most people. I am
attempting to write a class library in C# that can also be called from
traditional application.... here is my code:

using System;

namespace CWrapTest
{
public class Class1
{
public string Reverse(string reverse)
{
string sReverse = "";

for (int i=reverse.Length - 1; i > -1; i--)
{
sReverse += reverse.Substring(i, 1);
}

return sReverse;
}
}
}

In VisualStudio.NET under the project's properties I set the value "Register
for COM Interop" to True, compiled the project, went into a copy of VB6,
included a reference CWrapTest type library. It displays that Class1 is
available, but the function Reverse isn't there.

Can someone tell me what I need to do, or what I'm doing wrong?

Thanks in Advanced,

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

This discussion thread is closed

Replies have been disabled for this discussion.