Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Creating a DLL of a function to call from VFP
Message
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
VB 9.0
Miscellaneous
Thread ID:
01325489
Message ID:
01325703
Views:
11
>on reading more carefully is sounds like you're suggesting the class interface attribute in addition to setting the project property , is that correct?
>

Yes. In every COM-interop situation I've been in I've just exposed the stuff I wanted to via the attributes. So, in addition to selecting the option to Register for COM interop, I've added the explicit attributes to tell it what to export in the type library.

When registering it, I haven't gone the strongly-named route either, I've just used REGASM MyAssembly.DLL /codebase - you don't have to do this on your development machine since it will happen automatically when you build, but you do have to do it when you distribute your app.

OK, I just did a quick test in VB.NET - the option to expose it as a COM component is under "Compile", almost the last option on the screen. The attributes are slightly different:
Imports System.Runtime.InteropServices

<ClassInterface(ClassInterfaceType.AutoDual)> _
<ComVisible(True)> _
Public Class MyTest
-Paul

RCS Solutions, Inc.
Blog
Twitter
Previous
Reply
Map
View

Click here to load this message in the networking platform