... Home  
... Impressum
... ColorConsole

... CMD
... Netsh-XP
... Netsh-7
... Netsh-Vista
... Powershell

Download the Windows 7 Starter, Home (Basic Premium), Professional und Ultimate!


... facebook.de
 
 
ColorConsole [Version 1.7.1000] PowerShell 2.0-Export
Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation.

C:\Windows-7>Powershell get-help about_functions_advanced -full
# TOPIC
about_Functions_Advanced

# SHORT DESCRIPTION
Introduces advanced functions that act similar to cmdlets.

# LONG DESCRIPTION
Advanced functions allow you to write functions that can perform operations
that are similar to the operations you can perform with cmdlets. Advanced
functions are helpful when you want to quickly write a function without
having to write a compiled cmdlet using a Microsoft .NET Framework
language. These functions are also helpful when you want to restrict the
functionality of a compiled cmdlet or when you want to write a function
that is similar to a compiled cmdlet.

There is a difference between authoring a compiled cmdlet and an advanced
function. Compiled cmdlets are .NET Framework classes that must be written
in a .NET Framework language such as C#. In contrast, advanced functions
are written in the Windows PowerShell script language in the same way that
other functions or script blocks are written.

Advanced functions use the CmdletBinding attribute to identify them as
functions that act similar to cmdlets. The CmdletBinding attribute is
similar to the Cmdlet attribute that is used in compiled cmdlet classes to
identify the class as a cmdlet. For more information about this attribute,
see about_Functions_CmdletBindingAttribute.

The following example shows a function that accepts a name and then prints
a greeting using the supplied name. Also notice that this function defines
a name that includes a verb (Send) and noun (Greeting) pair similar to the
verb-noun pair of a compiled cmdlet. However, functions are not required
to have a verb-noun name.

function Send-Greeting
{
[CmdletBinding()]
Param(
[Parameter(Mandatory=$true)]
[string] $Name
)
Process
{
write-host ("Hello " + $Name + "!")
}
}

The parameters of the function are declared by using the Parameter
attribute. This attribute can be used alone, or it can be combined with
the Alias attribute or with several other parameter validation attributes.
For more information about how to declare parameters (including dynamic
parameters that are added at runtime), see
about_Functions_Advanced_Parameters.

The actual work of the previous function is performed in the Process
block, which is equivalent to the ProcessingRecord method that is used by
compiled cmdlets to process the data that is passed to the cmdlet. This
block, along with the Begin and End blocks, is described in the
about_Functions_Advanced_Methods topic.

Advanced functions differ from compiled cmdlets in the following ways:

- Advanced function parameter binding does not throw an exception when
an array of strings is bound to a Boolean parameter.

- The ValidateSet attribute and the ValidatePattern attribute cannot
pass named parameters.

- Advanced functions cannot be used in transactions.

SEE ALSO
about_Functions_Advanced_CmdletBindingAttribute
about_Functions_Advanced_Methods
about_Functions_Advanced_Parameters
Windows PowerShell Cmdlets (http://go.microsoft.com/fwlink/?LinkID=135279)

C:\Windows>powershell get-help about_functions_advanced_methods -full

OS: Windows-7 / Windows-Vista // Windows Server 2008
»»»» ColorConsole


0.062
Wie funktioniert das Mounten von VHD ohne Zusatzsoftware in Windows-7?  / Wo finde ich das Tool, um zu verhindern, dass Win 7 in Standby fährt?  / Die Versionsnummer vom Betriebssystem Win-7 will ich am Desktop nicht sehen (ausblenden)!  / Warum kommt überhaupt Windows-8 auf den Markt, wenn das Windows-7 gerade erschienen ist  / Ich habe auf dem Desktop einen kleinen schwarzen Punkt, was kann ich machen?  / Habe W7 über Vista installiert, mein Outlook mit allen Kontaktdaten ist weg!  / Ist bei Win-7 ein dauerhaftes Entfernen der Programme aus der Schnellstartleiste möglich?  / Ich hab die Testversion von Windows Server 2008 hab aber keinen Product Key!  / / Lesetipp: 960  / Windows 7 Farbschema stellt sich bei bestimmten Programmen um, ist das zu beheben?  / Windows Vista oder Windows 7, das ist hier die Frage?  / Wie formatiere ich eine externe Festplatte unter Windows 7?  / Wie kann ich TDSL von T-Online bei Vista einrichten?  / Wie kann ich die Datenträgerverwaltung in Windows 7 öffnen?  / Was macht der Gatewaydienst an meinem PC?  /