Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Unassigning file type to application

I would like to find a safe way to restore the default assignments between file types and applications. For example, when trying to open a certain file type for the first time, I ask for "Get Info" on the file and it says open with <None>. Or if I double click the file, it asks what application I want to use.

Now assume I tell it an application to use. From then on the system will use that application for that file. Is there a way to "undo" that assignment without selecting a new application?

In other words, how can I get the system to go back to thinking there is no application assigned to that file or file type?

iMac, Mac OS X (10.4.11)

Posted on Aug 26, 2008 11:03 AM

Reply
Question marked as Best reply

Posted on Aug 26, 2008 4:29 PM

Basically you cannot as there is no "None" option to select in the Open With section of Get Info, but you can assign a different application.

You can also clear the LaunchServices database:

Rebuild LaunchServices Database

For Tiger users

Open the Terminal application in your Utilities folder. At the prompt paste in the following command in its entirety:

/System/Library/Frameworks/ApplicationServices.framework/Frameworks/LaunchServic es.framework/Support/lsregister -kill -r -domain local -domain system -domain user
Press RETURN.


For Leopard users

Open the Terminal application in your Utilities folder. At the prompt paste in the following command in its entirety:

/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchSe rvices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system -domain user
Press RETURN.
10 replies
Question marked as Best reply

Aug 26, 2008 4:29 PM in response to t.c.p.

Basically you cannot as there is no "None" option to select in the Open With section of Get Info, but you can assign a different application.

You can also clear the LaunchServices database:

Rebuild LaunchServices Database

For Tiger users

Open the Terminal application in your Utilities folder. At the prompt paste in the following command in its entirety:

/System/Library/Frameworks/ApplicationServices.framework/Frameworks/LaunchServic es.framework/Support/lsregister -kill -r -domain local -domain system -domain user
Press RETURN.


For Leopard users

Open the Terminal application in your Utilities folder. At the prompt paste in the following command in its entirety:

/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchSe rvices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system -domain user
Press RETURN.

Aug 26, 2008 5:37 PM in response to Kappy

Thanks very much for your answer. However, I've never used Terminal before but I know how to access it.

Two questions:

1. If I follow your advice exactly, can you think of any unintended consequences that may result from this action? Will the default assignments between applications and file types be restored or will all assignments be removed?

2. I need very explicit instructions on how to do what you say. Do I copy the entire text including the Press Return part as one item? If so, after I paste it into Terminal at the Prompt, do I need to hit return also, or will the action occur as soon as I paste? Assuming that all goes well, how do I exit Terminal gracefully?

I guess after I exit Terminal I should be able to go to a file or file type that originally had no application assigned and it should show me the <None> option or ask what application I want to open it with. Is that correct?

Thanks again.

Aug 26, 2008 6:01 PM in response to t.c.p.

1. No, nothing bad should happen.

2. Copy ONLY the full command line, not the Press RETURN.

/System/Library/Frameworks/ApplicationServices.framework/Frameworks/LaunchServic es.framework/Support/lsregister -kill -r -domain local -domain system -domain user


After you copy the command line to the Terminal THEN Press RETURN. Wait for the Terminal prompt to reappear. You can then quit the Terminal application.

I do not know if "None" will return or not. Normally all document files have a default application associated with them. Applications do not because they are, well, applications. Unknown file types may not have an application assigned or may be assigned a default application based on its content even though it may be the wrong default application.

Aug 26, 2008 8:17 PM in response to Kappy

OK, I followed your instructions, but the system still remembered the application that I had assigned to the file type. (Before I assigned an application, it had to ask me what to use, but now it doesn't.)

I just want to make sure that the command line I used was actually executed. This is what the terminal screen looked like except that the command line did not break at the same points. It broke wherever it needed to to fill each line, including in the middle of words. I have replaced the actual letters preceding the prompts with X or x and the actual numbers with n.

Last login: Tue Aug 26 19:33:02 on ttyp1
Welcome to Darwin!
x-nn-nnn-nn-nnn:~ Xxx$ (Prompt)/System/Library/Frameworks/ApplicationServices.framework/Frameworks/Lau nchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user
x-nn-nnn-nn-nnn:~ Xxx$ (Prompt)

My concern is that after I pressed return there was a pause and then the prompt appeared again preceded by the same characters that preceded the previous prompt. There was no indication that anything happened other than the pause.

Any thoughts?

Aug 26, 2008 9:14 PM in response to t.c.p.

Looks just fine. As I said I didn't think a "None" choice would appear as it's only there when no default has ever been assigned and LaunchServices doesn't know what to assign. In fact there is no need for a "None" entry as there is something assigned for everything. I don't really understand why this is of importance for you.

Aug 26, 2008 10:22 PM in response to Kappy

When I first tried to open a .json file (where I believed my Firefox bookmarks were backed up), I was asked what application to use. I didn't have a clue, so I told it to use TextEdit. When I did that, the file opened and I could see among the gobbledygook that my bookmarks were there.

However, from that point on the file icon for the .json file changed from what I call a generic icon to a TextEdit or Document icon. Shortly after that I noticed that Firefox had created a Crash Reports folder where there had not been one before. I was afraid that by assigning TextEdit to the .json file and changing its icon, I had inadvertently done something that Firefox didn't like.

Since then I have come to believe that the creation of the Crash Reports folder was probably not related to my assignment of .json files to the TextEdit application.

So it is now mostly an item of academic interest. I didn't realize that it would be so much trouble to get the system to return to the original state in which it did not know how to open .json files and thus revert to the original file icon.

I'm wondering if the assignment I made between .json and TextEdit got stored in the TextEdit application itself as well as in the Launch Services code.

In any event I can live with my present situation and I thank you greatly for your patience. I will close this question after I see if you have any final thoughts. For example, is there any way to check if TextEdit remembers that I assigned .json files to it?

Aug 26, 2008 10:32 PM in response to t.c.p.

Assuming the file in question was created by Firefox, then why not simply save another copy of the file somewhere else on the drive, delete this one, then replace it with the newly saved copy. This should get you a file with the proper icon. The icon is generally irrelevant to the file as far as it's use with Firefox as long as the file has the proper file extensions, i.e., .json.

Aug 27, 2008 3:15 PM in response to Kappy

Two things:

1. Regarding your recommendation, I copied one of the .json files to my desktop, but the icon that appeared on my desktop was identical to the one that Firefox created. Also, the file on my desktop was still associated with TextEdit. So I did not delete the file in Firefox and replace it because I didn't think anything would change.

2. The .json files in question are daily bookmark backups. Each day Firefox creates a new one. The new .json file it created today (after I did the Launch Services command last evening) still shows the assignment to TextEdit and the document icon rather than the original generic icon.

So I guess I will give up.

Appreciate your help though!

Thanks.

Aug 27, 2008 3:20 PM in response to t.c.p.

Have you ever tried this?

Repairing the Hard Drive and Permissions

Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger and Leopard.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer. Now restart normally.

If DU reports errors it cannot fix, then you will need Disk Warrior (4.0 for Tiger, and 4.1 for Leopard) and/or TechTool Pro (4.6.1 for Leopard) to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.

Then after the above download a utility such as TinkerTool System - VersionTracker or MacUpdate - and use it to clear user and system caches and old log archives. Then reboot the computer.

Unassigning file type to application

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.