<< < … 6 7 8 9 10 11 12 13 > >>   ∑:312  Sort:Date

What Is "for" Loop Parameter
What Is "for" Loop Parameter? A "for" loop parameter is a parameter defined in a "for" command to represent each item from a give list. A "for" loop parameter must be defined using the "%%name" format, where "name" can be any identifier string. Same parameter modifiers as batch parameters are also s...
2022-02-04, ∼3418🔥, 0💬

Cmdlet Pipeline Patterns in Windows PowerShell
Are there any usage patterns for cmdlet pipelines in Windows PowerShell? Yes, there are some usage patterns for cmdlet pipelines in Windows PowerShell. 1. Use cmdlets of the same noun in a single pipeline - This is to ensure that we are working on the same object type in the entire pipeline. For exa...
2016-11-04, ∼3413🔥, 0💬

Run Second Command If the First Successful
How to run two commands with a condition that the second one will run only if the first one is successful? You can run two commands with a condition that the second one will run only if the first one is successful with the syntax below: command-1 &amp;&amp; command-2 For example, if you want...
2022-12-03, ∼3412🔥, 0💬

Work with Strings in Windows PowerShell
Where to find tutorials on how to work with strings in Windows PowerShell? Here is a collection of tutorials compiled by FYIcenter.com team on working strings in Windows PowerShell. What Is String in Windows PowerShell String Concatenation in Windows PowerShell Variable Expansion in Strings in Windo...
2016-10-20, ∼3412🔥, 0💬

"for" - Loop on List of Files
What is the "for" batch command for? The "for" command is for running a given command for each item in a list of files, path names, or any values. Below is the "for" command syntax: for %%parameter in (list) do command When the "for" command is executed, the given command will be executed once for e...
2022-04-13, ∼3408🔥, 0💬

File Name and File Path
Where to find introduction information on File Name and File Path? Here is a collection of tutorials compiled by FYIcenter.com team to provide introduction information on File Name and File Path. What Is File Name File Name with or without Drive Letter File Name with Relative Path or Absolute Path F...
2022-08-26, ∼3403🔥, 0💬

Wildcard Character In File Names
What are wildcard characters in file names? wildcard characters in file names are special characters that Windows will them as match patterns to search for files. If any matches found, the given file name will be replaced with matched file names. Many Windows commands support two wildcard characters...
2021-04-15, ∼3399🔥, 0💬

Run Script with Arguments in Windows PowerShell
How to write a script that take argument from the command line in Windows PowerShell? You can use the automatic variable $Args to take arguments from the command line where the script is launched. The $Args variable contains an array of all argument provided at the command line where this script was...
2016-10-27, ∼3398🔥, 0💬

Copy Directory or File in Windows PowerShell
How to copy a directory or file to a new location in Windows PowerShell? Can I use the old "copy" command? Yes, you can still use the old "copy" command in Windows PowerShell. But "copy" is defined as an alias of the "Copy-Item" cmdlet. The Copy-Item cmdlet copies an item from one location to anothe...
2016-10-24, ∼3386🔥, 0💬

