1

Applying the fixes from Android Studio 0.8.6: Failure [INSTALL_FAILED_OLDER_SDK] and Android Studio : Failure [INSTALL_FAILED_OLDER_SDK], I get the error:

Loading SDK information...
Refresh Sources:
  Fetched Add-ons List successfully
  Refresh Sources

Installing Archives:
  Preparing to install archives
  Downloading SDK Platform Android 4.4W, API 20, revision 1
  Installing SDK Platform Android 4.4W, API 20, revision 1
  Failed to rename directory C:\android-studio\sdk\platforms\android-20 to C:\android-studio\sdk\temp\PlatformPackage.old01.

SDK Manager: failed to install
-= Warning ! =-
A folder failed to be moved. On Windows this typically means that a program is using that folder (for example Windows Explorer or your anti-virus software.)
Please momentarily deactivate your anti-virus software or close any running programs that may be accessing the directory 'C:\android-studio\sdk\platforms\android-20'.
When ready, press YES to try again.
Note: you  can use --force to override to yes.
[y/n] =>
  Done. Nothing was installed.

What am I doing wrong, and how do I fix this?

Community
  • 1
  • 1
user5262
  • 391
  • 5
  • 11

1 Answers1

2

You have saved your project in the SDK folder. When the SDk is trying to be updated the entire folder will be replaced with new data. Since the project is opened in IDE and SDK is trying to replace the folder its showing this error. Copy your project folder in a different folder and close your current project and try updating.

Psypher
  • 10,717
  • 12
  • 59
  • 83
  • Thanks, **File > Close Project**, press **Configure > SDK Manager** in the Android Studio window, and then install the missing package did the trick. – Loknar Dec 31 '14 at 13:40