Sunday 23 June 2019

Batch: Command parameters


Command parameters change the way that the command executes.

For example, dir command displays a list of files and subdirectories in a directory.
C:\Users\Public\databases>dir
 Volume in drive C is OSDisk
 Volume Serial Number is 1034-4F6F

 Directory of C:\Users\Public\databases

08/07/2018  09:28 PM    <DIR>          .
08/07/2018  09:28 PM    <DIR>          ..
08/07/2018  09:35 PM    <DIR>          batch script tutorial
02/10/2017  09:17 AM               436 customerDb.properties
02/10/2017  09:17 AM        52,887,096 customerDb.script
08/07/2018  09:28 PM    <DIR>          testApp
               2 File(s)     52,887,532 bytes
               4 Dir(s)  24,013,168,640 bytes free


For example, ‘dir /O’ displays files in sorted order.

C:\Users\Public\databases>dir /O
 Volume in drive C is OSDisk
 Volume Serial Number is 1034-4F6F

 Directory of C:\Users\Public\databases

08/07/2018  09:28 PM    <DIR>          .
08/07/2018  09:28 PM    <DIR>          ..
08/07/2018  09:35 PM    <DIR>          batch script tutorial
08/07/2018  09:28 PM    <DIR>          testApp
02/10/2017  09:17 AM               436 customerDb.properties
02/10/2017  09:17 AM        52,887,096 customerDb.script
               2 File(s)     52,887,532 bytes
               4 Dir(s)  24,013,066,240 bytes free




Previous                                                 Next                                                 Home

1 comment: