Jump to content
Xtreme .Net Talk

Recommended Posts

Posted
As anyone seen anything on "How to convert VB6 APIs to .NET?" or have an understanding ont "How to use VB6 APIs in a .NET application"?
Guest TheIrishCoder
Posted

Heres an example:-

 

<DLLImport("user32")> Function FindWindow(ByVal lpClassName As String, _

ByVal lpWindowName as String) as Integer

 

and as I've done above all Integers must be converted to Shorts and Long to Integer when copying from vb6. You can use the Declare statement but this seems to be the recommended way of doing it in .net. Also you only use ByRef for structures as far as I know.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...