Hi,
I'm sorry to fill this forum whit my question's. But i have I problem that i can't find a solution to. I have made a printer dialog. and now the problem i how do i print text,bitmap or etc to the print. I've used the following code:
void PrintPage(void)
{
PRINTDLG pd;
// Initialize PRINTDLG
ZeroMemory(&pd, sizeof(PRINTDLG));
pd.lStructSize = sizeof(PRINTDLG);
pd.hwndOwner = hwnd;
pd.hDevMode = NULL; // Don't forget to free or store hDevMode.
pd.hDevNames = NULL; // Don't forget to free or store hDevNames.
pd.Flags = PD_USEDEVMODECOPIESANDCOLLATE | PD_RETURNDC;
pd.nCopies = 1;
pd.nFromPage = 0xFFFF;
pd.nToPage = 0xFFFF;
pd.nMinPage = 1;
pd.nMaxPage = 0xFFFF;
if (PrintDlg(&pd)==TRUE) {
// GDI calls to render output.
// Delete DC when done.
DeleteDC(pd.hDC);
}
}
It would help me alot if you could help me out.
Please Help Me
..:::GOOOD:::..
I'm sorry to fill this forum whit my question's. But i have I problem that i can't find a solution to. I have made a printer dialog. and now the problem i how do i print text,bitmap or etc to the print. I've used the following code:
void PrintPage(void)
{
PRINTDLG pd;
// Initialize PRINTDLG
ZeroMemory(&pd, sizeof(PRINTDLG));
pd.lStructSize = sizeof(PRINTDLG);
pd.hwndOwner = hwnd;
pd.hDevMode = NULL; // Don't forget to free or store hDevMode.
pd.hDevNames = NULL; // Don't forget to free or store hDevNames.
pd.Flags = PD_USEDEVMODECOPIESANDCOLLATE | PD_RETURNDC;
pd.nCopies = 1;
pd.nFromPage = 0xFFFF;
pd.nToPage = 0xFFFF;
pd.nMinPage = 1;
pd.nMaxPage = 0xFFFF;
if (PrintDlg(&pd)==TRUE) {
// GDI calls to render output.
// Delete DC when done.
DeleteDC(pd.hDC);
}
}
It would help me alot if you could help me out.
Please Help Me
..:::GOOOD:::..