I am a college student taking an INTRODUCTORY Windows 10 Operating System SCRIPTING course and need some help with this script I created.
I need to have the script confirm that the file exists before the batch file hides the file.
If the file doesn't exist, the attrib command should not be executed.
How do I do this? The batch file accepts unlimited file names and I think I could use IF EXIST but not sure how to write the code.
Thanks.
Yaa, you guessed it right
the syntax is: if exist <filename or path> <action>
to hide just do if exist <filename/path> attrib +h <filename/path>
+h is used for hiding
Hope you like the answer
Please comment for any doubts
I am a college student taking an INTRODUCTORY Windows 10 Operating System SCRIPTING course and need...