<?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 Betreff: Macro NEED HELP! in PowerMill Forum</title>
    <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576901#M2203</link>
    <description>Unfortunately, it doesn't work. The toolpath is not renamed.&lt;BR /&gt;&lt;BR /&gt;thanks for the help</description>
    <pubDate>Thu, 22 Feb 2024 18:55:04 GMT</pubDate>
    <dc:creator>nlegareLUZKA</dc:creator>
    <dc:date>2024-02-22T18:55:04Z</dc:date>
    <item>
      <title>Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576270#M2201</link>
      <description>&lt;PRE&gt;&lt;SPAN class=""&gt;HELLO EVERYONE&lt;BR /&gt;I WOULD LIKE TO ADD A CONDITION TO MY MACRO 'CHECK_COLLISION'(SEE ATTACHMENT)&lt;BR /&gt;AND I DON'T KNOW HOW TO DO IT SO I WILL NEED YOUR HELP.&lt;BR /&gt;HERE IS THE CONDITION. &lt;BR /&gt;I WOULD LIKE, IF A COLLISION IS DETECTED, THAT THE PROBLEMATIC TOOLPATH BE RENAMMED &lt;BR /&gt;'TOOLPATH NAME + _COLLISION' WITHOUT THE MACRO BEING STOPPED. &lt;BR /&gt;&lt;BR /&gt;THANK YOU FOR YOUR HELP AND TIME. IT IS REALLY APPRECIATED!&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Feb 2024 15:03:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576270#M2201</guid>
      <dc:creator>nlegareLUZKA</dc:creator>
      <dc:date>2024-02-22T15:03:46Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576479#M2202</link>
      <description>&lt;P&gt;try this:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;FOREACH tp IN folder('Toolpath') {

	IF NOT tp.Computed {

		ACTIVATE TOOLPATH $tp.Name

		EDIT TOOLPATH $tp.Name CALCULATE
	}

}



FOREACH tp IN folder('Toolpath') {

	ACTIVATE TOOLPATH $tp.Name

	ACTIVATE StockModel "P#01 - STM_Blank milling_1"

	EDIT COLLISION TYPE COLLISION

	EDIT COLLISION STOCKMODEL_CHECK Y

	EDIT COLLISION STOCKMODEL  "P#01 - STM_Blank milling"

	EDIT COLLISION SCOPE ALL

	EDIT COLLISION SPLIT_TOOLPATH N

	EDIT COLLISION MISS_OUTPUT N

	EDIT PAR 'Verification.UseVerificationThickness' 0

	EDIT COLLISION HEAD_CLEARANCE "600.0"

	EDIT COLLISION HOLDER_CLEARANCE "1.0"

	EDIT COLLISION SHANK_CLEARANCE "0.3"

	EDIT COLLISION DEPTH Y

	EDIT COLLISION ADJUST_TOOL N

	UNDRAW COLLISION

	EDIT COLLISION APPLY

	EDIT STOCKMODEL ; INSERT_INPUT TOOLPATH $tp.Name LAST

	EDIT STOCKMODEL "P#01 - STM_Blank milling_1" CALCULATE
	
	if Safety.Holder.Cutting.Status == 'collides' or Safety.Holder.Leads.Status == 'collides' or Safety.Holder.Links.Status == 'collides' or Safety.Tool.Cutting.Status == 'collides' or Safety.Tool.Leads.Status == 'collides' or Safety.Tool.Links.Status == 'collides' {
		
		string $newName = $tp.Name + "_COLLISION"
		if entity_exists('toolpath',$newName) {
			$newName = new_entity_name('toolpath',$newName)
		}
		RENAME Toolpath ; ${newName}
	}

}	



DIALOGS MESSAGE ON

DIALOGS ERROR ON

