Is there a list of the possible values that can be returned from the FeatureType property of a Features.Feature?
It seems strange that the only way I can get these values is by creating a feature and then writing a journal to return the FeatureType for each feature I have created. As a follow on question, is the list broken down by the different sub types (i.e. Features.BodyFeature, Features.CurveFeature, etc...)
(Version NX 8)
Solved! Go to Solution.
VB .Net is the language I am using.
I saw the list before but I wasn't confident that the name listed in the hierarchy is the name that is returned from featuretype, at the very least featuretype returns a string that is all caps and the list is not all caps, if thats the only difference I can live with that. I guess I just need to do some test cases.
For testing a feature's type, I prefer to use the TypeOf operator. This operator uses the class name, so you can use what is listed in the inheritance hierarchy. The .FeatureType property returns a string value that sometimes matches the class name but often does not. I've always wondered if it returns the same english value in a non-english version of NX or if it returns a value in the current language. If it does not return the english string value, your code would not work on installs using a different language.
If TypeOf(someFeature) Is DatumCsys then 'code for datum csys feature End If