How to modify Powershell script to use 0 as current day

I would like to modify this Powershell script so if you enter the number 0, it will accept today's date.
If Enter is pressed, it should not move ahead until only a Number is entered for the amount of days back.

Thanks in advance.

[code]$userDays = Read-Host -Prompt "How many days ago is this report for (no input = today)"
If ($userDays -ne $null) {
      Try {
            $daysAgo = [Int32]$userDays
      } Catch {
            Write-Warning "'$($userDays)' is not a number; will use 1 day!"
            $daysAgo = 1
} Else {
      $daysAgo = 1
#-------DO NOT MODIFY-------#
      #Yesterdays Date
            $date = ((Get-Date).AddDays((-1 * $daysAgo))).ToString("MMM/dd/yyyy")
###SETUP END###/code]
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Like taht, for example?
$maxDays = 365
Do {
	$userDays = Read-Host -Prompt "How many days ago is this report for (0 = today, max $($maxDays), X = exit)"
	$userDays = $userDays.Trim()
} Until (($userDays -eq 'X') -or (($userDays -match '\d+') -and ($maxDays -ge $userDays)))
If ($userDays -eq 'X') {
$daysAgo = [Int32]$userDays
#-------DO NOT MODIFY-------#
	#Yesterdays Date
		$date = ((Get-Date).AddDays((-1 * $daysAgo))).ToString("MMM'/'dd'/'yyyy")

Open in new window

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
100questionsAuthor Commented:
Perfect, thank you.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.