MicroDrie Well-Known Member Licensed User Longtime User Sep 6, 2019 #1 I search the forum for two days, bud I can't find the answer how I convert an object to a string format. The result of the following code gives an object: Code: Copy Shared = rp.GetAllSafeDirsExternal("") Log(Shared) This result in the log is: [Ljava.lang.String;@b87a6f1 How can I both string representing the Phone and the SDcard into two different variables?
I search the forum for two days, bud I can't find the answer how I convert an object to a string format. The result of the following code gives an object: Code: Copy Shared = rp.GetAllSafeDirsExternal("") Log(Shared) This result in the log is: [Ljava.lang.String;@b87a6f1 How can I both string representing the Phone and the SDcard into two different variables?
DonManfred Expert Licensed User Longtime User Sep 6, 2019 #2 Code: Copy dim folders as list = rp.GetAllSafeDirsExternal("") Upvote 0
MicroDrie Well-Known Member Licensed User Longtime User Sep 6, 2019 #3 Works like a charm, thanxs Upvote 0
thetahsk Active Member Licensed User Longtime User Sep 6, 2019 #4 The result of a 50 sec. search Code: Copy Dim rp As RuntimePermissions For Each s As String In rp.GetAllSafeDirsExternal("") Log(s) Next Upvote 0
The result of a 50 sec. search Code: Copy Dim rp As RuntimePermissions For Each s As String In rp.GetAllSafeDirsExternal("") Log(s) Next
MicroDrie Well-Known Member Licensed User Longtime User Sep 6, 2019 #5 Yes thetahsk that was also my fist and easy step. The point is that I want to test if there is, and if so, to use or create a sub directory on a SDcard. Therefore I need sure about the correct name in the second string option in the object. Your solution gives the sub directories of the phone memory. Every phone or tablet has a different name for the SDcard. Upvote 0
Yes thetahsk that was also my fist and easy step. The point is that I want to test if there is, and if so, to use or create a sub directory on a SDcard. Therefore I need sure about the correct name in the second string option in the object. Your solution gives the sub directories of the phone memory. Every phone or tablet has a different name for the SDcard.
DonManfred Expert Licensed User Longtime User Sep 6, 2019 #6 To access a SDCard or USB Disc you need to use the ExternalStorage Class. At least on Android 5+ Upvote 0
E emexes Expert Licensed User Longtime User Sep 6, 2019 #7 MicroDrie said: I search the forum for two days, bud I can't find the answer Click to expand... 1/ I'm hoping that "two days" is overstatement for effect 2/ Another useful place to get information is within the IDE itself, which tells us that GetAllSafeDirsExternal returns a String Array (which cast reasonably well to Lists, per Manfred's prompt answer): Upvote 0
MicroDrie said: I search the forum for two days, bud I can't find the answer Click to expand... 1/ I'm hoping that "two days" is overstatement for effect 2/ Another useful place to get information is within the IDE itself, which tells us that GetAllSafeDirsExternal returns a String Array (which cast reasonably well to Lists, per Manfred's prompt answer):
MicroDrie Well-Known Member Licensed User Longtime User Sep 6, 2019 #8 Yes there is so much information on this site. I read a lot in those two days. In addition to studying the instructional videos, I have also read many interesting things that are often casually reported in answering questions from forum users. And I probably would never have read it if I had written an object "out-of-the-blue" in one go to a list . Thanks to everyone for the help offered . Upvote 0
Yes there is so much information on this site. I read a lot in those two days. In addition to studying the instructional videos, I have also read many interesting things that are often casually reported in answering questions from forum users. And I probably would never have read it if I had written an object "out-of-the-blue" in one go to a list . Thanks to everyone for the help offered .