Does anyone know how to create a folder tree in the Eclipse DDMS File Explorer?

早过忘川 提交于 2019-12-11 10:47:54

问题


I'm trying to create the path "/package name/databases" under the sdcard folder. Anybody got the secret?


回答1:


Are you using fileobj.mkdir() method from File class? Check if the directory already exist if not exist then create it.Refer

And don't forget about writing permissions for external storage, WRITE_EXTERNAL_STORAGE.




回答2:


Just select the parent folder and click the small + ("New Folder"). Do this again for the next subfolder.




回答3:


Creating SD Card

 Access to your Android SDK Tools folder and use command “mksdcard” in order to create one.

 By default installation on Windows, the Tools folder should be here:

  C:\Program Files\Android\android-sdk\tools
 Using following syntax to create your desired SD Card

  mksdcard [memory size] [output file]

For example, I’d like to create a SD card with 200 MB in memory and put the files in 
 C:\Personel\AndroidNewbie\SDCard with file named “sdcard_dev.iso“, I do like this:

 mksdcard 256M C:\Personel\AndroidNewbie\SDCard\<span class="skimlinks-unlinked">sdcard_dev.iso</span>

Then

Using SD Card

You’ve done creating your desired SD Card, now you need it to be used by Android emulator. Open Eclipse, 
   access to your project.
   On menu Run -> Run Configurations, click on Android Configuration on the left tree menu, click on tab 
  Target on the right pane. You will see at the bottom: “Additional Emulator Commandline Options” and an 
  Input/Edit box below:
 Just type your input sdcard following syntax   
  -sdcard [sdcard location]

 For example, with the SD Card I’ve created above, I type:  

 -sdcard C:\Personel\AndroidNewbie\SDCard\<span class="skimlinks-unlinked">sdcard_dev.iso</span>


来源:https://stackoverflow.com/questions/7222580/does-anyone-know-how-to-create-a-folder-tree-in-the-eclipse-ddms-file-explorer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!