splitting commer seperated values

This is where you talk about Macros, show examples of your macro scripting and SHARE handy segments of script code as examples.

splitting commer seperated values

Postby Battwell » Mon Aug 05, 2024 6:46 am

i found this example online. trying to seperate the numbers out.
obviously doesnt work :-)
any help?



string values = "0,1,2,3,4,5,6,7,8,9";

foreach(string value in values.split(','))
{
//do something with individual value
exec.AddStatusmessage("TOOL # "+ value);
}
Uc300eth on router and mill.
UK uccnc powered machine sales. https://cncrouter.uk/atc-cnc-routers.htm
Automateanything/duzzit cnc/mercury cnc
Battwell
 
Posts: 855
Joined: Sun Sep 25, 2016 7:39 pm
Location: South Wales. Uk

Re: splitting commer seperated values

Postby Battwell » Mon Aug 05, 2024 6:48 am

actual line type will be

t6,t8,t9,t4,t3
Uc300eth on router and mill.
UK uccnc powered machine sales. https://cncrouter.uk/atc-cnc-routers.htm
Automateanything/duzzit cnc/mercury cnc
Battwell
 
Posts: 855
Joined: Sun Sep 25, 2016 7:39 pm
Location: South Wales. Uk


Return to Macros

Who is online

Users browsing this forum: No registered users and 7 guests