Working with Variable Conversion Process

Navigation:  How to Work with Processes > Working with the Variable Processes Group >

Working with Variable Conversion Process

Previous pageReturn to chapter overviewNext page

 

Process Purpose

 

The "Variable Conversion" process is used to convert a string into another one but with a different format or encoding (from ASCI to hexadecimal or base 64 conversions).

Check the provided "Variable Conversion" examples at the end of the topic.

 

 

When you add a process, you are required to define its settings. This occurs in the process's properties window which is displayed automatically after having added the "Variable Conversion" process.

If any subsequent edition is required, double-click the process to open its properties window and enter the necessary modifications.

 

 

Fill in the following options:

 

Source Variable

Variable

Click to select the variable with the string to be converted. See Variable Usage.

Type of conversion

Conversion

Select the type of conversion from the drop-down. Depending on the selected conversion type, the “Option” box may become available.

Option

Only available for some "Conversion" types. Select the appropriate option from the drop-down.

 

The use of the "RAW" option requires MCL-Client 4.10.P20 (or a higher version) and/or MCL-Simulator 4.9.23 (or a higher version).

 

 

In the case of "BASE64" Encoding or Decoding conversion, if you select "UTF-8 (Default)", the conversion will handle the source's data as follows:

 

If the source's data are "RAW" (ex: a file in the device with unprocessed/unknown format), the conversion operation will consider them as being type "RAW".

If the data of the source are NOT "RAW" (ex: a string, a value in a variable), MCL-Client will interpret them as being "UTF-8" data. This can be very useful, for instance, to decode Base64 data strings into images.

Store Result into Variable

Result Variable

Click to select the variable that will receive the converted result. See To Select/Create a Variable.

 

 

If required, use the icon (upper right corner of the properties window) to attach any relevant notes to this process.

Click it and enter your notes in the resulting text box. These notes will be displayed in the corresponding "Actions" tab or "Process" window (in the "Notes" field) and in the "Developer Report".

 

After filling in the required options, click to conclude or to abort the operation.

The added process is displayed in the corresponding "Actions" tab or "Process" window.

 

 

Use the right-click in MCL-Designer's input boxes to access some related options as well as the general "Cut", "Copy"; "Paste"; "Search" actions (active/inactive according to the current context).

Ex: If you right-click the "Variable" input box (included in a "Conversion's" properties window), you are provided with general editing/search actions and other more specific options such as "Variable Select" (see "Variable Select"); "Variable Insert" (see "Variable Insert"); "Insert Special Character" (see To Insert Special Characters into a Control's Text Input Field) and "Localization Select" (see Localization List).

If you right-click another input box, it may provide other possibilities.

 

 

 

Click Here for Examples of "Variable Conversion" Results