PEGetFormula

Use PEGetFormula to retrieve the text of the named formula as a string handle. This function is used with PEGetHandleString. Use PESetFormula, to pass a formula back. The series can be used in a Custom-Print Link to identify and then change an existing formula in response to a user selection at print time.

C Syntax
BOOL CRPE_API PEGetFormula (
        short printJob,
        const char *formulaName,     
        HANDLE FAR *textHandle,
        short FAR *textLength );
Parameters

printJob

Specifies the print job from which you want to retrieve the formula string.

formulaName

Specifies a pointer to the null-terminated string that contains the name of the formula for which you want to retrieve the formula string.

textHandle

Specifies a pointer to the handle of the string containing the formula text.

textLength

Specifies a pointer to the length of the formula string (in bytes) including the terminating byte.

Returns
VB Syntax

VB Sample Code for modifying formulas

Declare Function PEGetFormula Lib "crpe32.dll" (ByVal printJob As 
Integer, ByVal FormulaName As String, TextHandle As Long, TextLength As 
Integer) As Integer
Delphi Syntax

Delphi code for getting/setting formulas

function PEGetFormula (
    printJob: Word;
    formulaName: PChar;
    var textHandle: HWnd;
    var textLength: Word
    ): Bool stdcall;


Seagate Software IMG Holdings, Inc.
http://www.seagatesoftware.com
Support services:
http://support.seagatesoftware.com