Declare Statement Not Supported

The Windows CE Toolkit for Visual Basic does not support direct calls to DLLs, so the Declare statement is not supported. To call DLL routines you should encapsulate them in an ActiveX wrapper object.

Example of this error:

Declare Sub YourRoutine Lib "YourLib.DLL" ( YourArg )
...
YourRoutine ArgValue

Change to:

WrapperObject = CreateObject( "YourWrapper.YourClass" )
...
WrapperObject.YourRoutine ArgValue