Dll Parameter Type (POINTER) and return (BYTE)

Dll Parameter Type (POINTER) and return (BYTE)

Postby digordo » Tue Dec 18, 2012 12:23 pm

Hi Guys!

I'm execute a Dll Function and some parameters is Ref BYTE type. How can i call ?

See code in xHarbour:

Code: Select all  Expand view

Function Test()
Local hHandle := LoadLibrary("EasyInner.dll")
Local pReceberDados := DllPrepareCall( hHandle, DC_CALL_STD,"ReceberDadosOnLine")
Local nNumCol          := 1
Local nOrigem          := 0
Local nComplemento:= 0
Local cCartao          := ""
Local nDia               := 0
Local nMes              := 0
Local nAno              := 0
Local nHora            := 0
Local nMinuto        := 0
Local nSegundo      := 0
Local nRet
nRet := DllExecuteCall( pReceberDados , nNumCol , @nOrigem, @nComplemento, @cCartao, @nDia, @nMes, @nAno, @nHora, @nMinuto, @nSegundo)

Return nRet
 


The return of function is always strange numbers, with 9..8..digits...i don't no why.
And the var ref parameters is alwarys 0, but the value of cCartao is ok.

Delphi (Define):
Code: Select all  Expand view

Function ReceberDadosOnLine( Inner:Integer; Origem, Complemento: Pointer; Cartao: PChar; Dia, Mes, Ano, Hora, Minuto, Segundo:Pointer):Byte; stdcall; external 'EasyInner.dll';
 


Can anyone help?


Thks
digordo
 
Posts: 13
Joined: Mon Aug 02, 2010 5:15 pm

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 82 guests

cron