Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Скачиваний:
191
Добавлен:
11.05.2015
Размер:
4.96 Mб
Скачать

Related Topics

PESetGroupCondition, Volume 2, Chapter 1

CRPEJob::SetGroupSelectionFormula

Use SetGroupSelectionFormula to set the formula text for the group selection formula. This method is often used with CRPEJob::GetGroupSelectionFormula, Page 418 to identify and then change an existing group selection formula in response to a user selection at print time.

Syntax

SetGroupSelectionFormula (formulaText CHAR(*)) RETURNING BOOLEAN

Parameter

formulaText

Specifies the new group selection formula that you want to assign to the report.

 

 

Returns

TRUE if the call is successful.

FALSE if there is an error in the formula, or if the call fails.

Related Topics

PESetGroupSelectionFormula, Volume 2, Chapter 1

CRPEJob::SetLineHeight

Use SetLineHeight to set the line height for the specified section. This method can be used for setting up a report to print on preprinted forms. It can also be used if you want to insure the size of a line in relation to the font size. For example, this method might be used to specify a 12 point line with 10 point type.

Syntax

SetLineHeight (sectionCode SMALLINT, lineN SMALLINT, height SMALLINT, ascent SMALLINT) RETURNING BOOLEAN

Parameters

sectionCode

Specifies the Section Codes (page 480), for the section of the report for which you want

 

to set line height.

 

 

Crystal Class Library for NewEra Reference

447

lineN

Specifies the 0-based number of the line for which you are setting the height. The first

 

line in a section is line number 0, the next is 1, etc. Use PEP_ALLLINES to specify all

 

lines in the section.

 

 

height

Specifies the height, in twips, of the line.

 

 

ascent

Specifies the ascent, in twips, of the line. Line ascent is the distance from the baseline of

 

the font to the top of the line space.

Returns

TRUE if the call is successful.

FALSE if there is an invalid selection, or if the call fails.

CRPEJob::SetMargins

Use SetMargins to set the page margins for the print job. Use this method any time you want to allow the user to change margins.

Syntax

SetMargins (left SMALLINT, right SMALLINT, top SMALLINT, bottom SMALLINT) RETURNING BOOLEAN

Parameters

For any of the above parameters, PM_SM_DEFAULT can be used to specify that the report use default printer margins.

left

Specifies the left margin in twips.

 

 

right

Specifies the right margin in twips.

 

 

top

Specifies the top margin in twips.

 

 

bottom

Specifies the bottom margin in twips.

Returns

TRUE if the call is successful.

FALSE if the call fails.

Related Topics

PESetMargins, Volume 2, Chapter 1

Crystal Class Library for NewEra Reference

448

CRPEJob::SetMinimumSectionHeight

Use SetMinimumSectionHeight to set the minimum height for the specified section. For example, use this method whenever you want to specify a minimum section height for printing on pre-printed forms or printing on any other kind of document with a fixed format.

Syntax

SetMinimumSectionHeight (sectionCode SMALLINT, height SMALLINT) RETURNING BOOLEAN

Parameters

sectionCode

Specifies the Section Codes (page 480), for the section of the report for which you want to

 

set minimum section height.

 

 

height

Specifies the minimum height in twips of the specified section.

 

 

Returns

TRUE if the call is successful.

FALSE if an invalid section has been specified, or if the call fails.

Related Topics

PESetMinimumSectionHeight, Volume 2, Chapter 1

CRPEJob::SetNDetailCopies

Use SetNDetailCopies to set the number of times the Details section of the report is to be printed. For example, you can use this method to print multiple copies of labels for a customer, multiple copies of a purchase order, or multiple copies of anything set up in the Details section of the report.

Syntax

SetNDetailCopies (nCopies SMALLINT) RETURNING BOOLEAN

Parameter

nCopies

Specifies the number of copies of the detail section of the report to be printed.

 

 

Crystal Class Library for NewEra Reference

449

Returns

TRUE if the call is successful.

FALSE if the call fails.

Related Topics

PESetNDetailCopies, Volume 2, Chapter 1

CRPEJob::SetNthGroupSortField

Use SetNthGroupSortField to specify that the specified group summary field is sorted in the specified direction (ascending or descending). This method does not create a new group, but will sort an existing group summary field.

Syntax

SetNthGroupSortField (sortFieldN SMALLINT, field CHAR(*), direction SMALLINT) RETURNING BOOLEAN

Parameters

sortFieldN

Specifies the 0-based number of the group sort field that you want to set. The first group

 

sort field added to the report is field 0, the second is 1, etc. If the report has N group sort

 

fields, the function can be called with this parameter between 0 and N-1 to replace an

 

existing group sort field. Call the function with this parameter equal to N to add a new

 

group sort field.

 

 

field

Specifies the name of the group field to be sorted.

 

 

direction

Specifies one of the Sort Order Constants (page 480).

Returns

TRUE if the call is successful.

FALSE if the call fails.

Related Topics

PESetNthGroupSortField, Volume 2, Chapter 1

Crystal Class Library for NewEra Reference

450

Соседние файлы в папке crystal