I've come across something strange and wanted to ask if anyone has any ideas what is going on or if this is a bug.
I am creating a List using a Saved View that contains a list of codes (text) to be added to a list.
The import action is set to use code only, and the source codes are imported into both Name and Code of the target list.
The weird part comes after the list has been created and I try to use Finditem() on the list code to return the list item. For all codes, this works (as shown below) except if the code contains a space before a pipe:
If the list code = LS
Finditem(list, code) = LS
If the list code = LS|
Finditem(list,code) = LS|
If the list code = LS |
(with a space between "LS" and "|")
Finditem(list,code) = BLANK
I've no idea why for some reason Finditem() does not work on the code with a space before the "|" but this appears to be the case.
Is this a bug related to special characters or am i missing something?
I'll explain everything I did to see if you can spot any differences/ errors i may have made:
Created a line item (Line item3) of two text line items, one contained "LS" and the other BLANK
Formula: Line item1 & " | " & Line item2 = Line item3
Line item3 is used as Code and Name into a non-numbered list importing as saved view. Line item3 = LS |
created the list item from this saved view
Finditem(list, line item3) = BLANK
While writing this it appears there may be an issue with the space after the pipe. When a code is created does it ignore spaces at the end of the string? if so the finditem() will be looking for the space which has been automatically removed from the code... Could be what is happening here. Maybe you could try adding a space to the end of your pipe (" | ")?
I really appreciate you looking into this for me to such an extent!