Multiple fields in printing

Multiple fields in printing

Postby Ehab Samir Aziz » Sat Feb 18, 2006 8:49 am

How can I print the whole fields of DBf in preview.dll put all fields simulataneoulsy in separate pages ?
Ehab Samir Aziz
 
Posts: 334
Joined: Fri Oct 14, 2005 1:54 pm

Postby Roger Seiler » Wed Feb 22, 2006 8:05 pm

Could you re-phrase your question, please? I can't understand your question as presently stated, but would like to help if possible.
User avatar
Roger Seiler
 
Posts: 223
Joined: Thu Dec 01, 2005 3:34 pm
Location: Nyack, New York, USA

Postby E. Bartzokas » Tue Feb 28, 2006 5:42 pm

Roger Seiler wrote:Could you re-phrase your question, please? I can't understand your question as presently stated, but would like to help if possible.


I guess our friend wants to create a printout with Preview, but he does not define how he wants the fields to be printed.
I guess a small rephrasing wouldn't hurt anyone... ;-)
User avatar
E. Bartzokas
 
Posts: 114
Joined: Tue Feb 14, 2006 8:13 am
Location: Corinth, Greece

Postby Ehab Samir Aziz » Thu Mar 09, 2006 9:23 pm

I want to overcome the problem of ;
Report width is greater than page width ?
Ehab Samir Aziz
 
Posts: 334
Joined: Fri Oct 14, 2005 1:54 pm

Postby James Bott » Thu Mar 09, 2006 10:05 pm

I believe what he wants is to print as many fields (in order) as will fit within the width of a portrait page in one report, then pick up on the next field on a second report, etc.

This will require calculating the width of each field based on the field width and the width of a dummy string of characters (usually uppercase B's) of the same length as the field spec. You use uppercase B's because nothing actually in the field will be wider than that. Also the printable width of the printer will have to be considered. I don't know that anyone has done this, but I am sure it can be done.

I did something similar a long time ago, but all the fields were the same width so it was easy.

James
User avatar
James Bott
 
Posts: 4840
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA

Postby Ehab Samir Aziz » Thu Mar 09, 2006 10:34 pm

Can you help me in coding please ?
Ehab Samir Aziz
 
Posts: 334
Joined: Fri Oct 14, 2005 1:54 pm

Postby James Bott » Thu Mar 09, 2006 10:55 pm

Ehab,

Try these:

oReport:oDevice:nHorzSize() // page width

oReport:oDevice:getTextSize( cText, oFont )

James
User avatar
James Bott
 
Posts: 4840
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 43 guests