Hi,
Im trying to write a plugin DLL for a printing system. The example comes in
C++ language and I cant convert it to delphi. Is there anybody can help me
to convert it to pascal?
Thanks
#define MY_CUSTOM_DATA_SIZE 1024 * 100 // 100K.
BOOL __stdcall
BiStartDoc( BlackIceDEVMODE* pDevmode, void** ppCustomData, unsigned long
*pdwCustomDataSize) -->Actually BlackIceDEVMODE is LongInt
{
void *pMyData; // Pointer to my data buffer
DWORD dwMyDataSize; // The size of the data buffer in bytes
OutputDebugString(TEXT("BiPlugIn.dll: BiStartDoc called.
"));
pMyData = GlobalAlloc(GPTR, MY_CUSTOM_DATA_SIZE);
if (!pMyData)
return FALSE;
// Specify the size of the data
dwMyDataSize = MY_CUSTOM_DATA_SIZE;
// return a pointer to my data and to the data size
*ppCustomData = pMyData;
*pdwCustomDataSize = dwMyDataSize;
return TRUE;
}