-4

I have an app... I want to add a feature to that app. Feature is automatically rename a folder in sdcard.

It doing this. Download a file. Then it extract to sd card automatically. So is there anyway to make it rename automatically? Any code for smali?

  • You should mention that you only have the *binaries* of an app, i.e. the `.apk` file, and you want to rename a folder that app creates automatically. Or am I getting you wrong? – JimmyB May 28 '15 at 11:30
  • Yes. I have the decompiled apk... Smali files and other xml files... I want to rename that extracted folder... The folder is /sdcard/Android/data-test – Nishantha Indika Bandara May 28 '15 at 11:32
  • You'll probably find the literal "data-test" somewhere in the decompiled resources. Once located, you can try and change that constant, re-compile the app, and see if that does the trick. - You may be infringing on copyright and/or license terms though! – JimmyB May 28 '15 at 11:35
  • In my app automatically deleting the data folder. Cannot find it on the app codes. Then I made the file extract as data-test folder. So I wanna do after extract rename data-test to data folder... – Nishantha Indika Bandara May 28 '15 at 11:42
  • Can you make a little app to rename a specific folder? So when app launch the folder will rename automatically... – Nishantha Indika Bandara May 28 '15 at 13:01
  • That should be really easy to do. See for instance http://stackoverflow.com/questions/2896733/how-to-rename-a-file-on-sdcard-with-android-application. – JimmyB May 28 '15 at 13:59
  • I got the source code... Can u help me to get this rename method add to this source code of app? – Nishantha Indika Bandara Jun 01 '15 at 06:15

1 Answers1

-1

just use this code oldfilename.renameTo(new_file_name);

Ankita Bansal
  • 335
  • 1
  • 5
  • 11