DownloadRecipeTypes

function DownloadRecipeTypes(ctx: TcHmi.SelectableRequired<TcHmi.Context<void>, 'success' | 'error'>, filter: string[] | null, referencedRecipeTypes = false): void

The DownloadRecipeTypes function downloads the specified recipe types as a file. This function must be triggered by a direct user interaction, e.g. clicking on a button, in order to be successful.

Parameters

Name

Type

Description

ctx

TcHmi.SelectableRequired<TcHmi.Context>

Context object

Does not need to be specified by the user when used in a trigger or function expression. In this case the transfer and the evaluation is done by the corresponding parser.

Is used by the caller to indicate success or failure to the framework during execution.

If the function is used directly in JavaScript/TypeScript, the context object must be passed in the call and evaluated if necessary.

filter

string[] | null

Specifies which recipes are to be downloaded.

The value null can be used to download all recipes, or an array can be used which contains the paths of the recipes to be downloaded.

 

Example:

['Recipe1', 'Folder::SubFolder::Recipe2']

referencedRecipeTypes

boolean

Can be set to download all recipe types referenced in the recipes to be downloaded.

Return value

Type

Description

void

No return value.

NuGet package: Beckhoff.TwinCAT.HMI.Functions

DownloadRecipeTypes 1:

Available since version 1.12.758