Skip to content

Not Working with Windows Powershell in "ConstrainedLanguage" Mode #11

Description

@MLackner

If the Windows Powershell is set to "ConstrainedLanguage" mode and/or the execution of Powershell scripts is prohibited by the administrator the Dendron: Paste Image command does not work.

I tried to manually save an image from my system clipboard to the hard drive with Powershell with

$img = Get-Clipboard -Format Image
$img.Save(".\img.jpg")

Essentially, this is what this extension does. When I do this I get the following error:

Cannot invoke method. Method invocation is supported only on core types in this language mode.
[...]

Unfortunately I wasn't able to get the error message from VSCode.

I suspect that even the execution of the .ps1 script file will be blocked by the systems administrator.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions