Check for Existence of a Variable in MEL
June 16th, 2011Error-catching in MEL with the catch command won’t catch a “variable does not exist” error, so use whatIs instead:
if (`whatIs "$test"` == "Unknown") {
print "yes";
} else {
print "no";
}
There ya go.
« previously: Thursday | Home | next: MakerBot construction timelapse »
August 24th, 2011 at 6:19 pm
here is one for you: http://www.youtube.com/watch?v=fElE-LFep9w
August 24th, 2011 at 8:25 pm
Lovely. Thanks!