|
Having recently installed Clarion.Net, I find myself a little overwhelmed trying to get started converting some C5.5 code over. I've gone through the tutorials, ClarionSharpExamples, etc and did a couple versions of "Hello World". But now for the real world...
I'm starting with a low level class that I share in multiple projects. This class has the following MAP:
MAP MODULE('API') MoveMemory(long lpdest,long lpsource,long lnbytes),SHORT,pascal,proc,name('RTLMoveMemory') END MODULE('win32') FindFirstFile( *CSTRING lpFileName, *WIN32_FIND_DATA),HANDLE,RAW,PASCAL,DLL(dll_mode),NAME('FindFirstFileA') !FindNextFile( HANDLE hFindFile, *WIN32_FIND_DATA),BOOL,RAW,PASCAL,DLL(dll_mode),NAME('FindNextFileA') FindClose( HANDLE hFindFile),BOOL,RAW,PASCAL,dll(dll_mode),PROC CreateFile( *CSTRING lpFileName, DWORD dwDesiredAccess, DWORD dwShareMode, LONG lpSecurityAttributes, DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes, HANDLE hTemplateFile), HANDLE,RAW,PASCAL,DLL(dll_mode),NAME('CreateFileA') ReadFile( HANDLE hFile, ULONG, DWORD nNumberOfBytesToRead, *DWORD lpNumberOfBytesRead, LONG lpOverlapped),BOOL,RAW,PASCAL,DLL(dll_mode) WriteFile( HANDLE hFile, ULONG, DWORD nNumberOfBytesToWrite, *DWORD lpNumberOfBytesWritten, LONG lpOverlapped),BOOL,RAW,PASCAL,DLL(dll_mode) CloseHandle( HANDLE hObject),BOOL,RAW,PASCAL,DLL(dll_mode),PROC GetLastError(),DWORD,PASCAL,RAW,DLL( dll_mode),DLL( dll_mode)
SetFilePointer( HANDLE hFile, LONG lDistanceToMove, PLONG lpDistanceToMoveHigh, DWORD dwMoveMethod ), DWORD, PASCAL, RAW, NAME( 'SetFilePointer' ) LockFile( HANDLE hFile, DWORD dwFileOffsetLow, DWORD dwFileOffsetHigh, DWORD nNumberOfBytesToLockLow, DWORD nNumberOfBytesToLockHigh ), BOOL, PASCAL, RAW, NAME( 'LockFile' ) UnlockFile( HANDLE hFile, DWORD dwFileOffsetLow, DWORD dwFileOffsetHigh, DWORD nNumberOfBytesToUnlockLow, DWORD nNumberOfBytesToUnlockHigh ), BOOL, PASCAL, RAW, NAME( 'UnlockFile' ) END END
The compiler right away doesn't like my module names 'api' & 'Win32', nor did it like the pascal attribute. I have no idea if it is still possible to use these win api functions or if they all have to be migrated to something else.
Can anyone shed some light on this?
Thanks,
Tom
|