<?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 Re: Create Windows folders based on attribute value of polygon in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370443#M77441</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Yes - you could achieve this this through ArcPy and Python by:&lt;/P&gt;&lt;P&gt;1: Use an ArcPy Data Access &lt;STRONG&gt;SearchCursor()&lt;/STRONG&gt; to return the values stored in a given attribute field.&lt;/P&gt;&lt;P&gt;2: Loop through the resulting object and for each value call the &lt;EM&gt;CreateFolder&lt;/EM&gt; geoprocessing tool.&lt;/P&gt;&lt;P&gt;and that would work quite nicely.&lt;/P&gt;&lt;P&gt;But you can also achieve the same thing&amp;nbsp; through ModelBuilder. You would need to:&lt;/P&gt;&lt;P&gt;1: Use the &lt;STRONG&gt;Iterate Feature Selection&lt;/STRONG&gt; iterator. For the &lt;EM&gt;In Features&lt;/EM&gt; parameter you should choose the dataset which contains the selected records whose attributes will be used to create the folders from.&lt;/P&gt;&lt;P&gt;2: Add the &lt;STRONG&gt;Get Field Value&lt;/STRONG&gt; utility tool to&amp;nbsp; the model and connect the &lt;EM&gt;Selected Features&lt;/EM&gt; output of the iterator to the &lt;EM&gt;Input Table&lt;/EM&gt; parameter of &lt;EM&gt;Get Field Value&lt;/EM&gt;. You also need to specify&amp;nbsp; the attribute field of your feature layer as the &lt;EM&gt;Field&lt;/EM&gt; parameter of the &lt;EM&gt;Get Field Value&lt;/EM&gt; utility tool.&lt;/P&gt;&lt;P&gt;3: Add the &lt;STRONG&gt;Create Folder&lt;/STRONG&gt; tool.&lt;/P&gt;&lt;P&gt;4: Connect the output of &lt;EM&gt;Get Field Value&lt;/EM&gt; to the &lt;STRONG&gt;Create Folder&lt;/STRONG&gt; tool specifying the&lt;EM&gt; Folder Name&lt;/EM&gt; parameter. You also need to select the &lt;EM&gt;output folder&lt;/EM&gt; as a parameter for the &lt;EM&gt;Create Folder&lt;/EM&gt; tool.&lt;/P&gt;&lt;P&gt;The final model should look like the one supplied..... It took me about 5 minutes to make this. Hope it helps you out! thanks ed&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="CreateFolder.PNG" style="width: 842px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/91683i192E0B0E4D4F1B90/image-size/large?v=v2&amp;amp;px=999" role="button" title="CreateFolder.PNG" alt="CreateFolder.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 16 Jan 2024 13:27:04 GMT</pubDate>
    <dc:creator>EdM</dc:creator>
    <dc:date>2024-01-16T13:27:04Z</dc:date>
    <item>
      <title>Create Windows folders based on attribute value of polygon</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370395#M77437</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Looking for any help or guidance please. I'm trying to create a windows explorer folder based on an attribute held within a file geodatabase. The use case is as below...&lt;/P&gt;&lt;P&gt;1) I've got a selection of polygons/sites which all need a separate project folder within a specific area within Windows explorer. Currently this being done manually, but we'll be looking to ramp up our number of sites so this will soon become untenable. Each polygon/site has it's own unique site number, which I'd like the folder name to be.&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) I know there is a geoprocessing tool which allows you to add a new folder but this is just one and needs manual intervention in terms of folder name.&amp;nbsp;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/create-folder.htm" target="_blank"&gt;Create Folder (Data Management)—ArcGIS Pro | Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;3) I'm a complete novice to Python but do believe this may be the best/only way to be able to do this.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Has anyone come across similar or knows how to solve my issue please? I'd be very grateful.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&amp;nbsp;&lt;/P&gt;&lt;P&gt;James&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jan 2024 10:35:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370395#M77437</guid>
      <dc:creator>James_Shreeve</dc:creator>
      <dc:date>2024-01-16T10:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: Create Windows folders based on attribute value of polygon</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370443#M77441</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Yes - you could achieve this this through ArcPy and Python by:&lt;/P&gt;&lt;P&gt;1: Use an ArcPy Data Access &lt;STRONG&gt;SearchCursor()&lt;/STRONG&gt; to return the values stored in a given attribute field.&lt;/P&gt;&lt;P&gt;2: Loop through the resulting object and for each value call the &lt;EM&gt;CreateFolder&lt;/EM&gt; geoprocessing tool.&lt;/P&gt;&lt;P&gt;and that would work quite nicely.&lt;/P&gt;&lt;P&gt;But you can also achieve the same thing&amp;nbsp; through ModelBuilder. You would need to:&lt;/P&gt;&lt;P&gt;1: Use the &lt;STRONG&gt;Iterate Feature Selection&lt;/STRONG&gt; iterator. For the &lt;EM&gt;In Features&lt;/EM&gt; parameter you should choose the dataset which contains the selected records whose attributes will be used to create the folders from.&lt;/P&gt;&lt;P&gt;2: Add the &lt;STRONG&gt;Get Field Value&lt;/STRONG&gt; utility tool to&amp;nbsp; the model and connect the &lt;EM&gt;Selected Features&lt;/EM&gt; output of the iterator to the &lt;EM&gt;Input Table&lt;/EM&gt; parameter of &lt;EM&gt;Get Field Value&lt;/EM&gt;. You also need to specify&amp;nbsp; the attribute field of your feature layer as the &lt;EM&gt;Field&lt;/EM&gt; parameter of the &lt;EM&gt;Get Field Value&lt;/EM&gt; utility tool.&lt;/P&gt;&lt;P&gt;3: Add the &lt;STRONG&gt;Create Folder&lt;/STRONG&gt; tool.&lt;/P&gt;&lt;P&gt;4: Connect the output of &lt;EM&gt;Get Field Value&lt;/EM&gt; to the &lt;STRONG&gt;Create Folder&lt;/STRONG&gt; tool specifying the&lt;EM&gt; Folder Name&lt;/EM&gt; parameter. You also need to select the &lt;EM&gt;output folder&lt;/EM&gt; as a parameter for the &lt;EM&gt;Create Folder&lt;/EM&gt; tool.&lt;/P&gt;&lt;P&gt;The final model should look like the one supplied..... It took me about 5 minutes to make this. Hope it helps you out! thanks ed&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="CreateFolder.PNG" style="width: 842px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/91683i192E0B0E4D4F1B90/image-size/large?v=v2&amp;amp;px=999" role="button" title="CreateFolder.PNG" alt="CreateFolder.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jan 2024 13:27:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370443#M77441</guid>
      <dc:creator>EdM</dc:creator>
      <dc:date>2024-01-16T13:27:04Z</dc:date>
    </item>
    <item>
      <title>Re: Create Windows folders based on attribute value of polygon</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370478#M77443</link>
      <description>&lt;P&gt;You hero!&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you so much for this, it's massively helpful and has worked a treat. I've utilised the ModelBuilder approach as I know how to work with that straight away and I added in "Select Layer by Attribute" prior to the "Iterate" function to enable me to strip down the dataset slightly when needed. Really appreciate your time in getting back to me with a solution Ed. Many thanks&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jan 2024 15:00:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/create-windows-folders-based-on-attribute-value-of/m-p/1370478#M77443</guid>
      <dc:creator>James_Shreeve</dc:creator>
      <dc:date>2024-01-16T15:00:50Z</dc:date>
    </item>
  </channel>
</rss>

