Home Forums Programming Powershell Dynamically creating / evaluating variables RE: Dynamically creating / evaluating variables
bruce 1565
SSCrazy
Points: 2574
More actions
April 15, 2014 at 1:56 pm
#1706238
May not be what you saw, probably not, but this should do.
$Hourly8 = 10
$Hour = 8
$Var = '$Hourly'+$Hour
$cTime = Invoke-Expression -Command "$Var"
$cTime