Soru

Zorluk: OrtaMicrosoft Command-Line Tools

A systems administrator needs to configure several Windows 11 workstations so that files with a custom file extension (.logcfg) automatically open using a specific proprietary application executable. The administrator wants to inspect and update the file extension binding and the corresponding executable command-line program using the Windows Command Prompt. Which TWO command-line utilities should the administrator use to accomplish this task?

  1. assocCevap
  2. ftypeCevap
  3. C
    chmod
  4. D
    dism

Cevap

The administrator should use `assoc` and `ftype` to manage file extension bindings and associated executable launch strings in Windows.
In Windows, file association management from the command prompt is split into two commands: `assoc` links a file extension to a file type name, while `ftype` defines the executable launch command for that file type.

Adım Adım Çözüm

1
Use `assoc` in the command prompt to view or change the file type assigned to a specific file extension (e.g., `assoc .logcfg=LogConfigFile`).
Links the file extension `.logcfg` to a custom file type identifier.
The system must first know which file type name maps to the specified extension.
2
Use `ftype` in the command prompt to specify the program and arguments used to open that file type (e.g., `ftype LogConfigFile="C:\Program Files\App\editor.exe" "%1"`).
Associates the custom file type identifier with the binary executable path.
The file type must be bound to the exact executable path so Windows knows how to open files of that type.

Anahtar Kavram

Managing Windows file extension associations via Command Prompt using `assoc` and `ftype`
Bu soruyu puanla