PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV Mobile 24 → [WM23] Storing files, image etc. On iOS
[WM23] Storing files, image etc. On iOS
Débuté par ARV, 19 mar. 2019 17:42 - 6 réponses
Membre enregistré
371 messages
Posté le 19 mars 2019 - 17:42
Hi all

I was trying to save those types of files on my iPHone But I Couldn't do it.
I was using fCurrentDir() to have a path.
But when I try to use FTPGet with fCurrentDir() launch me an error, about that can't create the file or use it on write mode to store my file.

there's a way to save file on iPhone (iOS)?

--
Best Regards
ARV
Posté le 09 avril 2019 - 16:51
ARV,

I am about to go down that road.
I will let you know if I am successful.

Jim
Membre enregistré
371 messages
Posté le 10 avril 2019 - 22:10
Hi Jim

Thanks for your reply

I was testing some more of this and yes it is possible BUT!

only if the app create his own docs or recieve docs it is not possible to access files from the device only images and videos.
the way to save files on a path its with

fCurrentDir but in the end put a fsep() function something like

sPathiOS is string = fCurrenDir()+fSep()


with this you can save files on the file path of the app access to this and do whatever you want with them, but only the app could access this files.

now to access files of the device like image its with:
ImagePath is string
ImagePath = AlbumPicker(albumImage)


to access files of the device like videos it's with:
ImagePath is string
ImagePath = AlbumPicker(albumVideo)


this will get you the path of the image or video, what PCsoft say it's that this files are copy from his file to the fCurrentDir, so that's why you can access to them.

that's all I found about this topic... Hope you get lucky more than me.

source of AlbumPicker:
https://help.windev.com/en-US/…

source of fCurrentDir:
https://help.windev.com/en-US/…

--
Best Regards
ARV
Message modifié, 10 avril 2019 - 22:11
Posté le 11 avril 2019 - 19:17
ARV,

It works as you said. My app is getting data from a piece of hardware.
Then it creates a .csv file of the data.
I am then able to open the email app and send it.

One strange thing is happening and I cannot say what is causing it. Emulator and phone both.
The .csv will open incorrectly in Excel. Other programs like Open Office and Google see it correctly.
Excel says it is in an unrecognizable format. It will open, but everything is in one column. The commas are there.

It appears IOS is locked down pretty good. The files app doesn't even have the option of looking on the phone, only ICloud.


Jim
Posté le 11 avril 2019 - 20:28
I think I am OK.
My Excel version is likely too old.

I didn't try to open a file in the app though. (I have no need to)
Would you like me to attempt it?

Jim
Membre enregistré
371 messages
Posté le 11 avril 2019 - 22:06
Hi Jim

Good thing to know that works for you.

If you want to try it yes, maybe it's the version of the excel who knows.
about send it something on email, do you create your own app or it's something like gmail?
with that in mind how could you access to the files you create or recieve on fCurrentDir?
is it possible to access that file with another app?
that file are not erased when the app it's uninstall?

Good luck!

--
Best Regards
ARV
Membre enregistré
371 messages
Posté le 14 mai 2019 - 22:06
Hi

be careful using fCurrentDir if the app updated or it's uninstall then you will lose every file you save there
this only happend to iOS thought

--
Best Regards
ARV