<?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: mxd.saveACopy - doesn't save appended Toolboxes in Mapping Questions</title>
    <link>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676013#M7273</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Cosmin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm not sure I completely understand the workflow, you please confirm or clarify the following:&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- You open an MXD (in the ArcMap application).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- Next you add some script tools to the Catalog Window (but you mention ArcCatalog, not Catalog Window) - I'm not sure what you mean by append.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- you do a saveACopy (to a different mxd)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- then you close the ArcMap application,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- reopen the same MXD and the toolbox is not available.&amp;nbsp; I.e., you must add it again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Question: if you do the same thing with File--&amp;gt;SaveACopy, do you get the same behavior?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Jeff&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 10 Jan 2011 14:52:23 GMT</pubDate>
    <dc:creator>JeffBarrette</dc:creator>
    <dc:date>2011-01-10T14:52:23Z</dc:date>
    <item>
      <title>mxd.saveACopy - doesn't save appended Toolboxes</title>
      <link>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676012#M7272</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Out of a toolbox, I run multiple scripts (in a certain row), one saves at the end the modified .mxd via&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;mxd.saveACopy("D:\\Filepath\\filename.mxd")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;into a new "Copy" ( and opens it afterwards).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have to open that new mxd for further modification (using the scripts in the same toolbox).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This must be done several times...so it's is quite annoying if I have to append the toolbox every time..&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem is, this toolbox is NOT saved in that .mxd, so I have to append that toolbox again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That means: mxd.saveACopy() does not save that toolbox in the copied project file (.mxd) - at least in my cases.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My Question is: what can I try that it might be included in the new"Copy"?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this maybe a bug?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have ArcGIS 10 SP1 installed.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help is appreciated.Thanks.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;some more information:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The the original .mxd was created before the toolbox was appended to ArcCatalog, anyway the Toolbox IS appended in that .mxd (probably by hand.. back then- before I appended it to ArcCatalog)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;btw:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;mxd.saveACopy() works fine from the python window, from appended scripts (using "Current" and absolute paths) the only problem i have is: my toolbox is not saved within the .mxd....&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 09 Jan 2011 18:50:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676012#M7272</guid>
      <dc:creator>CosminTana</dc:creator>
      <dc:date>2011-01-09T18:50:57Z</dc:date>
    </item>
    <item>
      <title>Re: mxd.saveACopy - doesn't save appended Toolboxes</title>
      <link>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676013#M7273</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Cosmin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm not sure I completely understand the workflow, you please confirm or clarify the following:&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- You open an MXD (in the ArcMap application).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- Next you add some script tools to the Catalog Window (but you mention ArcCatalog, not Catalog Window) - I'm not sure what you mean by append.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- you do a saveACopy (to a different mxd)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- then you close the ArcMap application,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- reopen the same MXD and the toolbox is not available.&amp;nbsp; I.e., you must add it again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Question: if you do the same thing with File--&amp;gt;SaveACopy, do you get the same behavior?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Jeff&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Jan 2011 14:52:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676013#M7273</guid>
      <dc:creator>JeffBarrette</dc:creator>
      <dc:date>2011-01-10T14:52:23Z</dc:date>
    </item>
    <item>
      <title>Re: mxd.saveACopy - doesn't save appended Toolboxes</title>
      <link>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676014#M7274</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Jeff,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;with "appended" I meant, the toolbox is added to the project (.mxd) as well as in ArcCatalog.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Since it is also added to ArcCatalog, I think this toolbox is included by default to every new project that will be created (=blank mxd).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I save a Copy manually (via File-&amp;gt;Save a Copy) everything is fine (my customized toolbox is included in the copy) &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I use mxd.saveACopy() from within the pythonwindow in ArcMap, my toolxbox is still there.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Untill Yesterday I had a script in the toolbox which referenced the mxd via ('Current').&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In order to save time (not opening and closing that original mxd) I now run that script from ArcCatalog and it now references the original mxd via the filepath.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;BUT the problem remains, the toolbox is not included in the Copy.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My Workflow at the moment is:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-Start a script from the toolbox in ArcCatalog.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Basically this script just replaces some datasources according to the parameters. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; (workflow for one layer: 1. RemoveLayer 2.replaceDataSource 3. InserLayer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; since ReplaceDataSource makes them disappear if used alone)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Anyway, it works fine now.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- at the end it saves the modified mxd via mxd.saveACopy()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- at the very last it starts that copy via os.starfile()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- next stept would be to run other scripts from that toolbox but I now have to re-add the toolbox first (the toolbox is definitely added to the original mxd)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope it is a bit clearer now.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am wondering if this is a problem with my particular mxd or maybe the functions saveACopy() (called from a script) only saves the "system toolboxes".&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for your help.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Cosmin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Jan 2011 15:49:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676014#M7274</guid>
      <dc:creator>CosminTana</dc:creator>
      <dc:date>2011-01-10T15:49:42Z</dc:date>
    </item>
    <item>
      <title>Re: mxd.saveACopy - doesn't save appended Toolboxes</title>
      <link>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676015#M7275</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;update:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;a script which does just: saveACopy() works fine- on this mxd and on others.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;So there is rather a problem with my script than with the settings or with the mxd...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Jan 2011 20:24:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/mxd-saveacopy-doesn-t-save-appended-toolboxes/m-p/676015#M7275</guid>
      <dc:creator>CosminTana</dc:creator>
      <dc:date>2011-01-10T20:24:00Z</dc:date>
    </item>
  </channel>
</rss>

