java - Command to find default program related to file(.pdf) using command line in windows OS -


is there command through can find user has selected particular program (e.g. adobe reader/adobe acrobat) default program particular file extension (e.g. .pdf) in windows?

more specifically:

  • if select adobe reader default pdf viewer file properties
  • string viewer1 = "command .pdf" (running in command prompt)
  • then change acrobat file properties → change default program
  • string viewer2 = "command .pdf" (running in command prompt)

so, viewer1 != viewer2

i working in java swing, if there library or way find default program selected .pdf file, helpful me.

does registry key exist, stores default program path specific file extension (.pdf)?

edited

okay missed part here. consists of 2 commands.

  1. assoc filetype association extension e.g. .jpg=jpegimage
  2. ftype default handler ftype jpegimage

hope helps. suppose pipeline 2 have no idea how thats done in windows.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -