List Iterator fails in case a single percent sign is in the list

Hi support team,

Perforce uses to replace a hash sign (#) by %23

Obviously FB expects a variable starting at the percent sign and fails to iterate the following list:

File No.50.txt
File #50.txt
File %2350.txt  <--- forces the iterator to fail

 

If I double the percent sign the iterator does nothing.

A sample project is attached.

Best regards

Michael

 

001_20110811_Percent_in_Iterator.fbp7 (37.824 KB)

You can disable recursive variable expansion by using ! in front of the variable name, e.g %!list%

http://help.finalbuilder.com/variable_evaluation_and_recurs.htm

Hi Vincent,

that's quite a fast response :-) Thank you.

But, I am not quite sure how to use your answer. My problem is:

- I have a File with the name "File #1.txt"

- perforce cannot handle this because the # sign indicates the revision number, therefore in case I ask for a list of files I get "File %231.txt"

- if one single in the 'list of lines' of the 'list iterator' contains this file name, the iterator fails

Where I have to apply the exclamation mark you mentioned? I cannot change the filename to      File %!231.txt           because this file does not exist - Perforce will not find such a file.

Best regards

Michael

Hi Michael

The ! symbol addresses the issue you reported, I have modified the example project and it works correctly. You should be able double quote the filename when passing it to perforce. Otherwise I guess I'm not seeing what the problem is. Perhaps if you flesh out your example a bit more so I can see exactly what you are trying to do?

 

Percent_in_Iterator.fbp7 (37.82 KB)

Hi Vincent,

thank your for the modified sample. Now I see WHERE you applied the exclamation mark... This works fine.

Thanks a lot again.

Michael