Change data of message box in locked patch

Jan 1, 2013 at 10:48pm

Change data of message box in locked patch

Hello,

I need a message box that’s data can be changed without unlocking the patch and that remembers its last data after saving. I thought of a solution with a [textedit] sending to a message box’s right inlet through some gate system. Unfortunately the system isn’t predictable and I cannot figure out if the problem is with [textedit]‘s initialization (I don’t see a system why textedit sometimes keeps its last content after saving-reopening and sometimes not) with the gate’s particularities (indeed logically gate and gswitch1 and 2 should react the same way and the don’t) or some other thing.
all suggestions welcome!
toscanini

– Pasted Max Patch, click to expand. –
#65876
Jan 1, 2013 at 11:23pm

Use the prepend object, not sure why you need the gate.

– Pasted Max Patch, click to expand. –
#237226
Jan 1, 2013 at 11:36pm
– Pasted Max Patch, click to expand. –
#237227
Jan 2, 2013 at 7:38am

Hi,

An idea, that must be improved to manage special characters.

– Pasted Max Patch, click to expand. –
#237228
Jan 2, 2013 at 9:45am

Thank you for the answers, unfortunately none of the solutions pass the test of saving – closing – reopening the patch. As I reopen the message box is empty. @Rick, the idea of the gate was to make sure nothing passes in the right inlet of the message box at initialization.
I keep experiencing an adventurous behavior in the textedit: no idea why it would discard data at reopening or keep some old one over many savings/reopenings. So I did like the idea of not even using textedit but in nicolas’ patch the message box still blanks out.
Maybe Rick’s patch with textedit reinforced with a pattr will work, but it is a bit of an overkill.
fwiw I use M4L so maybe all this is perfectly predictable with the max standalone version, but that would be weird…

#237229
Jan 2, 2013 at 10:33am

When using [textedit] in M4L you need to connect a [pattr] with parameter mode enabled.
This way it remembers the last data after saving the Live set.

#237230
Jan 2, 2013 at 10:55am

Hi,

It just need to remove the [loadmess \] ;-)

– Pasted Max Patch, click to expand. –
#237231
Jan 2, 2013 at 2:35pm

Hi,

Slightly improved :

– Pasted Max Patch, click to expand. –
#237232
Jan 2, 2013 at 3:25pm

Thank you for the new messages. @Nicolas, I really dig your method without [textedit] but the message content still changes as I reopen the patch. And [message] won’t accept a pattr bindto connection.
@broc, yes, I was thinking of that but even the version with [pattr] bindto the problem subsists. Comparing to Rick’s solution I have even removed the [loadbang] to make sure the message box won’t overwrite the textedit content, and it still doesn’t work. I am a bit clueless. Here is my last attempt and a short illustration video.

– Pasted Max Patch, click to expand. –

http://youtu.be/jKS8lGMfwiU

#237233
Jan 2, 2013 at 4:03pm

You simply forgot to enable parameter mode of pattr.
Here is the corrected version which works for me.

– Pasted Max Patch, click to expand. –
#237234
Jan 2, 2013 at 4:59pm

Hi,

@carloskleiber : strange ; it works fine for me (max 5.1.9)…

#237235
Jan 2, 2013 at 5:28pm

Bingo! Thank you guys. I always remember checking the “parameter enable” box for the [pattrstorage] but obviously overlooked that the same mode also exited for [pattr]
I cannot imagine how many older patches this new knowledge will fix for me :P

#237236

You must be logged in to reply to this topic.