home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Supreme Volume 6 #1
/
swsii.zip
/
swsii
/
452
/
P4W_TI.ZIP
/
TI1253.ASC
< prev
next >
Wrap
Text File
|
1993-02-05
|
11KB
|
397 lines
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 1/6
TITLE : INFORECORDS: A powerful way to print forms & reports
Intended Audience:
This Technical Information Sheet is for the more experienced
ObjectPAL programmer who wants more power in printing reports and
forms.
Prerequisites:
The user should have a good overview of printing reports and
forms with ObjectPAL using more conventional commands.
Purpose:
To enable you to have more control over printing in your
application.
Print and Open InfoRecords
For the ObjectPAL programmer, the infoRecord approach to opening
and printing forms and reports is the most powerful and flexible
of all. All of the options available to the interactive report
designer become available to your application through the
infoRecords.
One possible use for the printInfoRecord occurs when you have a
report designed as landscape, but need to print the report on
paper in a portrait orientation. The panelOptions can be
provided in the info record to indicate your desire to clip the
overflow, or to print additional pages to 'panel' the entire
report across multiple pieces of paper.
There are two general steps to follow when using the infoRecords:
1. Define the record:
var
rep report
myInfo reportPrintInfo
endvar
myInfo.name = "oldsocks.rsl" ; Use your own report
; files here
myInfo.masterTable="damaged.qbe" ; A different table
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 2/6
TITLE : INFORECORDS: A powerful way to print forms & reports
2. Issue the print() statement using the infoRecord as the
only argument
rep.print(myInfo)
That's all there is to it! Read through the descriptions of
infoRecords below to see how many options are available to you
when printing/displaying your forms and reports. Be sure to read
the noted sections of the ObjectPAL documentation as well.
Here are the three record types, and their fields:
ReportOpenInfo
Data
Field Type Description
x LongInt x-coordinate of upper-left corner of
the report when opened, in twips
y LongInt y-coordinate of upper-left corner of
the report when opened, in twips
w LongInt Width of the report, in twips
h LongInt Height of the report, in twips
name String Name of the report to open. May
include alias, or any needed path
information.
masterTable String Use this table in place of any
existing master table in the dataModel
of the report being opened. Will add a
table to a table-less report. Attempts
to link to detail tables as arranged
by existing table. A QBE file is a
valid table here.
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 3/6
TITLE : INFORECORDS: A powerful way to print forms & reports
Data
Field Type Description
queryString String Query to run (like executeQBEString),
who's Answer table will become master
to report. Overrides any entry in
masterTable.
refreshOptions SmallInt One of 4 reportRestartOption
constants: PrintFromCopy; PrintLock;
PrintRestart; PrintReturn
FormOpenInfo (works with openAsDialog also)
x LongInt x-coordinate of upper-left corner of
the form when opened, in twips
y LongInt y-coordinate of upper-left corner of
the form when opened, in twips
w LongInt Width of the form, in twips
h LongInt Height of the form, in twips
name String The name of the form to open. May
include alias, or any needed path
information.
masterTable String Uses this table in place of any
existing master table in the dataModel
of the form being opened. Will add a
table to a table-less form. Attempts
to link to detail tables as arranged
by existing table. A QBE file is a
valid table here.
queryString String A query to run, like executeQBEString,
who's Answer table will become the
master to the form. Overrides any
entry in masterTable.
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 4/6
TITLE : INFORECORDS: A powerful way to print forms & reports
style LongInt Any valid combination of Windows Style
Constants (e.g. WinstyleVScroll,
WinStyleMinimize etc.). See page 200
in the ObjectPAL Developer's Guide for
a list of valid constants.
refreshOptions SmallInt One of 4 reportRestartOption
constants: PrintFromCopy; PrintLock;
PrintRestart; PrintReturn. This
affects any queries involved in the
form open (master table is QBE, query
in queryString).
ReportPrintInfo
name String Name of the report to print. May
include alias, or any needed path
information.
masterTable String Use this table in place of any
existing master table in the dataModel
of the report being printed. Will add
a table to a table-less report.
Attempts to link to detail tables as
arranged by existing table. A QBE file
is a valid table here.
queryString String Query to run (like executeQBEString),
who's answer table will become master
to report. Overrides any entry in
masterTable.
refreshOptions SmallInt One of 4 reportRestartOption
constants: PrintFromCopy; PrintLock;
PrintRestart; PrintReturn
printBackwards Logical Default = FALSE. Use this when your
printer won't collate for you
makeCopies Logical Will Paradox or the Printer make the
copies if nCopies <> 1. TRUE = Paradox
generates copies
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 5/6
TITLE : INFORECORDS: A powerful way to print forms & reports
panelOptions SmallInt One of 4 ReportPrintPanel constants:
PrintHorizontalPanel;
PrintClipToWidth; PrintOverflowPages;
PrintVerticalPanel. Here you decide
how Paradox should deal with a report
larger than the physical page.
nCopies SmallInt Number of copies to print. See
"makeCopies"
startPage LongInt Default = 1. What page to begin
printing on.
endPage LongInt Default = lastpage. Where to stop
printing
pageIncrement SmallInt Default = 1. Page increment for
multi-pass printing. THIS MAY AFFECT
CALC FIELD RESULTS.
xOffset LongInt Slide printed image this many twips to
the right on the page
yOffset LongInt Slide printed image this many twips
down on the page
orient SmallInt One of three ReportOrientation
constants: PrintLandscape;
PrintPortrait;
PrintDefaultOrientation. The latter
prints in the current orientation of
the printer.
Notes:
Simple examples are found on the following pages:
Forms - ObjectPAL Reference, page 212;
Reports - ObjectPAL Reference, page 365;
ObjectPAL Developer's Guide, page 202.
PRODUCT : Paradox for Windows NUMBER : 1253
VERSION : 1.0
OS : WIN
DATE : February 5, 1993 PAGE : 6/6
TITLE : INFORECORDS: A powerful way to print forms & reports
The parameters below are only ignored or defaulted if they are
unassigned -- that is, once you assign a value to a part of the
record, it will keep that value for the life of the object
containing the record. Additionally, you may unassign the field
using a statement like:
myInfo.masterTable.unAssign()
DISCLAIMER: You have the right to use this technical information
subject to the terms of the No-Nonsense License Statement that
you received with the Borland product to which this information
pertains.