This is my first post, so please guide me if I have cjosen the wrong place.
I am printing from my C++ application written under Visual C++ 6.0, and I can print fine to Laser printers such as LaserJet II or LaserJet 4400, but if I direct the print to a DeskJet printer, the document doesn't print and the printer status box always seems to dhow 48 bytes printed out of whatever the document size is. The code I'm using to start printing is.....
==============================================
vertpos = 0;
dinfo.lpszDocName ="Membership Card";
dinfo.lpszOutput = NULL;
dinfo.lpszDatatype = NULL;
dinfo.fwType = 0;
dinfo.cbSize = sizeof(DOCINFO);
CString printer_name;
CPrintDialog pdlg(TRUE,PD_ALLPAGES|PD_RETURNDC,NULL);
if(pdlg.DoModal()==IDCANCEL)
return;
printer_name = pdlg.GetDeviceName();
hdc=pdlg.GetPrinterDC();
pdc = CDC::FromHandle(hdc);
cHeightPels = GetDeviceCaps(hdc, VERTRES);
// prepare doc
pdc->StartDoc((LPDOCINFO)&dinfo);
pdc->StartPage();
tcf.CreatePointFont(100,"Courier New",pdc);
pdc->SelectObject(&tcf);
tcf.GetLogFont(&lfnt);
iRowPos = iTopMargin;
iColPos = iLeftMargin;
// iRowPos = 200;
iTextHeight = abs(lfnt.lfHeight) + 10;
iCharWidth = abs(lfnt.lfWidth) +10;
================================
Any help very much appreciated.
Alyn

Printing to Laser vs Inkjet
dsilberhorn
I live in hope for any other likely ideas.
Cheers - Alyn
Pparl0627
Maybe the guys in http://msdn.microsoft.com/newsgroups/default.aspx dg=microsoft.public.win32.programmer.gdi&lang=en&cr=US have better ideas!
pberkhof
::ZeroMemory(&dinfo,sizeof(dinfo));
http://msdn.microsoft.com/library/default.asp url=/library/en-us/gdi/prntspol_9ilu.asp