Skip to content

Issues running the context command #20

Description

@Logonz

I am running windows 11 and i just tried to use pyWinContext, I used the example in the readme and i get this error.

image

My reg file looks like this:

Windows Registry Editor Version 5.00

[-HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0]

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell]

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0]
@="List File Details"

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0\command]
@="cmd /c C:\\Users\\Logon\\AppData\\Roaming\\pyWinContext\\comStore\\242669942215147203472854078214285481705.bat "%1""

Bat file:

@echo off
echo Name: %~n1
echo Filetype: %~x1
echo FileSize: %~z1
pause

Working reg file:

Windows Registry Editor Version 5.00

[-HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0]

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell]

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0]
@="List File Details"

[HKEY_CLASSES_ROOT\SystemFileAssociations\.txt\shell\pyWin-filedetails-0\command]
@="cmd.exe /s /c \"C:\\Users\\Logon\\AppData\\Roaming\\pyWinContext\\comStore\\242669942215147203472854078214285481705.bat \"%1\"\""

Where i use /s and escape the citations instead, this solved the issue.

Has anyone else run into this issue?

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions