(func_name: str, func_file_name: str, func_dir_path: str, params: str)
return full_command
Creates a registry valid command to link a context menu entry to a funtion, specifically for file selection(FILES, DIRECTORY, DRIVE).

    Requires the name of the function, the name of the file, and the path to the directory of the file.
Creates a registry valid command to link a context menu entry to a funtion, specifically for file selection(FILES, DIRECTORY, DRIVE).
Creates a registry valid command to link a context menu entry to a funtion specifically for file selection ( FILES DIRECTORY DRIVE ) .
def create_file_select_command(func_name: str, func_file_name: str, func_dir_path: str, params: str) -> 'Registry valid string to call python function':
    '''
    Creates a registry valid command to link a context menu entry to a funtion, specifically for file selection(FILES, DIRECTORY, DRIVE).

    Requires the name of the function, the name of the file, and the path to the directory of the file.
    '''
    python_loc = sys.executable
    sys_section = f'''import sys; sys.path.insert(0, '{func_dir_path}')'''.replace('\\', '/')
    file_section = f'import {func_file_name}'
    dir_path = """' '.join(sys.argv[1:]) """
    func_section = f'''{func_file_name}.{func_name}([{dir_path}],'{params}')'''
    python_portion = f'''"{python_loc}" -c "{sys_section}; {file_section}; {func_section}"'''
    full_command = f'''{python_portion} \"%1\"'''

    return full_command
def create_file_select_command ( func_name : str , func_file_name : str , func_dir_path : str , params : str ) -> 'Registry valid string to call python function' : python_loc = sys . executable sys_section = f'''import sys; sys.path.insert(0, '{func_dir_path}')''' . replace ( '\\' , '/' ) file_section = f'import {func_file_name}' dir_path = """' '.join(sys.argv[1:]) """ func_section = f'''{func_file_name}.{func_name}([{dir_path}],'{params}')''' python_portion = f'''"{python_loc}" -c "{sys_section}; {file_section}; {func_section}"''' full_command = f'''{python_portion} \"%1\"''' return full_command