Wish No path shown for HttpUtils2Service.TempFolder

Peter Simpson

Expert
Licensed User
Longtime User
Hello Anywhere Software,

In both B4A and also B4J, using the following line returns a folder path, but in B4i it returns absolutely nothing. At first I thought that there must be an issue, but I think that it's just me.

B4X:
HttpUtils2Service.TempFolder

B4A returns /data/user/0/b4a.example/cache
B4J returns C:\Users\<username>\AppData\Local\Temp\
B4i returns Nice fresh air

It would be really nice if B4i also returned a folder path, or does the OS (iOS) somehow deals with this automatically for us. I couldn't find anything about it on the forum.

Or what am I missing???

Thank you...
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
 

Peter Simpson

Expert
Licensed User
Longtime User
Howdi @Erel
I was looking at HttpUtils2Services.bas when I saw line 40. I changed line 40 to what is shown in the code below (I just added or B4i), and that appears to have cured my query above with multiple successful tests (I've changed the file back now). According to your excellent tutorial on iOS Files and Folders, File.DirTmp - The location of temporary files. These files will not be backuped by iTunes. The OS can clean this folder from time to time (you are also expected to delete unused files from this folder).

So my question is as follows, what am I missing here Erel, what is the theory on why line 40 can't read as below?
I'm NOT questioning your decision (I'm obviously not that crazy ?), no not at all. I'm just asking as part of my current learning process, as if possible I like to learn something new every day, if possible.

B4X:
#Else If B4J or B4i
    TempFolder = File.DirTemp
#End If

I'm actually feeling a bit reluctant to create this post/question, so please be kind to me lol ?

Thank you...
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…