🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.vbasic
Article #92413

vb6 funkcja w dll

#92413
From: k p
Date: Wed, 26 Oct 2005 06:46
21 lines
1374 bytes
Witam wszystkich.
Czy ktoś wie jak z vb wywołać funkcję z dll-a napisaną w C, 
która jako z parametrów ma pointer to pointer?
Przykład:
funkcja w dll-u jest zdefiniowana tak:
int open(char *sPlik, MojTyp **ppPlik)

Próbowałem to zrobić tak:
uchwyt = open(path, VarPtr(VarPtr(plik)))
gdzie
Dim path As String
Dim plik As Long
Private Declare Function open Lib "lib.dll" (ByVal sPlik As String, _
	ByVal ppPlik As Long) As Long
ale vb nie pozwala na to zwracając błąd "Bad dll calling convention".

Czy da się w ogóle coś takiego zrobić w vb?
Pozdrawiam.

-- 
Wysłano z serwisu Usenet w portalu Gazeta.pl -> http://www.gazeta.pl/usenet/
Technical Details
Message-ID: <djn8nd$bue$1@inews.gazeta.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mail

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mail
From: "k p" <wim_ok.SKASUJ@gazeta.pl>
Newsgroups: pl.comp.lang.vbasic
Subject: vb6 funkcja w dll
Date: Wed, 26 Oct 2005 06:46:05 +0000 (UTC)
Organization: "Portal Gazeta.pl -> http://www.gazeta.pl"
Lines: 21
Message-ID: <djn8nd$bue$1@inews.gazeta.pl>
NNTP-Posting-Host: 212.160.172.70
X-Trace: inews.gazeta.pl 1130309165 12238 172.20.26.241 (26 Oct 2005 06:46:05 GMT)
X-Complaints-To: usenet@agora.pl
NNTP-Posting-Date: Wed, 26 Oct 2005 06:46:05 +0000 (UTC)
X-User: wim_ok
X-Forwarded-For: 172.20.6.162
X-Remote-IP: 212.160.172.70
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit