Convert cmd to batch file
August 3rd, 2013
can anyone help me to convert cmd command into a batch file?
I want to convert this cmd command into a batch file.
‘ attrib +s +h d:\newfile ‘
Thanks
You already have.
im on winxp and i want to create a batch file for that cmd command…
Im not getting you !
You just need to paste what you have in quotes (without them) into a new text file, then rename it to .bat
You could also replace the path and file name with a ‘%1’ (without quotes).
@.GhostShot. – Thanks
@-paroxysM^ – can you show me a demo – please
attrib +s +h d:\newfile
copy paste the code in notepad..
give save/save as..
give any name with .bat extension
for eg: file.bat
below the name field give all files in save as type like shown in this pic..
n click save..
ur batch file’s ready!!
mkmovies: it will allow you to pass a parameter to the batch file which is often more convenient than hardcoding paths. You can then invoke the bat file like this: “mybatfile D:\newfile”
right nw im replying through my fon…
Thank you all for the support.
I have one question i.e.
Can we limit file/folder access through batch command ?
You can then invoke the bat file like this: "mybatfile D:\newfile"
Or just drag and drop the file.
Well, that would be more simple didn’t think about that^^
mkmovies: Most likely, yes. But it’s probably a pain to do unless you switch to some decent scripting language like Python. (most things are painful unless you simply want to start some applications IMHO)
Can we limit file/folder access through batch command ?
Why? You can. But why? Just use the security tab in properties like everyone else.
@-paroxysM^ – yes, i can use the sec. tab but im a bit lazy thats why i want to create a batch command…
.GhostShot. replied: mkmovies: Most likely, yes. But it's probably a pain to do unless you switch to some decent scripting language like Python. (most things are painful unless you simply want to start some applications IMHO)
Can you explain me a bit briefly – please [i love to learn new things but life is too short]
And if python can do things like i want then please suggest me some tuts for this ….