Windows 10: CMD command prompt (CPT) usage and explanations


  1. Posts : 5
    Windows 10545
       16 Oct 2015 #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 ComputerSystem Spec

  2.    16 Oct 2015 #2

    Bash said: View Post
    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 ComputerSystem Spec


  3. Posts : 5
    Windows 10545
    Thread Starter
       16 Oct 2015 #3

    DIR command syntax


    PJLLB said: View Post
    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 ComputerSystem Spec


  4. Posts : 5
    Windows 10545
    Thread Starter
       16 Oct 2015 #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 ComputerSystem Spec


  5. Posts : 5
    Windows 10545
    Thread Starter
       17 Oct 2015 #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 ComputerSystem Spec


  6. Posts : 5
    Windows 10545
    Thread Starter
       18 Oct 2015 #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 ComputerSystem Spec


 

Related Threads
Anyone figured out a use for the Opacity setting for Command Prompt on the Experimental tab? I've tried it at many different settings and I just can't see a use for it.
Solved Command Prompt in General Support
How to call up "command Prompt (Admin) from the "run" dialog box win 10 Home?
Command Prompt Won't Close in General Support
Ok, so on my Dell Latitude E6520 laptop, I can open command prompt (Normal and Admin), but can not close any of the CMD windows I open unless I go through the Task Manager and shut them down. I do not have that issue on my desktop, which is also...
Command Prompt? in General Support
Guys, I'm going to try one last time. The error code I received told to me to empty files and then "Run the command prompt as an administrator"?? Then, type wuauclt.exe/update now??......I don't know what run the command prompt means. I have no...
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 00:31.
Find Us