Powershell von Funktion Wert weiterverwenden
Hallo zusammen,
Wie kann ich von einer aufgerufenen Funkion die Variabeln später weiterverwenden?
Bsp:
Angezeigt wird momentan nur: gagagi!
Wie kann ich auf die Variable $Summe ausserhalb der Funktion zugreifen?
Danke und Gruss
Shan
function Test
{
param($Zahl,$Zahl2)
$Summe = $Zahl + $Zahl2
}
Test 4 5
Write-Output "gagagi" $Summe
Angezeigt wird momentan nur: gagagi!
Wie kann ich auf die Variable $Summe ausserhalb der Funktion zugreifen?
Danke und Gruss
Shan
Please also mark the comments that contributed to the solution of the article
Content-Key: 169931
Url: https://administrator.de/contentid/169931
Printed on: April 23, 2024 at 06:04 o'clock
1 Comment