"dir" Command Help Reference
How to get "dir" command help reference? You can run the "dir /?" command to get "dir" command help reference as shown below: C:\fyicenter&gt;dir /? Displays a list of files and subdirectories in a directory. DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N] [/O[[:]sortor...
2022-02-04, ∼3385🔥, 0💬

Special File Names Used by Windows
What are special file names used by Windows? Windows used a number of special file names referring to special resources in the system: CON - Referring to the console: keyboard and screen. Reading from CON is reading from the keyboard. Writing to CON is writing to the screen. PRN - Referring to the p...
2021-04-15, ∼3385🔥, 0💬

What Is Windows PowerShell Background Job
What are Windows PowerShell background jobs? A Windows PowerShell background job is an execution of a Windows PowerShell command detached from the console running in the background. Windows PowerShell offers the following cmdlets to help you managing background jobs: Start-Job - Starts a background ...
2016-10-13, ∼3380🔥, 0💬

Redirect STDOUT Stream to the End of File
How to redirect STDOUT stream from the screen to the end of a file? I want to append output from STDOUT stream to an existing file. When using the "&gt;" redirection to an existing file, old content of the file will be replaced. You can keep the old content of the file by using the append redire...
2022-12-03, ∼3379🔥, 0💬

Hashtable in Windows PowerShell Scripts
What is a hashtables of objects in Windows PowerShell scripts? A hashtables in Windows PowerShell is a data structure where pieces of data are stored in the structure as key-value members. The value of a member represents the data, and the key of a member provides a name for the data. Hashtable keys...
2016-10-29, ∼3373🔥, 0💬

Remote Computing Overview in Windows PowerShell
How to manage remote computers in Windows PowerShell? Windows PowerShell allows you to manage remote computers by using various technologies, including WMI, RPC, and WS-Management. You can run commands on one or hundreds of computers with a single Windows PowerShell command. Windows PowerShell offer...
2016-10-17, ∼3370🔥, 0💬

"if" Command Help Reference
How to get "if" command help reference? You can run the "if /?" command to get "if" command help reference as shown below: C:\fyicenter&gt;if /? Performs conditional processing in batch programs. IF [NOT] ERRORLEVEL number command IF [NOT] string1==string2 command IF [NOT] EXIST filename command...
2021-08-01, ∼3368🔥, 0💬

What Are Batch Variables
What What Are Batch Variables? Batch variables are variables that create, store value to and retrieve value from in a batch file. There are 3 ways a batch variable is defined: 1. Defined in the batch file using the "set" command. For example, "set java_home=\fyicenter\java" will define a new variabl...
2022-02-04, ∼3352🔥, 0💬

Introduction of Windows PowerShell ISE
Where to find tutorials on using Windows PowerShell ISE to write and test scripts? Here is a collection of tutorials compiled by FYIcenter.com team on using Windows PowerShell ISE to write and test scripts. What Is Windows PowerShell ISE Start Windows PowerShell ISE Create a PowerShell Tab in Window...
2016-10-05, ∼3352🔥, 0💬

Redirect STDOUT Stream for Command to File
How to redirect STDOUT stream from the screen to a file? I want the command to send output data to a file. By default, the STDOUT stream for a command is mapped the screen. If the command is writing data to the STDIN stream, you will see it on the screen. But, you can use the "&gt;" redirect ope...
2022-12-03, ∼3346🔥, 0💬

String Replacement in Windows PowerShell
How to replace a part of a string in Windows PowerShell? You can use the "-Replace" operation to replace a part of a string in Windows PowerShell. Here is the syntax of the "-Replace" operation: $subject -Replace $pattern,$replacement Regular expression is supported in $pattern. Here are some good e...
2016-10-19, ∼3341🔥, 0💬

Application Command in Pipeline in Windows PowerShell
Can I use application commands in cmdlet pipeline in Windows PowerShell? Yes, you can use application commands in cmdlet pipeline in Windows PowerShell. But you need to remember a couple of things: 1. The output of an application command will be considered as a String object, not a sequence of chara...
2016-11-04, ∼3339🔥, 0💬

"goto" - Change the Execution Flow
What is the "goto" batch command for? The "goto" command is for changing the execution flow in a batch file. Below is the "if" command syntax: goto label When the "goto" command is executed, the execution will jump to the line where "label" is defined and continue to execution the line after the "la...
2022-08-26, ∼3332🔥, 0💬

Rename Directory or File in Windows PowerShell
How to rename a directory or file in Windows PowerShell? Can I use the old "ren" command? Yes, you can still use the old "ren" command in Windows PowerShell. But "ren" is defined as an alias of the "Rename-Item" cmdlet. The "Rename-Item" cmdlet changes the name of a specified item, for example a dir...
2016-10-24, ∼3327🔥, 0💬

Invoke Object Methods in Windows PowerShell Scripts
How to invoke methods of an object in Windows PowerShell scripts? I know the method name in Windows PowerShell scripts. If you know the method name of an object, you can invoke and run the method using the "." operator. For example, if you run the following script: $today = Get-Date $tomorrow = $tod...
2016-11-02, ∼3315🔥, 0💬

<< < … 6 7 8 9 10 11 12 13 > >>   ∑:312  Sort:Date