Associate file type (extension) with my app

Discussion in 'Mac Programming' started by albebaubles, Feb 9, 2010.

  1. albebaubles macrumors regular

    albebaubles

    Joined:
    Feb 9, 2010
    Location:
    Desert Southwest
    #1
    I have an app that creates files with it's own extension type '.qaz'.

    How do I go about programatically associating that extension with my application such that when a user clicks on the .qaz file my application automatically opens.

    FYI, the app is Leopard and SL only.

    Thanks.
     
  2. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #2
    Lookup universal type identifier in the documentation.
     
  3. Sydde macrumors 68020

    Sydde

    Joined:
    Aug 17, 2009
  4. albebaubles thread starter macrumors regular

    albebaubles

    Joined:
    Feb 9, 2010
    Location:
    Desert Southwest
    #4

    OK, the plist is what I've been trying, so I'm at least headed down the right path. My problem is the text editor still continues to open when I double-click my file.

    Found it:

    "Launch Manager" is responsible for opening files based on associations. Launch Manager settings are held in ~/Library/Preferences/com.apple.LaunchServices.plist. Some associations are cached in /Library/Caches/com.apple.LaunchServices*.csstore (the exact name varies with OS version). To remove the offending association:
    rename/move the cache(s) (you could delete, but a rename/move is safer)
    restart
    open the LaunchServices preferences in the Property List Editor
    search for and remove the association for the binary files.



    I'm styling. Thanks, all.
     

Share This Page