<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Problem creating folders on iOS device in ArcGIS AppStudio Questions</title>
    <link>https://community.esri.com/t5/arcgis-appstudio-questions/problem-creating-folders-on-ios-device/m-p/1087413#M4026</link>
    <description>&lt;P&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;Im having troubles with the file structure of my app using the FileFolder qml type.&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;FileFolder&lt;/SPAN&gt;{&lt;BR /&gt;&lt;SPAN&gt;     id&lt;/SPAN&gt;: &lt;SPAN&gt;appFolder&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;     path&lt;/SPAN&gt;: &lt;SPAN&gt;app&lt;/SPAN&gt;.folder.path&lt;BR /&gt;}&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;When i launch the app i execute the next method on the Component.OnCompleted event of the App:&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;appFolder&lt;/SPAN&gt;.makePath(&lt;SPAN&gt;AppFramework&lt;/SPAN&gt;.userHomeFolder.filePath(&lt;SPAN&gt;"ArcGIS/AppStudio/Data/test/"&lt;/SPAN&gt;))&lt;/PRE&gt;&lt;P&gt;That line returns a False&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In other part of the app, i use the ZipReader to extract all the files that i get from my server, and that creates the folders without problem using the next line:&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;zipReader&lt;/SPAN&gt;.extractAll(&lt;SPAN&gt;AppFramework&lt;/SPAN&gt;.userHomeFolder.filePath(&lt;SPAN&gt;"ArcGIS/AppStudio/Data/test/"&lt;/SPAN&gt; + &lt;SPAN&gt;zippedIdSim&lt;/SPAN&gt;));&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I really dont know if i doing something wrong, but it strange that it works perfectly on Windows but on iOS can not create folders with the makePath method...&lt;/P&gt;&lt;P&gt;The main objective is to create individual folders inside that path.&lt;/P&gt;&lt;PRE&gt;ArcGis&lt;BR /&gt;  └AppStudio&lt;BR /&gt;    └Data&lt;BR /&gt;      └Test&lt;BR /&gt;        └376646c3-9cd4-434f-b09c-0d8a22776f82&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └e2068270-3c49-47b5-8b02-59a3cfae2654&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └67a8ae80-ef1a-410b-abc1-0762364bfac0&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └92c33799-d11c-4443-af36-7b5603d56c05&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └dc087ef0-f590-49ee-9b29-fe252ec0cbb1&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └92d3bcf8-6d66-45f8-8fe3-e0c8ce9d542f&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └61825d42-e813-4ec4-991f-afeba2e64c3f&lt;BR /&gt;          └{some files}&lt;/PRE&gt;&lt;P&gt;The ones that comes with a Zip file works perfectly, but if i need to create the folder manually don't work at all.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A greeting!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 10 Aug 2021 10:18:57 GMT</pubDate>
    <dc:creator>JorgeFrade_Martínez</dc:creator>
    <dc:date>2021-08-10T10:18:57Z</dc:date>
    <item>
      <title>Problem creating folders on iOS device</title>
      <link>https://community.esri.com/t5/arcgis-appstudio-questions/problem-creating-folders-on-ios-device/m-p/1087413#M4026</link>
      <description>&lt;P&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;Im having troubles with the file structure of my app using the FileFolder qml type.&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;FileFolder&lt;/SPAN&gt;{&lt;BR /&gt;&lt;SPAN&gt;     id&lt;/SPAN&gt;: &lt;SPAN&gt;appFolder&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;     path&lt;/SPAN&gt;: &lt;SPAN&gt;app&lt;/SPAN&gt;.folder.path&lt;BR /&gt;}&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;When i launch the app i execute the next method on the Component.OnCompleted event of the App:&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;appFolder&lt;/SPAN&gt;.makePath(&lt;SPAN&gt;AppFramework&lt;/SPAN&gt;.userHomeFolder.filePath(&lt;SPAN&gt;"ArcGIS/AppStudio/Data/test/"&lt;/SPAN&gt;))&lt;/PRE&gt;&lt;P&gt;That line returns a False&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In other part of the app, i use the ZipReader to extract all the files that i get from my server, and that creates the folders without problem using the next line:&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;zipReader&lt;/SPAN&gt;.extractAll(&lt;SPAN&gt;AppFramework&lt;/SPAN&gt;.userHomeFolder.filePath(&lt;SPAN&gt;"ArcGIS/AppStudio/Data/test/"&lt;/SPAN&gt; + &lt;SPAN&gt;zippedIdSim&lt;/SPAN&gt;));&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I really dont know if i doing something wrong, but it strange that it works perfectly on Windows but on iOS can not create folders with the makePath method...&lt;/P&gt;&lt;P&gt;The main objective is to create individual folders inside that path.&lt;/P&gt;&lt;PRE&gt;ArcGis&lt;BR /&gt;  └AppStudio&lt;BR /&gt;    └Data&lt;BR /&gt;      └Test&lt;BR /&gt;        └376646c3-9cd4-434f-b09c-0d8a22776f82&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └e2068270-3c49-47b5-8b02-59a3cfae2654&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └67a8ae80-ef1a-410b-abc1-0762364bfac0&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └92c33799-d11c-4443-af36-7b5603d56c05&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └dc087ef0-f590-49ee-9b29-fe252ec0cbb1&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └92d3bcf8-6d66-45f8-8fe3-e0c8ce9d542f&lt;BR /&gt;          └{some files}&lt;BR /&gt;        └61825d42-e813-4ec4-991f-afeba2e64c3f&lt;BR /&gt;          └{some files}&lt;/PRE&gt;&lt;P&gt;The ones that comes with a Zip file works perfectly, but if i need to create the folder manually don't work at all.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A greeting!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Aug 2021 10:18:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-appstudio-questions/problem-creating-folders-on-ios-device/m-p/1087413#M4026</guid>
      <dc:creator>JorgeFrade_Martínez</dc:creator>
      <dc:date>2021-08-10T10:18:57Z</dc:date>
    </item>
    <item>
      <title>Re: Problem creating folders on iOS device</title>
      <link>https://community.esri.com/t5/arcgis-appstudio-questions/problem-creating-folders-on-ios-device/m-p/1089459#M4033</link>
      <description>&lt;P&gt;You're mixing concepts. `app.folder` refers to content, including QML that is makes your app. Whilst developing, you run your app in AppStudio and/or Player and this area is read-write. However, the issue here is when you build your app, `app.folder` will refer to a read-only compiled resource and become read-only. Therefore, `app.folder` is not a fit area to unpack your data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The `AppFramework.userHomeFolder` refers to a cross platform representation of a "HOME" directory. For Linux and macOS, this does equate to the actual home folder. Similarly for Windows. However, for iOS and Android this refers to a sandboxed area within your app. It is okay, to use. However, in your usage, you try to append the two areas together.&lt;/P&gt;&lt;P&gt;I like to draw your attention to our shorthand "~" syntax which is a shortcut for your home folder, so you do not need to explicitly spell it out. The usage is like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FileFolder {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; id: workspace&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; path: "~/ArcGIS/AppStudio/Data/test"&lt;/P&gt;&lt;P&gt;}&lt;BR /&gt;&lt;BR /&gt;Then, to ensure that folder exists, you correctly identify that `makePath` needs to be called, i.e. `&lt;SPAN&gt;workspace.makePath()`,&lt;BR /&gt;&lt;BR /&gt;I hope these pointers put you in the right direction. I haven't commented on your usage of ZIP, I think it's straightforward. But, if you need further assistance, let me know and we will troubleshoot further.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Aug 2021 22:02:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-appstudio-questions/problem-creating-folders-on-ios-device/m-p/1089459#M4033</guid>
      <dc:creator>StephenQuan4</dc:creator>
      <dc:date>2021-08-16T22:02:35Z</dc:date>
    </item>
  </channel>
</rss>

