<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Efficy Overflow Q&amp;A - Recent questions tagged folder</title>
<link>https://overflow.efficy.io/?qa=tag/folder</link>
<description>Powered by Question2Answer</description>
<item>
<title>Permission denied when creatng new folder on network share</title>
<link>https://overflow.efficy.io/?qa=2621/permission-denied-when-creatng-new-folder-on-network-share</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;I'm trying to create some folder structure on network share. Access is ok, and i can create folders manually with no problem from Efficy server.&lt;/p&gt;

&lt;p&gt;I tested this script using SchedulerAdmin, and it works perfectly&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;function CreateSubfoldersDE(EditHandle){
    var docuDS = Database.GetMasterDataSet(EditHandle, 0);
    var docuRef = docuDS.FieldByName(&quot;REFERENCE&quot;).AsString;
    var subFolders = Database.GetSysStorageValue(&quot;DeSubFolders&quot;).split(&quot;;&quot;); //Folder1;Folder2;Folder3
    var rootFolder = Database.GetSysStorageValue(&quot;DeRootFolder&quot;);// \\servername\Puplic$\1- Projects\TestEfficyCrmIntegration
    var folderObject = new ActiveXObject(&quot;Scripting.FileSystemObject&quot;);
    var path = rootFolder + &quot;\\&quot; + docuRef;
    if(!folderObject.FolderExists(path)){
        folderObject.CreateFolder (path)
        for(var i = 0 ; i &amp;lt; subFolders.length; i++){
            var subFodlerFullPath = path + &quot;\\&quot; + subFolders[i];
            folderObject.CreateFolder (subFodlerFullPath);
        }
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;But when i try to do it from workflow (call the same function on AfterCommitDocu) i go error &quot;Permission Denied&quot; like in teh screenshot, indication to line of first fodler to create &quot;folderObject.CreateFolder (path)&quot;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;https://overflow.efficy.com/?qa=blob&amp;amp;qa_blobid=12232836409994913310&quot; alt=&quot;enter image description here&quot;&gt;&lt;/p&gt;

&lt;p&gt;I've doubled check to make sure the user that's running COM+ is the same one that has access to that folder. it's a domain user.&lt;/p&gt;

&lt;p&gt;Please advise.&lt;br&gt;
Thank you in advance for help.&lt;br&gt;
Best Regards.&lt;/p&gt;
</description>
<category>WorkFlow / Serverscript</category>
<guid isPermaLink="true">https://overflow.efficy.io/?qa=2621/permission-denied-when-creatng-new-folder-on-network-share</guid>
<pubDate>Mon, 17 Jul 2017 10:39:41 +0000</pubDate>
</item>
</channel>
</rss>