Perspective View Parameter as Message Handler Type

I feel like you should be able to reference a View-level Parameter or Custom attribute as the Message Type when setting up the message handler for onMessageRecieved.

I’ve tried view.custom.returnMessageId and parent.view.custom.returnMessageId
as Custom attributes and Params, with and without the curly braces.

Having this custom attribute works fine for passing it into the system.perspective.openPopup call. The popup view receives it as a parameter and is able to use it as a reference when sending a message back to the calling view. I would have thought it should have worked the same way when setting up the message handler on the receiving side.

Any thoughts on this?
Thanks.

try self.view.custom.returnMessageId?

Though I’m not sure you can set up a dynamic message handler type. What is the intended use case for this, I’m a bit curious.

That was a good try, thanks Ryan. Unfortunately it didn’t work either. I sort of lean toward enclosing it with curly braces as the right answer, but that depends on if the developers evaluate the input as an expression. So far, that doesn’t look like the case.

So I like creating individual views as a library of templates in a way.
For reusability, we already assign the first half of the root path to a view parameter, so why not the messaging handler type. Sounded good anyway. Lol