<?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 Export dialog path in Fusion API and Scripts Forum</title>
    <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7256064#M17773</link>
    <description>&lt;P&gt;Hiya all!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm new to the Fusion 360 api, but I was hoping to change some of the default properties on the Export dialog (specifically the "Save to my computer..." path).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems like I should be able to catch the export command somewhere, and then modify the command inputs, but I haven't worked out a way to do that (I tried adding my own CommandStarting handler, but couldn't find a way to get/modify inputs in there).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any suggestions would be helpful!&lt;/P&gt;&lt;P&gt;(Fallback is to create my own export dialog, but I'd rather not...)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Geoff&lt;/P&gt;</description>
    <pubDate>Wed, 26 Jul 2017 16:27:57 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-07-26T16:27:57Z</dc:date>
    <item>
      <title>Export dialog path</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7256064#M17773</link>
      <description>&lt;P&gt;Hiya all!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm new to the Fusion 360 api, but I was hoping to change some of the default properties on the Export dialog (specifically the "Save to my computer..." path).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems like I should be able to catch the export command somewhere, and then modify the command inputs, but I haven't worked out a way to do that (I tried adding my own CommandStarting handler, but couldn't find a way to get/modify inputs in there).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any suggestions would be helpful!&lt;/P&gt;&lt;P&gt;(Fallback is to create my own export dialog, but I'd rather not...)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Geoff&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jul 2017 16:27:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7256064#M17773</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-07-26T16:27:57Z</dc:date>
    </item>
    <item>
      <title>Re: Export dialog path</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7257573#M17774</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Unfortunately there is no API to support to customize the export dialog. Instead you can create export dialog by yourself and make use of ExportManager to do export.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For example: the following codes show how to show save file dialog and export file as f3d.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;import adsk.core, adsk.fusion, traceback
 
def run(context):
    ui = None
    try:
        app = adsk.core.Application.get()
        ui = app.userInterface
        
        filedlg = ui.createFileDialog()
        filedlg.initialDirectory = '/Users/tum/Downloads/'
        filedlg.filter = '*.f3d'
        if filedlg.showSave() == adsk.core.DialogResults.DialogOK:
            design = adsk.fusion.Design.cast(app.activeProduct) 
            option = design.exportManager.createFusionArchiveExportOptions(filedlg.filename, design.rootComponent)
            design.exportManager.execute(option)
 
    except:
        if ui:
            ui.messageBox('Failed:\n{}'.format(traceback.format_exc()))&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Marshal&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2017 07:15:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7257573#M17774</guid>
      <dc:creator>marshaltu</dc:creator>
      <dc:date>2017-07-27T07:15:36Z</dc:date>
    </item>
    <item>
      <title>Re: Export dialog path</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7258881#M17775</link>
      <description>&lt;P&gt;Ah, well that makes sense, thank you!&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jul 2017 16:29:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/export-dialog-path/m-p/7258881#M17775</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-07-27T16:29:23Z</dc:date>
    </item>
  </channel>
</rss>