GRAPHICS UNLOCK&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;did not tested it...&lt;/P&gt;</description>
      <pubDate>Thu, 22 Feb 2024 16:15:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576479#M2202</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-22T16:15:43Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576901#M2203</link>
      <description>Unfortunately, it doesn't work. The toolpath is not renamed.&lt;BR /&gt;&lt;BR /&gt;thanks for the help</description>
      <pubDate>Thu, 22 Feb 2024 18:55:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576901#M2203</guid>
      <dc:creator>nlegareLUZKA</dc:creator>
      <dc:date>2024-02-22T18:55:04Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576980#M2204</link>
      <description>&lt;P&gt;Sorry i'm not at my pc ill check it tomorrow.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Feb 2024 19:40:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12576980#M2204</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-22T19:40:55Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12577820#M2205</link>
      <description>&lt;P&gt;this should work&lt;/P&gt;&lt;LI-CODE lang="general"&gt;FOREACH tp IN folder('Toolpath') {

	IF NOT tp.Computed {

		ACTIVATE TOOLPATH $tp.Name

		EDIT TOOLPATH $tp.Name CALCULATE
	}

}



FOREACH tp IN folder('Toolpath') {

	ACTIVATE TOOLPATH $tp.Name

	ACTIVATE StockModel "P#01 - STM_Blank milling_1"

	EDIT COLLISION TYPE COLLISION

	EDIT COLLISION STOCKMODEL_CHECK Y

	EDIT COLLISION STOCKMODEL  "P#01 - STM_Blank milling"

	EDIT COLLISION SCOPE ALL

	EDIT COLLISION SPLIT_TOOLPATH N

	EDIT COLLISION MISS_OUTPUT N

	EDIT PAR 'Verification.UseVerificationThickness' 0

	EDIT COLLISION HEAD_CLEARANCE "600.0"

	EDIT COLLISION HOLDER_CLEARANCE "1.0"

	EDIT COLLISION SHANK_CLEARANCE "0.3"

	EDIT COLLISION DEPTH Y

	EDIT COLLISION ADJUST_TOOL N

	UNDRAW COLLISION

	EDIT COLLISION APPLY

	EDIT STOCKMODEL ; INSERT_INPUT TOOLPATH $tp.Name LAST

	EDIT STOCKMODEL "P#01 - STM_Blank milling_1" CALCULATE
	
	if $tp.Safety.Holder.Cutting.Status == 'collides' or $tp.Safety.Holder.Leads.Status == 'collides' or $tp.Safety.Holder.Links.Status == 'collides' or $tp.Safety.Tool.Cutting.Status == 'collides' or $tp.Safety.Tool.Leads.Status == 'collides' or $tp.Safety.Tool.Links.Status == 'collides' {
		
		string $newName = $tp.Name + "_COLLISION"
		if entity_exists('toolpath',$newName) {
			$newName = new_entity_name('toolpath',$newName)
		}
		RENAME Toolpath ${tp.Name} ${newName}
	}

}	



DIALOGS MESSAGE ON

DIALOGS ERROR ON

