共用方式為


CallStackFrame Class

Definition

A call stack item returned by the Get-PSCallStack cmdlet.

public ref class CallStackFrame sealed
public sealed class CallStackFrame
type CallStackFrame = class
Public NotInheritable Class CallStackFrame
Inheritance
CallStackFrame

Constructors

CallStackFrame(InvocationInfo)

Constructor.

Properties

FunctionName

The name of the function associated with this frame.

InvocationInfo

The InvocationInfo of the command.

Position

The position information for the current position in the frame. Null if the frame is not associated with a script.

ScriptLineNumber

Line number of the current location, or 0 if the frame is not associated to a script.

ScriptName

File name of the current location, or null if the frame is not associated to a script.

Methods

GetFrameVariables()

Return a dictionary with the names and values of variables that are "local" to the frame.

GetScriptLocation()

Returns a formatted string containing the ScriptName and ScriptLineNumber.

ToString()

ToString override.

Applies to