Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I made a perl application that run on Dos prompt. My problem is whenever I transfer my file into desktop(Document and Setting folder) it wouldn't work. But if I transfer back in C:/ or anywhere else it work fine. On dos prompt it said can't find c:/Document. So I'm preaty sure the problem is the space between*(Document*and...). So how do I fix this, TQ.

Replies are listed 'Best First'.
Re: Problem with window
by VSarkiss (Monsignor) on Aug 09, 2004 at 19:43 UTC

    Nothing to do with Perl, and everything to do with the DOS shell.

    Put quotes around the name you'r passing:perl foobar.pl "C:/Documents and Settings/Random User/My Documents/zap.txt"

      I think the perl script that run on dos could not find my cgi-bin file. As this is a perl web server, and the cgi-script is display on a browser. This is what the server said on dos prompt;-
      /cgi-bin/myp2p.cgi dispatched to cgi_bin as cgi_bin ServerState=HASH( +0x1b39dc4) at PSP/Httpd.pm line 20, <STDIN> line 179. 'C:\Documents' is not recognized as an internal or external command, operable program or batch file.

        You didn't mention anything about CGI or a web server in your original question. As a matter of fact, you said very little, so I put forward my best guess.

        At this point, it's still not clear to me what you're doing. I'm not familiar with any Perl web servers, so there's little I can do to help you there. But I would suggest that you take a look at some of the Tutorials here, in particular, Before You Post ..., How (Not) To Ask A Question, and dominus's excellent writeup Why questions go unanswered.

        Good luck, and sorry I couldn't help more.