GRAPHICS UNLOCK&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 23 Feb 2024 07:19:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12577820#M2205</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-23T07:19:16Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12578974#M2206</link>
      <description>It still does not work...</description>
      <pubDate>Fri, 23 Feb 2024 16:51:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12578974#M2206</guid>
      <dc:creator>nlegareLUZKA</dc:creator>
      <dc:date>2024-02-23T16:51:02Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12579068#M2207</link>
      <description>&lt;P&gt;Can you explain the problem a bit more.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does the macro stop at a certain point?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I just tested the renaming part ive added.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Feb 2024 17:26:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12579068#M2207</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-23T17:26:49Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12579077#M2208</link>
      <description>the macro does not stop but the problematic toolpath is not renamed.</description>
      <pubDate>Fri, 23 Feb 2024 17:30:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12579077#M2208</guid>
      <dc:creator>nlegareLUZKA</dc:creator>
      <dc:date>2024-02-23T17:30:27Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12582475#M2209</link>
      <description>&lt;P&gt;For me the code of my last post works fine...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;here with all collision checking removed:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;foreach $tp in filter(folder('toolpath'),'this.RootType == "toolpath"') {
	if $tp.Safety.Holder.Cutting.Status == 'collides' or $tp.Safety.Holder.Leads.Status == 'collides' or $tp.Safety.Holder.Links.Status == 'collides' or $tp.Safety.Tool.Cutting.Status == 'collides' or $tp.Safety.Tool.Leads.Status == 'collides' or $tp.Safety.Tool.Links.Status == 'collides' {
		
		string $newName = $tp.Name + "_COLLISION"
		if entity_exists('toolpath',$newName) {
			$newName = new_entity_name('toolpath',$newName)
		}
		RENAME Toolpath ${tp.Name} ${newName}
	}
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Feb 2024 07:24:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12582475#M2209</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-26T07:24:41Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12585388#M2210</link>
      <description>&lt;PRE&gt;&lt;SPAN class=""&gt;Here is the macro rewritten as I think I understood it.&lt;BR /&gt;Did I make a mistake? Am I forgetting something?&lt;BR /&gt;It's still the same result. It is read to the end without problem,&lt;BR /&gt;but the toolpath which is in collision is still not renamed.

Thanks again for your help. It is more than appreciated.&lt;/SPAN&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 27 Feb 2024 11:36:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12585388#M2210</guid>
      <dc:creator>nlegareLUZKA</dc:creator>
      <dc:date>2024-02-27T11:36:28Z</dc:date>
    </item>
    <item>
      <title>Betreff: Macro NEED HELP!</title>
      <link>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12585671#M2211</link>
      <description>&lt;P&gt;try running only this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;foreach $tp in filter(folder('toolpath'),'this.RootType == "toolpath"') {
	if $tp.Safety.Holder.Cutting.Status == 'collides' or $tp.Safety.Holder.Leads.Status == 'collides' or $tp.Safety.Holder.Links.Status == 'collides' or $tp.Safety.Tool.Cutting.Status == 'collides' or $tp.Safety.Tool.Leads.Status == 'collides' or $tp.Safety.Tool.Links.Status == 'collides' {
		
		string $newName = $tp.Name + "_COLLISION"
		if entity_exists('toolpath',$newName) {
			$newName = new_entity_name('toolpath',$newName)
		}
		RENAME Toolpath ${tp.Name} ${newName}
	}
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i just added my code at the end of your macro&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if this works heres the complere macro:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;DIALOGS MESSAGE OFF

DIALOGS ERROR OFF

GRAPHICS LOCK

	

		

		FOREACH tp IN folder('Toolpath') {

		IF NOT tp.Computed {

		ACTIVATE TOOLPATH $tp.Name

		EDIT TOOLPATH $tp.Name CALCULATE

		}

}



		FOREACH tp IN folder('Toolpath') {

		ACTIVATE TOOLPATH $tp.Name

		ACTIVATE StockModel "P#01 - STM_Blank milling_1"

		EDIT COLLISION TYPE COLLISION

		EDIT COLLISION STOCKMODEL_CHECK Y

		EDIT COLLISION STOCKMODEL  "P#01 - STM_Blank milling"

		EDIT COLLISION SCOPE ALL

		EDIT COLLISION SPLIT_TOOLPATH N

		EDIT COLLISION MISS_OUTPUT N

		EDIT PAR 'Verification.UseVerificationThickness' 0

		EDIT COLLISION HEAD_CLEARANCE "600.0"

		EDIT COLLISION HOLDER_CLEARANCE "1.0"

		EDIT COLLISION SHANK_CLEARANCE "0.3"

		EDIT COLLISION DEPTH Y

		EDIT COLLISION ADJUST_TOOL N

		UNDRAW COLLISION

		EDIT COLLISION APPLY

		EDIT STOCKMODEL ; INSERT_INPUT TOOLPATH $tp.Name LAST

		EDIT STOCKMODEL "P#01 - STM_Blank milling_1" CALCULATE

}	

foreach $tp in filter(folder('toolpath'),'this.RootType == "toolpath"') {
	if $tp.Safety.Holder.Cutting.Status == 'collides' or $tp.Safety.Holder.Leads.Status == 'collides' or $tp.Safety.Holder.Links.Status == 'collides' or $tp.Safety.Tool.Cutting.Status == 'collides' or $tp.Safety.Tool.Leads.Status == 'collides' or $tp.Safety.Tool.Links.Status == 'collides' {
		
		string $newName = $tp.Name + "_COLLISION"
		if entity_exists('toolpath',$newName) {
			$newName = new_entity_name('toolpath',$newName)
		}
		RENAME Toolpath ${tp.Name} ${newName}
	}
}

DIALOGS MESSAGE ON

DIALOGS ERROR ON

GRAPHICS UNLOCK&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Feb 2024 14:19:03 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/powermill-forum/macro-need-help/m-p/12585671#M2211</guid>
      <dc:creator>icse</dc:creator>
      <dc:date>2024-02-27T14:19:03Z</dc:date>
    </item>
  </channel>
</rss>

