# Perforce Delete Files: cannot use variable with list of files

**URL:** https://www.finalbuilder.com/forums/t/perforce-delete-files-cannot-use-variable-with-list-of-files/3386
**Category:** Bugs
**Created:** [August 15, 2011, 4:10am UTC](https://www.finalbuilder.com/forums/t/perforce-delete-files-cannot-use-variable-with-list-of-files/3386 "2011-08-15T04:10:30Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![finalbuilder](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/f/d07c76/32.png) [@finalbuilder](https://www.finalbuilder.com/forums/u/finalbuilder)
#### Post date: [August 15, 2011, 4:10am UTC](https://www.finalbuilder.com/forums/t/perforce-delete-files-cannot-use-variable-with-list-of-files/3386/1 "2011-08-15T04:10:30Z")

</div>

Hi Support Team,

I use the Perfoce Delete Files action one time with a list of files and another time with a variable containing a list of files.

The execution of these actions is different:&nbsp;the first succeeds, the second not.

In detail: On the "Depot and Files" page I&nbsp;add the following lines to "Depot Files" Listbox;

//test/Test/a.txt  
//test/Test/b.txt

On execution the log contains the following line:

Parameters:&nbsp;delete -c 1 //test/Test/a.txt //test/Test/b.txt  
&nbsp;

This is successful. The following approach fails:

Set Variable %FileNames to

Append To Variable %FileNames% //test/Test/a.txt

Append To Variable %FileNames%&nbsp;//test/Test/b.txt

Perforce Delete Files with %FileNames% in the "Depot Files"&nbsp;Listbox on page "Depot and Files"

On execution the log contains the following lines:

Parameters:&nbsp;delete -c 1 //test/Test/a.txt  
//test/Test/b.txt

This actions fails to execute ("file(s)&nbsp;not on client").

&nbsp;

Obviously when 'translating' a&nbsp;('hard coded') list of Depot Files to Perforce Command Line each line is concatenated separated by a space. This should also be done when using a variable containing a list of Depot Files, shouldn't it? But currently it isn't and therefore the commandline is splitted - or in other words:&nbsp;it contains a line break and this will fail.

If you agree with me, would you mind to fix this for the other actions, too?

Best regards

Michael

---

<div class="post-metadata">

### Author: ![stephen.ryan](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/f14d63/32.png) [@stephen.ryan](https://www.finalbuilder.com/forums/u/stephen.ryan)
#### Post date: [August 16, 2011, 5:54am UTC](https://www.finalbuilder.com/forums/t/perforce-delete-files-cannot-use-variable-with-list-of-files/3386/2 "2011-08-16T05:54:31Z")

</div>

Hi Michael   
  
 This issue has been fixed in the following build:   
 [https://www.finalbuilder.com/downloads/finalbuilder/aex6/FB700\_1480.exe](https://www.finalbuilder.com/downloads/finalbuilder/aex6/FB700_1480.exe)   
  
 The Perforce actions will now correctly handle a CRLF delimited list of files within a variable.   
  
 Regards,   
 Steve

---

<div class="post-metadata">

### Author: ![finalbuilder](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/f/d07c76/32.png) [@finalbuilder](https://www.finalbuilder.com/forums/u/finalbuilder)
#### Post date: [August 16, 2011, 12:59pm UTC](https://www.finalbuilder.com/forums/t/perforce-delete-files-cannot-use-variable-with-list-of-files/3386/3 "2011-08-16T12:59:26Z")

</div>

Hi Steve,

I've tested the new build and it works fine.

Thank you for the fast support.

Best regards

Michael
