This topic contains 1 reply, has 2 voices, and was last updated by Profile photo of Don Jones Don Jones 1 year, 5 months ago.

  • Author
  • #25248
    Profile photo of Jeff martin
    Jeff martin

    I am having an issue that I hope someone here can clue me in on. When I try to run the following script it does not work:
    $Qpath = $QPath = '"'+'D:\DATA\USERS\'+$User+'"'
    $QSize = Get-FSRMQuota -Path $QPath

    The error message is:
    Get-FSRMQuota : 0x80045306, The specified path is invalid.
    At line:9 char:10
    + $QSize = Get-FSRMQuota -Path $QPath
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (MSFT_FSRMQuota:Root/Microsoft/...
    /MSFT_FSRMQuota) [Get-FsrmQuota], CimException
    + FullyQualifiedErrorId : HRESULT 0x80045306,Get-FsrmQuota

    The odd thing if I take the contents of $QPath and paste them in place of $QPath it then works.

    Any ideas of what I'm doing wrong? All I am trying to do is to get user quotas, user by user.

  • #25249
    Profile photo of Don Jones
    Don Jones

    I'm having some trouble resolving all the quotes.

    $QPath = $QPath =

    Also doesn't make sense to me. What's the goal there?

    $QPath = "D:\DATA\USERS\$User"

    Is that sufficient? PowerShell will fill-in variable names inside double quotes. I don't think you need all that concatenating.

You must be logged in to reply to this topic.