Loading ...
Sorry, an error occurred while loading the content.

3536Help with dll call

Expand Messages
  • neilrichardcorcoran
    Mar 1 1:56 AM
      I'm trying to put together a program that uses the registry. I've
      tried to convert the VB syntax into LB but I keep getting a 'Dynamic
      Link Library Call Error'. Any suggestions on what I did wrong.

      The original Visual Basic syntax:

      Declare Function RegOpenKeyEx Lib "advapi32.dll"
      Alias "RegOpenKeyExA" (ByVal hKey As Long, ByVal lpSubKey As String,
      ByVal ulOptions As Long, ByVal samDesired As Long, phkResult As Long)
      As Long

      My Liberty Basic translation:

      Open "Advapi32" for dll as #Advapi32

      CallDll #Advapi32, "RegOpenKeyEx",_
      hKey as Long,_
      lpSubKey$ as ptr,_
      uloptions as long,_
      samDesired as long,_
      phkResult As long,_
      result as long

      For more documentation:
    • Show all 6 messages in this topic