object_error_obtrusive

Oct 15, 2010 at 7:53am

object_error_obtrusive

Hi.

I have very good reason to use object_error_obtrusive(), but I can’t get it working. It’s in the (very simple) instance creation method of a MSP object. It prints the error to the Max window, but the yellow bar on top of the patcher window doesn’t appear… any hints?

thank you

aa

#52766
Oct 15, 2010 at 9:42pm

It works like a charm here:

object_error_obtrusive((t_object *)x, "toto");

tested by adding that somewhere in simplemax.

#189648
Oct 16, 2010 at 6:58am

hi Emmanuel.
In fact, I have used it successfully in a non-MSP object.
I was wondering if perhaps it doesn’t work in MSP objects…
Thank you!
aa

#189649
Oct 16, 2010 at 4:28pm

You’re not trying to trigger it from the perform method, are you?

#189650
Oct 16, 2010 at 7:18pm

of course not!!!
I’m calling it from the instance creation method
aa

#189651
Oct 16, 2010 at 8:40pm

Hmmm…The object might need to have been instantiated first, and be valid in the patcher to actually work. So you might need to defer this (and/or actually create the object rather than returning NULL from your constructor).

#189652
Oct 17, 2010 at 6:35pm

Thank you, this definitely makes sense.
Cheers
aa

#189653

You must be logged in to reply to this topic.