sehr umständlich.
Aber irgendwann wirds auch klappen

Gruß Falko
Ja sogesehen hast du vollkommen Recht. Den Programmierer, den ich deswegen zu diesem Modul angeschrieben habe, ändert seine Haltung leider auch nicht. Er hätte ebenso gut in VC eine DLL kompilieren können, was er wohl nicht machen wird.ts-soft hat geschrieben:Ist eigentlich anders, gäbe es kein VB oder VC++, gäbe es das Problem nicht
Code: Alles auswählen
// Generated .IDL file (by the OLE/COM Object Viewer)
//
// typelib filename: AD_USB2XX.ocx
// Forward Declare all types defined in this typelib
dispinterface _DAD_USB2XX;
dispinterface _DAD_USB2XXEvents;
[
uuid(279E968D-F134-464E-ACE8-FC0D23958063),
version(1.0),
helpstring("AD_USB2XX ActiveX-Steuerelement-Modul"),
helpfile("AD_USB2XX.hlp"),
helpcontext(00000000)
]
library AD_USB2XXLib
{
// TLib : OLE Automation : {00020430-0000-0000-C000-000000000046}
importlib("stdole2.tlb");
[
uuid(BFD9E61F-75C4-4B33-8949-73A64F014514),
helpstring("Dispatch-Schnittstelle für AD_USB2XX Control"),
hidden
]
dispinterface _DAD_USB2XX {
properties:
methods:
[id(0x00000001)]
VARIANT_BOOL Scan(short DeviceNr);
[id(0x0000000d), propget]
double AnalogVoltage(
short DeviceNr,
short Channel);
[id(0x0000000d), propput]
void AnalogVoltage(
short DeviceNr,
short Channel,
double rhs);
[id(0x0000000e), propget]
short DigIO(short DeviceNr);
[id(0x0000000e), propput]
void DigIO(
short DeviceNr,
short rhs);
[id(0x00000002)]
double GetAnalogDiffVoltage(
short DeviceNr,
short Channel);
[id(0x00000003)]
short GetDeviceType(short DeviceNr);
[id(0x00000004)]
short GetError(short DeviceNr);
[id(0x00000005)]
short GetSerialNr(short DeviceNr);
[id(0x0000000f), propget]
long AnalogIO(
short DeviceNr,
short Channel);
[id(0x0000000f), propput]
void AnalogIO(
short DeviceNr,
short Channel,
long rhs);
[id(0x00000006)]
void EnableCalibration(BSTR Password);
[id(0x00000010), propget]
long Calibration(
short DeviceNr,
short IO,
short Level,
short Channel);
[id(0x00000010), propput]
void Calibration(
short DeviceNr,
short IO,
short Level,
short Channel,
long rhs);
[id(0x00000011), propget]
short SerialNr(short DeviceNr);
[id(0x00000011), propput]
void SerialNr(
short DeviceNr,
short rhs);
[id(0x00000007)]
double ReadAnalogVoltage(
short DeviceNr,
short Channel);
[id(0x00000008)]
void WriteAnalogVoltage(
short DeviceNr,
short Channel,
double Voltage);
[id(0x00000009)]
short ReadDigIn(short DeviceNr);
[id(0x0000000a)]
void WriteDigOut(
short DeviceNr,
short Value);
[id(0x0000000b)]
void DataIO(short DeviceNr);
[id(0x0000000c)]
void Close();
};
[
uuid(9A894BB7-0F68-429D-A30A-FCE4F6379D78),
helpstring("Ereignisschnittstelle für AD_USB2XX Control")
]
dispinterface _DAD_USB2XXEvents {
properties:
methods:
};
[
uuid(3FA65AAD-3DF5-4D30-8FA7-799205B01C91),
helpstring("AD_USB2XX Control"),
control
]
coclass AD_USB2XX {
[Default] dispinterface _DAD_USB2XX;
[Default, source] dispinterface _DAD_USB2XXEvents;
};
};
Code: Alles auswählen
OpenLibrary(#PB_Any, "stdole2.tlb")
Code: Alles auswählen
#VARIANT_TRUE = $FFFF ; Variant version of TRUE
#VARIANT_FALSE = $0000 ; Variant version of FALSE