Dears,
I'm building cosumized dll using unidrv model (oemdll
example).
I used SetPrinterData and GetPrinterData in the UI dll it
worked fine, GetPrinterData also worked fine in the
customizaion dll of the graphics engine.
I'm faceing a problem I tried to use SetPrinterData, or
EngSetPrinterData, both return code 5, i guess this means
access violation.
the code is:
dwResult = SetPrinterData(pdev->hPrinter,
STDSTR_FONTDATASIZE,
REG_DWORD,
(PBYTE) &FontSize,
sizeof(DWORD));
where FontSize is a DWORD and STDSTR_FONTDATASIZE is
defined as follows:
#define STDSTR_FONTDATASIZE TEXT("FontDataSize")
hPrinter is stored when the driver received the EnablePDEV
call, and it worked in GetPrinterData.
Please if any body knows what is going around please
advise.
Best regards,
-Amer Malas.