![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | implementing get-item hi... is possible to implement a provider that support operations like this? get-item mydrive:books['name']\author I am trying to implement it overriding methods like GetItem, GetItemDynamicParameters or GetPropertyDynamicParameters but the execution always return this error Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. Provider execution stopped because the provider does not support this operation. any suggestion? |
My System Specs![]() |
| | #2 (permalink) |
| | Re: implementing get-item mario wrote: Quote: > hi... > > is possible to implement a provider that support operations like this? > > get-item mydrive:books['name']\author > > I am trying to implement it overriding methods like GetItem, > GetItemDynamicParameters or GetPropertyDynamicParameters but the > execution always return this error > > Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. > Provider execution stopped because the provider does not support this > operation. > > any suggestion? into it. -- Microsoft MVP - Windows PowerShell http://www.microsoft.com/mvp PowerGadgets MVP http://www.powergadgets.com/mvp Blog: http://marcoshaw.blogspot.com |
My System Specs![]() |
| | #3 (permalink) |
| | Re: implementing get-item hi marco.. apparently powershell doens't like xpath expressions .... so, I had tochange the way referencing th items that I want to get... ![]() currently I am building a psdrive for bts but is a lot of work ... there are many ways and many things to implement :P regards.! "Marco Shaw [MVP]" <marco.shaw@_NO_SPAM_gmail.com> wrote in message news:edTHIloaIHA.4180@xxxxxx Quote: > mario wrote: Quote: >> hi... >> >> is possible to implement a provider that support operations like this? >> >> get-item mydrive:books['name']\author >> >> I am trying to implement it overriding methods like GetItem, >> GetItemDynamicParameters or GetPropertyDynamicParameters but the >> execution always return this error >> >> Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. >> Provider execution stopped because the provider does not support this >> operation. >> >> any suggestion? > Any luck? I haven't abandoned you, just haven't had the time to look into > it. > > -- > Microsoft MVP - Windows PowerShell > http://www.microsoft.com/mvp > > PowerGadgets MVP > http://www.powergadgets.com/mvp > > Blog: > http://marcoshaw.blogspot.com |
My System Specs![]() |
| | #4 (permalink) |
| | Re: implementing get-item On Feb 7, 12:37*am, "mario" <carlos1...@xxxxxx> wrote: Quote: > hi... > > is possible to implement a provider that support operations like this? > > get-item mydrive:books['name']\author > > I am trying to implement it overriding methods like GetItem, > GetItemDynamicParameters or GetPropertyDynamicParameters but the execution > always return this error > > Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. Provider > execution stopped because the provider does not support this operation. > > any suggestion? Quote: > hi marco.. > > apparently powershell doens't like xpath expressions .... so, I had to> change the way referencing th items that I want to get... ![]() > > currently I am building a psdrive for bts but is a lot of work ... there are > many ways and many things to implement :P > > regards.! > > "Marco Shaw [MVP]" <marco.shaw@_NO_SPAM_gmail.com> wrote in messagenews:edTHIloaIHA.4180@xxxxxx > > > Quote: > > mario wrote: Quote: > >> hi... Quote: Quote: > >> is possible to implement a provider that support operations like this? Quote: Quote: > >> get-item mydrive:books['name']\author Quote: Quote: > >> I am trying to implement it overriding methods like GetItem, > >> GetItemDynamicParameters or GetPropertyDynamicParameters but the > >> execution always return this error Quote: Quote: > >> Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. > >> Provider execution stopped because the provider does not support this > >> operation. Quote: Quote: > >> any suggestion? Quote: > > Any luck? I haven't abandoned you, just haven't had the time to look into > > it. Quote: Quote: Quote: > - Show quoted text - We have several XML related cmdlets in Pscx ( www.codeplex.com/pscx ), one or two of which take XPath expressions. I think it's Select-Xml. Since it's a cmdlet, we're not succeptible to the path munging you're seeing in your provider. On the other hand, have you investigated using provider-direct paths? if you prefix a pspath with \\ it will not be pre-parsed by powershell and you *may* be able to work with relatively clean looking xpath paths. Give it a whirl, and if you get it working, feel free to donate it to Pscx ;-) The problem you're seeing is because you have left in the default implementation for GetItemDynamicProperties(string) which is probably a "throw new NotImplementedException()" statement. Just replace that statement with "return null;" Hope this helps, - Oisin - Oisin |
My System Specs![]() |
| | #5 (permalink) |
| | Re: implementing get-item hi oisin... thanks by your response, I'll test it ![]() regards.! "Oisin (x0n) Grehan [MVP]" <oising@xxxxxx> wrote in message news:f73627c5-6a9e-4adb-90da-513398feb759@xxxxxx On Feb 7, 12:37 am, "mario" <carlos1...@xxxxxx> wrote: Quote: > hi... > > is possible to implement a provider that support operations like this? > > get-item mydrive:books['name']\author > > I am trying to implement it overriding methods like GetItem, > GetItemDynamicParameters or GetPropertyDynamicParameters but the execution > always return this error > > Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. Provider > execution stopped because the provider does not support this operation. > > any suggestion? Quote: > hi marco.. > > apparently powershell doens't like xpath expressions .... so, I had to> change the way referencing th items that I want to get... ![]() > > currently I am building a psdrive for bts but is a lot of work ... there > are > many ways and many things to implement :P > > regards.! > > "Marco Shaw [MVP]" <marco.shaw@_NO_SPAM_gmail.com> wrote in > messagenews:edTHIloaIHA.4180@xxxxxx > > > Quote: > > mario wrote: Quote: > >> hi... Quote: Quote: > >> is possible to implement a provider that support operations like this? Quote: Quote: > >> get-item mydrive:books['name']\author Quote: Quote: > >> I am trying to implement it overriding methods like GetItem, > >> GetItemDynamicParameters or GetPropertyDynamicParameters but the > >> execution always return this error Quote: Quote: > >> Get-Item : Cannot retrieve the dynamic parameters for the cmdlet. > >> Provider execution stopped because the provider does not support this > >> operation. Quote: Quote: > >> any suggestion? Quote: > > Any luck? I haven't abandoned you, just haven't had the time to look > > into > > it. Quote: Quote: Quote: > - Show quoted text - We have several XML related cmdlets in Pscx ( www.codeplex.com/pscx ), one or two of which take XPath expressions. I think it's Select-Xml. Since it's a cmdlet, we're not succeptible to the path munging you're seeing in your provider. On the other hand, have you investigated using provider-direct paths? if you prefix a pspath with \\ it will not be pre-parsed by powershell and you *may* be able to work with relatively clean looking xpath paths. Give it a whirl, and if you get it working, feel free to donate it to Pscx ;-) The problem you're seeing is because you have left in the default implementation for GetItemDynamicProperties(string) which is probably a "throw new NotImplementedException()" statement. Just replace that statement with "return null;" Hope this helps, - Oisin - Oisin |
My System Specs![]() |
| | #6 (permalink) |
| | Re: implementing get-item On Mar 14, 12:53*pm, "mario" <carlos1...@xxxxxx> wrote: Quote: > hi oisin... > > thanks by your response, I'll test it ![]() > > regards.! > pscx! sorry) - Oisin |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| rename-item, move-item and special chars. | PowerShell | |||
| Copy-Item : Container cannot be copied onto existing leaf item. | PowerShell | |||
| Implementing Sql Object Dependency? | .NET General | |||
| Implementing SMO in Powershell | PowerShell | |||
| implementing security templates | Vista security | |||