Watch window douments - file writing services

Below are the main services for writing watch window document files. Files are open using specific functions. When complete, they must be closed by calling the paFileClose function.

- Generating spy lists:

paFileOpenWriteSpyList - Open a spy list document for writing
paFSpyAddVariable - Add a variable to a spy list

- Generating recipes:

paFileOpenWriteRecipe - Open a recipe document for writing
paFrcpAddColumn - Define a column in the recipe
paFrcpAddVariable - Add a variable to a recipe
paFrcpAddValue - Add a value to a recipe

- Generating graphic documents:

    Not available

paFileOpenWriteSpyList - Open a spy list document for writing

FID := paFileOpenSpyList (NAME)

Parameters:

NAME : STRING; Name of the spy list (no suffix!)
FID : DINT; File identifier or 0 if fail

Description:

This function opens a spy list document file for writing. This functions removes the contents of the spy list if it already exist. When written, the file must be closed by calling the paFileClose function.

other functions

paFSpyAddVariable - Add a variable to a spy list

OK := paFSpyAddVariable (FID, NAME)

Parameters:

FID : DINT; File identifier returned by the paFileOpenSpyList function
NAME : STRING; Symbol of the variable
OK : BOOL; TRUE if successful

Description:

This function adds a variable to an open spy list document.

other functions

paFileOpenWriteRecipe - Open a recipe document for writing

FID := paFileOpenRecipe (NAME)

Parameters:

NAME : STRING; Name of the recipe (no suffix!)
FID : DINT; File identifier or 0 if fail

Description:

This function opens a recipe document file for writing. This functions removes the contents of the recipe if it already exist. When written, the file must be closed by calling the paFileClose function.

other functions

paFrcpAddColumn - Add a column to a recipe

OK := paFrcpAddColumn (FID, COL, NAME)

Parameters:

FID : DINT; File identifier returned by the paFileOpenRecipe function
COL : DINT; Index of the column (0 based)
NAME : STRING; Name of the column
OK : BOOL; TRUE if successful

Description:

This function adds a column to a recipe. The index of the first column is 0. Column must be declared from the left to the right. Columns must be definied before adding values to the recipe.

other functions

paFrcpAddVariable - Add a variable to a recipe

OK := paFrcpAddVariable (FID, NAME)

Parameters:

FID : DINT; File identifier returned by the paFileOpenRecipe function
NAME : STRING; Symbol of the variable
OK : BOOL; TRUE if successful

Description:

This function adds a variable (a line) to an open recipe document. Variables must be definied before adding values to the recipe.

other functions

paFrcpAddValue - Add a value to a recipe

OK := paFrcpAddValue (FID, NAME, COL, VALUE)

Parameters:

FID : DINT; File identifier returned by the paFileOpenRecipe function
NAME : STRING; Symbol of the variable
COL : DINT; Index of the column (0 based)
NAME : STRING; Value in IEC syntax
OK : BOOL; TRUE if successful

Description:

This function adds a value (one cell) to a recipe. The corresponding variable (line) and column must be defined before calling this function.

other functions