View Single Post
Join Date: Aug 2008
Posts: 710
Reputation: Teme64 will become famous soon enough Teme64 will become famous soon enough 
Solved Threads: 114
Teme64's Avatar
Teme64 Teme64 is offline Offline
Master Poster

Re: create dll using vb.net and how to call it from sql server

 
0
  #8
Dec 2nd, 2008
Ok. I found this MS Help and Support article: How to run a DLL-based COM object outside the SQL Server process. Read this article, it has good tips when remoting COM with SQL Server.

But first, you have to make your class a COM component by setting the class attribute "COM Class = True", or directly in the code
  1. <Microsoft.VisualBasic.ComClass()> Public Class Class1
  2.  
  3. Public Sub New()
  4. ' Initialize class
  5.  
  6. End Sub
  7.  
  8. Public Sub MyMethod()
  9.  
  10. End Sub
  11.  
  12. End Class
you'll have a COM component after compiling that, and you'll register COM component with regsvr32 <dllname>

I think this is more an SQL Server related issue than VB.NET. You could also re-post this question in "Web Development\MS SQL" forum here in DaniWeb.
Reply With Quote