08-30-2016 03:02 AM - edited 08-30-2016 03:23 AM
I added this code to the general part of the code:
Private Declare Function DSDisposeHandle Lib "lvrt.dll" (LStrHandle as Long) as Integer
And after I copy the the data in VB I added this code:
Dim dispose as Integer dispose = DSDisposeHandle(StringHandle_detector) dispose = DSDisposeHandle(StringHandle_ext)
but nothing has changed. Have I missed something here?
If I want to create a Pointer to a C string instead - how do I do this in vb6?
Best,
Julian
edit:
As pointers have to be adressed ByVal I changed the line to :
Dim dispose as Integer dispose = DSDisposeHandle(ByVal StringHandle_detector) dispose = DSDisposeHandle(ByVal StringHandle_ext)
Which did the trick 🙂
Thanks very much!!
08-30-2016 12:31 PM
@jschmidtengler wrote:
As pointers have to be adressed ByVal I changed the line to :
Dim dispose as Integer dispose = DSDisposeHandle(ByVal StringHandle_detector) dispose = DSDisposeHandle(ByVal StringHandle_ext)Which did the trick 🙂
My VB knowledge is almost non existent but wouldn't
Private Declare Function DSDisposeHandle Lib "lvrt.dll" (ByVal LStrHandle as Long) as Integer
do the same?
08-30-2016 12:34 PM
Yes.
The latter would also be the more elegant way of implementing it - directly in the definition.
Best,
Julian