Click here to Skip to main content
15,904,652 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Need help!!!!! Pin
Christian Graus10-Aug-05 11:17
protectorChristian Graus10-Aug-05 11:17 
GeneralRe: Need help!!!!! Pin
dptalt11-Aug-05 5:34
dptalt11-Aug-05 5:34 
Generalscreen size conversion Pin
utservoalius9-Aug-05 13:13
utservoalius9-Aug-05 13:13 
Generalorder by clause in XML Pin
Rizwan Bashir9-Aug-05 10:11
Rizwan Bashir9-Aug-05 10:11 
GeneralGot it Pin
Rizwan Bashir9-Aug-05 10:21
Rizwan Bashir9-Aug-05 10:21 
QuestionHow to modify or extract files from existing MFC application Pin
Zain suri9-Aug-05 10:00
Zain suri9-Aug-05 10:00 
AnswerRe: How to modify or extract files from existing MFC application Pin
Christian Graus9-Aug-05 13:48
protectorChristian Graus9-Aug-05 13:48 
GeneralSending and catching strings from a DLL Pin
Swim-13nrv9-Aug-05 4:30
Swim-13nrv9-Aug-05 4:30 
Hello,

I have difficulties in using a DLL I was given. So I can't modify the code of this DLL, but I know that it works, since I tested it succesfully with a C program (with the .h and .lib files that were given with it).

My problem is I have to call it in VB .NET.

Here is the function that I have to call in the DLL:

<br />
    void myfunction(<br />
    long * param_one,  <br />
    long param_two,<br />
    unsigned char * param_three,<br />
    unsigned char * param_four)


Parameters 1 and 4 are outputs and parameters 2 and 3 are inputs.

And here is how I declare and call it in my VB Code:

Private Declare Sub myfunction Lib "mydll" _<br />
(ByRef param_one As Long, _<br />
ByVal param_two As Long, _<br />
ByVal param_three As String, _<br />
ByVal param_four As String)



Call myfunction(a,b,c,d)

It seems the string input (param_three) doesn't reach the DLL, which I know from the return code (param_one). I've tested with ByRefs for the strings but it doesn't work either. Maybe is it a problem with the fact that these are unsigned char * ?

I am a brand new DLL user so I may have made mistakes... If someone has an idea, I would really appreciate it.
GeneralRe: Sending and catching strings from a DLL Pin
Dave Kreskowiak9-Aug-05 5:11
mveDave Kreskowiak9-Aug-05 5:11 
GeneralRe: Sending and catching strings from a DLL Pin
Swim-13nrv9-Aug-05 22:11
Swim-13nrv9-Aug-05 22:11 
GeneralRe: Sending and catching strings from a DLL Pin
thealca9-Aug-05 13:54
thealca9-Aug-05 13:54 
GeneralRe: Sending and catching strings from a DLL Pin
Swim-13nrv9-Aug-05 22:15
Swim-13nrv9-Aug-05 22:15 
GeneralLegal to use Microsoft icons in application Pin
bomstrong9-Aug-05 2:42
bomstrong9-Aug-05 2:42 
GeneralRe: Legal to use Microsoft icons in application Pin
Rob Graham9-Aug-05 3:09
Rob Graham9-Aug-05 3:09 
GeneralRe: Legal to use Microsoft icons in application Pin
Anonymous9-Aug-05 8:33
Anonymous9-Aug-05 8:33 
GeneralExcel file printing using Adobe PDF Pin
Anonymous9-Aug-05 1:14
Anonymous9-Aug-05 1:14 
QuestionCould .net not use icon file? Pin
rushing9-Aug-05 0:57
rushing9-Aug-05 0:57 
AnswerRe: Could .net not use icon file? Pin
Dave Kreskowiak9-Aug-05 3:34
mveDave Kreskowiak9-Aug-05 3:34 
GeneralRe: Could .net not use icon file? Pin
rushing9-Aug-05 15:44
rushing9-Aug-05 15:44 
GeneralRe: Could .net not use icon file? Pin
Dave Kreskowiak10-Aug-05 1:31
mveDave Kreskowiak10-Aug-05 1:31 
GeneralBlank MsgBox Pin
sayianjin9-Aug-05 0:41
sayianjin9-Aug-05 0:41 
GeneralRe: Blank MsgBox Pin
Anonymous9-Aug-05 1:02
Anonymous9-Aug-05 1:02 
GeneralRe: Blank MsgBox Pin
Steve Pullan9-Aug-05 2:07
Steve Pullan9-Aug-05 2:07 
GeneralRe: Blank MsgBox Pin
sayianjin9-Aug-05 4:20
sayianjin9-Aug-05 4:20 
GeneralRe: Blank MsgBox Pin
Steve Pullan9-Aug-05 15:33
Steve Pullan9-Aug-05 15:33 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.