Sorry, I forgot to show the definition. And you are right, I did not understand it correctly. Now I've changed the definition as follows:
Code:
typedef int (__cdecl *MYPROC)(HWND,HDC,UINT);
Now there are no more errors, the code compiles. However, nothing happens when I try to print. I tried both printing and creating a pdf. Nothing happens in either case. Did I miss something in this code?