Hello All,
I'm learning Powershell and i'm pretty much writing my first script.
This scripts is supposed to prompt the user to select one of four menu options.
I've sort of figured out most of it, but here's the one that's giving me hell.
I've set up the menu option using a "here-string" - which seemed easier than using if, else.
When the user selects option 4, the script prompts the user to enter a number and the script should then double the number entered.I figured this is simply the "input variable" * 2, but apparently not.
I'm just not sure how to get that to work. I've tried a few ways, and basically the calculations are completely off.
So here is a snippet of the option :
The user selects option # 4 and this happens.
"4" {
Write-Host "Okay... Lets double your number `n "
$num1 = Read-Host "Enter a number you would like to double "
...