microbox Active Member Licensed User Longtime User Apr 20, 2013 #1 I'm trying to create a folder in my sdcard (4Gb) but failed to do so or I do not know how to("/mnt/Sd card", "TestDirectory")...but when creating in the local memory the following code works.. Code: Copy File.MakeDir("/mnt/sdcard/extstorages/sdcard", "TestDirectory") Can anyone help, and tell me what I'm doing wrong? My device is MK802 + Android4.0 I attached an image that might be helpful to understand to what I'm trying to do. Thanks in advance, microbox Attachments FileManager.jpg 64.9 KB · Views: 602
I'm trying to create a folder in my sdcard (4Gb) but failed to do so or I do not know how to("/mnt/Sd card", "TestDirectory")...but when creating in the local memory the following code works.. Code: Copy File.MakeDir("/mnt/sdcard/extstorages/sdcard", "TestDirectory") Can anyone help, and tell me what I'm doing wrong? My device is MK802 + Android4.0 I attached an image that might be helpful to understand to what I'm trying to do. Thanks in advance, microbox
derez Expert Licensed User Longtime User Apr 20, 2013 #2 Code: Copy File.MakeDir(File.DirRootExternal,"TestDirectory") Upvote 0
microbox Active Member Licensed User Longtime User Apr 21, 2013 #3 Hi David, thanks for your reply...but still not able to create folder in the sdcard with the suggested code but it creates in the local memory instead(/mnt/sdcard)... Code: Copy Sub CreateDir File.MakeDir(File.DirRootExternal,"TestDirectory") Msgbox(File.DirRootExternal ,"") ' shows "/mnt/sdcard" Msgbox("Command executed!","Create Folder 1") End Sub Best Regards, microbox Last edited: Apr 21, 2013 Upvote 0
Hi David, thanks for your reply...but still not able to create folder in the sdcard with the suggested code but it creates in the local memory instead(/mnt/sdcard)... Code: Copy Sub CreateDir File.MakeDir(File.DirRootExternal,"TestDirectory") Msgbox(File.DirRootExternal ,"") ' shows "/mnt/sdcard" Msgbox("Command executed!","Create Folder 1") End Sub Best Regards, microbox
agraham Expert Licensed User Longtime User Apr 21, 2013 #4 Are you trying to make the folder on a real removable SD card rather than the internal memory? As a hangover from earlier devices which only had SD cards for bulk storage Android regards the internal memory of recent devices as "external memory". From the Android docs. Every Android-compatible device supports a shared "external storage" that you can use to save files. This can be a removable storage media (such as an SD card) or an internal (non-removable) storage. Files saved to the external storage are world-readable and can be modified by the user when they enable USB mass storage to transfer files on a computer. Click to expand... File.DirExternal refers to this memory, which in your case, judging by your screenshot, is probably the internal memory. If this is the case you need to find the path to the real SD card with a file explorer. As far as I know there is no standardised path for real external SD cards. Upvote 0
Are you trying to make the folder on a real removable SD card rather than the internal memory? As a hangover from earlier devices which only had SD cards for bulk storage Android regards the internal memory of recent devices as "external memory". From the Android docs. Every Android-compatible device supports a shared "external storage" that you can use to save files. This can be a removable storage media (such as an SD card) or an internal (non-removable) storage. Files saved to the external storage are world-readable and can be modified by the user when they enable USB mass storage to transfer files on a computer. Click to expand... File.DirExternal refers to this memory, which in your case, judging by your screenshot, is probably the internal memory. If this is the case you need to find the path to the real SD card with a file explorer. As far as I know there is no standardised path for real external SD cards.
microbox Active Member Licensed User Longtime User Apr 21, 2013 #5 Okay i got it...thank you very much agraham for helping me out... Upvote 0