LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Edit Format (Scan) String window doesn't escape "\" character (and it actually cause further issues)

Environment:
Windows 8.1
LabVIEW 2018 SP1 f4

 

Steps to Reproduce:

  1. Create a new VI and place a Format Into String function on a BD;
  2. Right-click a function and select Edit Format String;
  3. In a Selected operation dropdown select Output exact string;
  4. In a String field type a string ending with "\";
  5. Click Add New Operation button.

Expected Result:

  1. If a string contains "\" (backslash) character, followed by invalid (or no) backslash code, backslash character should be automatically escaped to output it as a character.
    If a string contains "\" (backslash) character, followed by valid backslash code, this backslash sequence should be left as is;
  2. New operation is added to the list.

Actual Result:

  1. Output exact string operation doesn't check or escape backslash codes;
  2. New format specifier is treated as part of a string and is not added to the list.

Conversely, if you remove the second "\" character in Output exact string operation, the string will collapse with next format specifier:

image.png

 

This problem was already discussed before (although in a bit different context) with people from NI involved, however no CAR number or its resolution was provided and the problem is still here. And moreover, it causes incorrect behavior of LabVIEW functionality.

 

Reported to NI with SR #7808544.

0 Kudos
Message 1 of 1
(2,276 Views)