<?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: ArcPy-Import Toolbox question in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/arcpy-import-toolbox-question/m-p/363618#M28764</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;are these multiple attempts packed into one?&amp;nbsp; Where is the script that you are using to import the toolbox?&amp;nbsp; Is it assigned to a tool in arctoolbox?&amp;nbsp; Do you have a toolbox created in arctoolbox and do you have the model and the other tools included in it?&lt;/P&gt;&lt;P&gt;Some elaboration and screenshots of what you have would be useful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 28 Dec 2017 21:51:24 GMT</pubDate>
    <dc:creator>DanPatterson_Retired</dc:creator>
    <dc:date>2017-12-28T21:51:24Z</dc:date>
    <item>
      <title>ArcPy-Import Toolbox question</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-import-toolbox-question/m-p/363617#M28763</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Newbie here. Since ModelBuilder does not have a task scheduler, I thought I would write a simple script in python to call that model and then add a task scheduler to that. Could someone give me a hand, not sure what the error message means below. Am thinking I need to set an alias for my tool name, but not sure how that is done. Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt;&amp;gt;&amp;gt; import arcpy&lt;BR /&gt;&amp;gt;&amp;gt;&amp;gt; arcpy.ImportToolbox(r"L:\D\W\GIS\Users\AAA\Models\Andys Toolbox.tbx", 1FumView)&lt;BR /&gt;Parsing error SyntaxError: invalid syntax (line 1)&lt;BR /&gt;&amp;gt;&amp;gt;&amp;gt;&amp;nbsp;&lt;SPAN&gt;arcpy.ImportToolbox(r"L:\&lt;/SPAN&gt;&lt;SPAN&gt;D&lt;/SPAN&gt;&lt;SPAN&gt;\&lt;/SPAN&gt;&lt;SPAN&gt;W&lt;/SPAN&gt;&lt;SPAN&gt;\GIS\Users\&lt;/SPAN&gt;&lt;SPAN&gt;AAA&lt;/SPAN&gt;&lt;SPAN&gt;\Models\Andys Toolbox.tbx", "1FumView")&lt;/SPAN&gt;&lt;BR /&gt;Runtime error &lt;BR /&gt;Traceback (most recent call last):&lt;BR /&gt; File "&amp;lt;string&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;BR /&gt; File "c:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\__init__.py", line 124, in ImportToolbox&lt;BR /&gt; return import_toolbox(input_file, module_name)&lt;BR /&gt; File "c:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\toolbox_code.py", line 440, in import_toolbox&lt;BR /&gt; mymodule = generate_toolbox_module(toolbox, None, False, False, False, module_name, use_alt_alias)&lt;BR /&gt; File "c:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\toolbox_code.py", line 414, in generate_toolbox_module&lt;BR /&gt; 'exec')&lt;BR /&gt; File "L:\SharedData\Denver\Wattenberg\GIS\Users\AndyBohnhoff\Models\Andys Toolbox.tbx", line 11&lt;BR /&gt; def 1FnumView():&lt;BR /&gt; ^&lt;BR /&gt;SyntaxError: invalid syntax&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Dec 2017 19:22:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-import-toolbox-question/m-p/363617#M28763</guid>
      <dc:creator>AndyBohnhoff</dc:creator>
      <dc:date>2017-12-28T19:22:30Z</dc:date>
    </item>
    <item>
      <title>Re: ArcPy-Import Toolbox question</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-import-toolbox-question/m-p/363618#M28764</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;are these multiple attempts packed into one?&amp;nbsp; Where is the script that you are using to import the toolbox?&amp;nbsp; Is it assigned to a tool in arctoolbox?&amp;nbsp; Do you have a toolbox created in arctoolbox and do you have the model and the other tools included in it?&lt;/P&gt;&lt;P&gt;Some elaboration and screenshots of what you have would be useful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Dec 2017 21:51:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-import-toolbox-question/m-p/363618#M28764</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-12-28T21:51:24Z</dc:date>
    </item>
  </channel>
</rss>

