However, the script block runs only while the condition is false.
Однако блок скрипта выполняется только в том случае, если условие ложно.
Parameter assigned. The script block in the preceding example uses the Param keyword to create a parameter that has a default value.
В предыдущем примере блок скрипта использует ключевое слово Рагам для создания параметра со значением по умолчанию.
Commands can have script block parameter values.
As in a While loop, the script block is repeated as long as the condition evaluates to true.
Как и в цикле While, блок скрипта повторяется до тех пор, пока условие остается истинным.
You can run a script block that is assigned to a variable by using the call operator (&), as shown in the following example: C:\PS> &$a Parameter assigned.
Запустить блок скрипта, назначенного переменной, можно с помощью оператора вызова (&), как показано в следующем примере: C:\PS> &$a Параметр задан.
Unlike the related While loop, the script block in a Do loop always runs at least once.
В отличие от цикла While, блок скрипта в цикле Do всегда выполняется по крайней мере один раз.
You can also provide a parameter to the script block, as shown in the following example: C:\PS> &$a "Other value" Other value assigned.
Для блока скрипта можно также задать параметр, как показано в следующем примере: C:\PS> &$a "Другое значение" Другое значение задано.
When strict mode is on, Windows PowerShell generates a terminating error when the content of an expression, script, or script block violates basic best-practice coding rules.
Если включен строгий режим, Windows PowerShell создает прерывающую ошибку, если содержимое выражения, скрипта или блока скрипта нарушает основные рекомендуемые правила кодирования.
The Measure-Command cmdlet runs a script block or cmdlet internally, times the execution of the operation, and returns the execution time.
Командлет Measure-Command выполняет во внутреннем контексте блок скрипта или командлет, измеряет время выполнения операции и возвращает полученное значение.
In a Do-While loop, the condition is evaluated after the script block has run.
В цикле Do-While условие проверяется после выполнения блока скрипта.
Like functions, a script block can include parameters.
This can be a complete script that contains all the elements of a modern lesson from the video till the job in the format of the DPA and international studies, or script block.
Это может быть полноценный сценарий, содержащий все элементы современного урока - от видеоролика до заданий в формате ГИА и международных исследований, или блок сценариев.