Community
PowerMill Forum
Welcome to Autodesk’s PowerMill Forums. Share your knowledge, ask questions, and explore popular PowerMill topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

List of Featuresets

2 REPLIES 2
Reply
Message 1 of 3
RAL6000
387 Views, 2 Replies

List of Featuresets

Hey together,

 

Im looking for a Macro solution to get a list of available featureset names.

 

I need that in something like this:

 

STRING $fs_name
IF $fs_name member(%featureset-list%) {
     PRINT "featureset already exists"
} ELSE {
     PRINT "create new featrueset"
}

- - - - - - - - - - - - - - - - - - - - - - - - - -
kind regards Stefan,
Milling robot integrator | Germany
2 REPLIES 2
Message 2 of 3
Anonymous
in reply to: RAL6000

String fset = "1_1"
STRING LIST fsets = extract(folder('featureset'),'name')
INT exists = 0

FOREACH f_set IN $fsets {
	IF fset == f_set {
		$exists = 1
	}
}

IF $exists {
	MESSAGE INFO "Featureset exists"
} ELSE {
	MESSAGE INFO "Featureset not exists"
}

 

Mateusz

Message 3 of 3
RAL6000
in reply to: RAL6000

I got what I want...

 

STRING fsname = "my_feature_set_name"
IF NOT entity_exists(entity('FeatureSet',$fsname)) {
	PRINT "FS dont exists"
} ELSE {
	PRINT "FS exists"
}

- - - - - - - - - - - - - - - - - - - - - - - - - -
kind regards Stefan,
Milling robot integrator | Germany

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report