Re: Building a string to contain a "\"

2007-11-18 Thread Ron Bergin
On Nov 16, 1:12 pm, [EMAIL PROTECTED] (AndrewMcHorney) wrote: > Hello > > I am trying to build a string that contains the following text "dir > c:\ /S" so I can get a complete directory of all the files on drive C > and put them into an array with the following line of code - > @dir_list = 'dir c:\

Re: Building a string to contain a "\"

2007-11-17 Thread Mathew
You have to escape it with another backslash. 'C:\\ /S' Keep up with my goings on at http://theillien.blogspot.com AndrewMcHorney wrote: > Hello > > I am trying to build a string that contains the following text "dir c:\ > /S" so I can get a complete directory of all the files on drive C and >

Re: Building a string to contain a "\"

2007-11-17 Thread Gunnar Hjalmarsson
AndrewMcHorney wrote: I am trying to build a string that contains the following text "dir c:\ /S" Use single quotes: my $command = 'dir c:\ /s'; so I can get a complete directory of all the files on drive C and put them into an array with the following line of code - @dir_list = 'dir c:

Building a string to contain a "\"

2007-11-17 Thread AndrewMcHorney
Hello I am trying to build a string that contains the following text "dir c:\ /S" so I can get a complete directory of all the files on drive C and put them into an array with the following line of code - @dir_list = 'dir c:\ /S`; Right now I have the following working: However, it is now w