CMD command prompt (CPT) usage and explanations  


  1. Posts : 5
    Windows 10545
       #1

    CMD command prompt (CPT) usage and explanations


    I was wondering why file not found would occur when I try to access a DIR command on a directory.

    DIR name >> file.txt

    Sincerely,

    Bash
      My Computer


  2. Posts : 384
    Window 10
       #2

    Bash said:
    I was wondering why file not found would occur when I try to access a DIR command on a directory.

    DIR name >> file.txt

    Sincerely,

    Bash
    The syntax you are using is incorrect. The command to get a list of files in a directory is simply dir. What are you trying to do? The command prompt windows thinks you're trying to issue a command which does not exist; hence the "file not found."
      My Computer


  3. Posts : 5
    Windows 10545
    Thread Starter
       #3

    DIR command syntax


    PJLLB said:
    The syntax you are using is incorrect. The command to get a list of files in a directory is simply dir. What are you trying to do? The command prompt windows thinks you're trying to issue a command which does not exist; hence the "file not found."
    I have seen uppercase commands in the documentation I have for WINDOWS 10.
    When do you use lower-case commands ?

    dir DirectoryName >> file.txt might work.

    I will try this now.

    Bash
      My Computer


  4. Posts : 5
    Windows 10545
    Thread Starter
       #4

    DIR syntax


    OK, I previously had dir command in lower case.

    I have a set command first.

    set dir1=DirectoryFilePath
    set filePath=FilePath.txt

    dir %dir1% >> %filePath% || goto Label

    This results in file not found for some directory that I know exists ???

    Thanks for the help so far !

    Bash
    Last edited by Bash; 17 Oct 2015 at 17:54.
      My Computer


  5. Posts : 5
    Windows 10545
    Thread Starter
       #5

    path error


    The system cannot find the path specified

    == is the new error I am now seeing

    set dirName=directoryFolderPath

    cd %dirName%

    gives this new error.

    Thanks for keeping up with this issue.
      My Computer


  6. Posts : 5
    Windows 10545
    Thread Starter
       #6

    I was trying to emulate IF EXISTS


    Hi Again,

    I see the folders on my desktop libraries but I cannot access them using any valid CMD command prompt use.

    I used IF EXISTS dirName and it is not found ??

    Is there some kind of access permissions I need to obtain first ??

    Bash
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 02:14.
Find Us




Windows 10 Forums