scripts

Write-Info.ps1

SYNOPSIS

Writes to the information stream, with color support and more.

SYNTAX

Write-Info.ps1 [-Message] <Object> [-ForegroundColor <ConsoleColor>] [-BackgroundColor <ConsoleColor>]
 [-LogFile <String>] [-NoNewLine] [-UseInformationPreference] [-ProgressAction <ActionPreference>]
 [<CommonParameters>]

DESCRIPTION

EXAMPLES

Example 1

PS C:\> 

PARAMETERS

-Message

Message to write to the information stream.

Type: Object
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False

-ForegroundColor

Specifies the text color. There is no default.

Type: ConsoleColor
Parameter Sets: (All)
Aliases: fg

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-BackgroundColor

Specifies the background color. There is no default.

Type: ConsoleColor
Parameter Sets: (All)
Aliases: bg

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-LogFile

Specifies a log file to write the information string to.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-NoNewLine

The string representations of the input objects are concatenated to form the output. No spaces or newlines are inserted between the output strings. No newline is added after the last output string.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-UseInformationPreference

By default, uses -InformationAction Continue. This uses the standard $InformationPreference instead.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

NOTES