Command Prompt not displaying the Current Directory before prompt [closed] - windows

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 7 years ago.
Improve this question
Whenever I run command prompt, it works fine but is not showing the current directory before the prompt(blinking).How can this be solved?

1.) Open up registry editor by typing "regedit" [without the quotes] in the search box, and then clicking on the link up top.
2.) Navigate to the key HKEY_CURRENT_USER \ Software \ Microsoft \ Command Processor and search for the string "Autorun" in the left window. If that string is not existing yet, create it. Double-click it afterwards and add the new directory path in the following way: CD /d C:\
3.) If you would like the command prompt to open in the system32 folder, use this string instead:
CD /d C:\windows\system32
It solved mine!

Related

In windows how to create a shortcut to make a system to shutdown or sleep? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
how to make a shortcut icon to make our pc to sleep or shutdown.
this is the desktop
Make a new txt file with content:
shutdown /s
and change the file extension to .bat. Place it on the desktop and double-click to shutdown.
You can also make a shortcut and in the "target" location, you can type in this
cmd /k shutdown -f -p
I'm not sure about the rundll one, it might be malicious to be honest
Do the below steps:
Right-click in any blank area of your desktop
Choose New > Shortcut
Copy/paste the command RUNDLL ….. 0,1,0
Click Next
For the name of the shortcut, enter “Put to Sleep Immediately”
Click Finish

How to use program name with out specific path in .cmd file [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 2 years ago.
Improve this question
When I usually type following command in command prompt,
pageant "C:\Users\test\.ssh\id_rsa.ppk"
It have worked well.
But on the other hands,when I make test.cmd file like
pageant "C:\Users\test\.ssh\id_rsa.ppk"
And then double click, it didn't work
buttest.cmd in following script
"C:\Program Files\PuTTY\pageant.exe" "C:\Users\test\.ssh\id_rsa.ppk"
work well.
What is the different between them ?
I guess The path was recognized by cmd.
If someone has opinion, please let me know
If the command doesn't contain an absolute path and isn't an internal command then cmd.exe will find the executable in the current folder and then look in the folders in the %PATH% environment variable. It looks like the current folder in your cmd is C:\Program Files\PuTTY so pageant can be found and execute normally. If you cd to a different folder then it won't work unless the folder exists in %PATH%

Windows: How to make command line prompt open at a different path? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 5 years ago.
Improve this question
I want to change the properties of Windows that when I open a command line prompt window, it will be opened at another path that the current one. Do you know how to do it?
You can create a shortcut to cmd.exe. Then do this :
Right click on Command Prompt > Properties > Shortcut. There you'll see a line which says Target: ". There just specify in which folder you want the cmd to start in.
Where you need to be, after accessing Properties
If you add /k cd "\path\to\folder" to the Target field (after cmd.exe), the resultant Command Prompt window will execute the cd command and then leave you with a prompt to do with as you please. If you need to change to a different drive, you'll need cd /d rather than just cd. If you need to change to a network drive, use pushd instead - it automatically mounts the target UNC path as a drive and changes to it.

Wildcard (*) in the path don't work while copying from cmd [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 7 years ago.
The community reviewed whether to reopen this question last year and left it closed:
Original close reason(s) were not resolved
Improve this question
There is a file (abc.txt) in a folder-
C:\vackwrk\24may\abc.txt
and i want to copy that file to another folder using cmd-
G:\work\
I use copy C:\vackwrk\24may\abc.txt G:\work\
this work , but when i am using wildcard it don't work copy C:\vackwrk\*\abc.txt G:\work\ this time output is - The filename , directory name or volume label syntax is incorrect.
Why ? Is there any alternate way to copy using wildcard ?
There is no way to use wildcard while copying from cmd because there will be ambiguity to system if there is any other directory C:\vackwrk\foo\ and C:\vackwrk\bar\,both with a file abc.txt.
But Windows PowerShell lets you to do copy using wildcard very easily , just need to open cmd and enter start powershell.exe copy C:\vackwrk\*\abc.txt G:\work\ or simply open Windows PowerShell and enter PS C:\Windows\system32> copy C:\vackwrk\*\abc.txt G:\work\ .
It works fine , so i think Windows PowerShell is more powerful than cmd.

what is the default program to interpret windows batch file [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I am working on windows 7 and I found that "notepad" was set as the default program for opening my .bat files. So when I try to execute the batch file by double clicking, it is opened by notepad.
I have tried setting cmd.exe as the default program, which didn't work.
What is the default program I should set for executing .bat files?
Click on "Start"->"Run" and type in "REGEDT32" and press Enter to start the Registry Editor.
Find the following key:
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts.BAT\UserChoice
and delete the key named "UserChoice".
Check the output of the following commands:
C:\>
C:\>assoc .bat
.bat=batfile
C:\>ftype batfile
batfile="%1" %*
C:\>
If your output is different, you have to correct the settings
(see assoc /? and ftype /? for help)
Right click a bat file and select open with - and navigate to system32\cmd.exe
If it fails to apply the setting then security software may be blocking the registry changes.

Resources