ignore blank space

Ignore spaces at the beginning or end of strings.

  • yes

    Ignore spaces at the beginning or the end of a string

  • no

    Do not ignore spaces at the beginning or the end of a string.

Default Value: yes
  • By default, TestArchitect trims the leading and trailing spaces from text strings that it captures from the AUT before making the values available to groups of built-in actions that are used to match or compare the values, such as, check, click list item, select, etc. You now have the option to skip that processing, leaving any leading or trailing spaces in place.

  • The TestArchitect interpreter automatically strips leading and trailing whitespace from argument values. When you want to distinguish between a given string that has leading or trailing spaces and one that doesn’t, there are two approaches you can take.

    The following examples demonstrate how we can detect the string "john" – that is, “john”, with a leading space:

    • apply the #char() function with a value of 32 (ASCII space) (learn more), and set ignore blank space to no, so as to avoid trimming spaces from captured AUT property values.

                  
      settingvalue
      settingignore blank spaceno
       
      start application
       
      windowcontrolvalue
      checkloginuser name#char(32) & "john"
    • Enclose the argument value, including space, in double quotation marks. Preceding that, apply the remove double quotes from cell built-in setting with a value of true to have the interpreter strip the quotation marks. Again, ensure that ignore blank space is set to no to avoid trimming spaces from the captured property value.

                  
      settingvalue
      settingremove double quotes from celltrue
      settingignore blank spaceno
       
      start application
       
      windowcontrolvalue
      checkloginuser name"john"
  • On web browsers, a space may be in the form of either a white space (ASCII code #32), or a non-breaking space (ASCII code #160). Hence, checking for a space in a property value of a web control may involve applying char(32), char(160), or both. Note however, that the standard ASCII only built-in setting, by default, discards any characters whose decimal ASCII codes are not within the range of 32-127. Consequently, to prevent the loss of ASCII #160 characters in captured text values, set standard ASCII only to no. For example:

                
    settingvalue
    settingignore blank spaceno
    settingstandard ASCII onlyno
     
    start application
     
    windowcontrolvalue
    checkloginuser name#char(32) & "john"
    checkloginuser name#char(160) & "john"

Copyright © 2025 LogiGear Corporation. All rights reserved. LogiGear is a registered trademark, and Action Based Testing and TestArchitect are trademarks of LogiGear Corporation. All other trademarks contained herein are the property of their respective owners.

LogiGear Corporation

1730 S. Amphlett Blvd. Suite 200, San Mateo, CA 94402

Tel: +1 (650) 572-1400