Why can´t I substitute a string variable in get-childitem expression
I try to write
$strExclude ="*?.resx,web.config"
Get-ChildItem *.* -exclude $strExclude
If I run that script the Get-ChildItem don´t seem to recognize the exclusion part.
But if I write Get-ChildItem *.* -exclude *?.resx,web.config it works nice
Get-ChildItem don´t seem to evaluate my string substitution correctly
any idea,
I try to write
$strExclude ="*?.resx,web.config"
Get-ChildItem *.* -exclude $strExclude
If I run that script the Get-ChildItem don´t seem to recognize the exclusion part.
But if I write Get-ChildItem *.* -exclude *?.resx,web.config it works nice
Get-ChildItem don´t seem to evaluate my string substitution correctly
any idea,