Forums > MaxMSP

pattrstorage doesnt see scripted objects

May 5, 2006 | 4:15 pm

Hi

I am using pattstorage to save the states and content of objects. However, in my patch the objects are created and named with the script new object message to thispatcher. While pattstorage can see these new objects in the client window, it doesnt register any value changes (or anything at all) for these objects in the client window or in the storage window.
I have noticed that if I close the patch, save it and open it again , then pattstorage sees and registers the behaviour of the previously ‘invisible’ objects…but this is not helpfull in my case really.
I include an attachment as an example (not sure if it’s there or not!).I also include as text a tiny abstraction needed in the patch.
Any help would be great
Thanks

max v2;
#N vpatcher 0 0 1024 702;
#P origin -102 -152;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 173 101 60 9109513 prepend set;
#P outlet 177 130 15 0;
#P inlet 173 71 15 0;
#P user dropfile 159 21 271 58 0;
#P connect 1 0 3 0;
#P connect 0 0 3 0;
#P connect 3 0 2 0;
#P pop;


May 5, 2006 | 5:25 pm

you have to "add" the autopattr object after the creation of new objects!

1. script to erase autopattr

2 script to create new objects

3 script to re-create autopattr.

every time you need to add or remove objects!

it works for me!


May 6, 2006 | 9:22 am

thanks a lot! works for me too…


May 6, 2006 | 10:58 am

actually, there is a difficulty: if I use that method in a patch, it works fine (although I have to refresh the storage window by other means after re-creating the autopattr object). However if I open that patch as an abstraction within another patch, as soon as I create a new object, the client list disappears and stays blank from then on…(?)


May 6, 2006 | 12:58 pm

actually i am pretty sure, that exactly this was fixed by jb in some
update.
anyways the patch below works for me; meaning i can script-create a
number
and its value will be seen from pattrstorage.
best
klaus

#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P message 260 161 217 196617 script new num1 number 425 65 35 9 0 0
0 3;
#N thispatcher;
#Q end;
#P newobj 260 185 61 196617 thispatcher;
#P newex 260 243 53 196617 autopattr;
#P objectname u708000013;
#P newex 259 269 67 196617 pattrstorage;
#X client_rect 50 119 690 359;
#X storage_rect 0 0 640 240;
#P objectname u153000012;
#P connect 3 0 2 0;
#P window clipboard copycount 4;


May 6, 2006 | 2:31 pm

what’s wrong with this one then?
perhaps it’s the update. I am using 4.5.5

max v2;
#N vpatcher 33 33 947 640;
#P origin 73 77;
#P window setfont "Sans Serif" 12.;
#P window linecount 2;
#P comment 813 118 100 9109516 Create and Drop folders here…;
#P comment 642 27 100 9109516 Drop a folder here;
#P window setfont "Sans Serif" 9.;
#P number 140 38 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname staticnumer;
#P window linecount 1;
#P comment 909 197 100 9109513 reset place & names;
#P comment 800 163 100 9109513 scripted drop & text;
#P message 960 217 14 9109513 5;
#P button 862 220 15 0;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 185 80 953 492;
#P origin 0 72;
#P window setfont "Sans Serif" 9.;
#P window linecount 0;
#P comment 479 302 100 9109513 naming;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 292 269 27 9240586 + 1;
#P objectname +;
#P newex 284 241 27 9240586 i;
#P window setfont "Sans Serif" 9.;
#P number 261 200 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[2];
#P window setfont "Fixedwidth Serif" 10.;
#P newex 334 218 50 9240586 del 500;
#P newex 338 196 80 9240586 r $0loadbang;
#P objectname receive;
#P window setfont "Sans Serif" 9.;
#P message 522 95 14 9109513 5;
#P message 617 96 14 9109513 0;
#P window setfont "Fixedwidth Serif" 10.;
#N counter 0 5 1000;
#X flags 0 0;
#P newobj 484 176 103 9240586 counter 0 5 1000;
#P window setfont "Sans Serif" 9.;
#P newex 385 45 129 9109513 autopattr $0sb @autoname 1;
#X prestore number[2] 1 0 9;
#P objectname $0sb[1];
#P window linecount 3;
#P comment 118 146 100 9109513 change 2nd number (40) to change distance between rows;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 1;
#P newex 598 173 113 9240586 s $0soundbankreset;
#P newex 130 276 103 9240586 s $0soundbankexp;
#P newex 482 266 134 9240586 s $0soundbankcounter;
#P newex 115 245 121 9240586 expr ($i1 * 40) +50;
#N counter 0 5 1000;
#X flags 0 0;
#P newobj 259 173 103 9240586 counter 0 5 1000;
#P window setfont "Fixedwidth Serif" 14.;
#P comment 223 145 60 9240590 Add cue;
#P inlet 588 45 15 0;
#P inlet 224 21 15 0;
#P window setfont "Sans Serif" 9.;
#P comment 149 310 100 9109513 window placemnt;
#P connect 4 0 5 0;
#P connect 5 0 7 0;
#P connect 1 0 4 0;
#P connect 4 0 16 0;
#P connect 17 0 18 0;
#P connect 16 0 17 1;
#P connect 13 0 4 2;
#P connect 18 0 4 2;
#P connect 14 0 15 0;
#P connect 11 0 6 0;
#P connect 1 0 11 0;
#P connect 2 0 13 0;
#P connect 12 0 11 2;
#P connect 12 0 8 0;
#P connect 2 0 12 0;
#P pop;
#P newobj 862 239 110 9240586 p soundbankcreate;
#B color 2;
#P objectname soundbankcreate[1];
#N vpatcher 4 27 995 665;
#P origin 0 113;
#P window setfont "Sans Serif" 9.;
#N vpatcher 5 40 877 686;
#P button 299 128 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 294 94 68 9109513 r $0packbang4;
#P newex 385 145 41 9109513 zl reg;
#P newex 422 212 174 9109513 sprintf script hidden connect %s 0 %s 2;
#P inlet 557 56 15 0;
#P inlet 344 51 15 0;
#P outlet 372 514 15 0;
#P connect 5 0 6 0;
#P connect 3 0 0 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 30 367 113 9109513 p connect;
#N vpatcher 5 40 877 686;
#P window setfont "Sans Serif" 9.;
#P newex 108 147 22 9109513 t b;
#P newex 97 105 75 9109513 r $0packbang2;
#P newex 141 174 40 9109513 zl reg;
#P newex 188 241 193 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 383 65 15 0;
#P inlet 171 78 15 0;
#P outlet 182 520 15 0;
#P connect 5 0 6 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 3 0 0 0;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 31 338 113 9109513 p connect;
#N vpatcher 5 40 877 686;
#P button 299 128 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 294 94 75 9109513 r $0packbang2;
#P newex 385 145 41 9109513 zl reg;
#P newex 422 212 189 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 557 56 15 0;
#P inlet 344 51 15 0;
#P outlet 372 514 15 0;
#P connect 5 0 6 0;
#P connect 3 0 0 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 28 295 113 9109513 p connect;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 290 101 971 562;
#P origin 148 39;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 436;
#P objectname u146002014;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u169002016;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 520 213 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 502 82 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 259 37 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 330 114 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P newex 130 309 79 9240586 unpack 0 0 s;
#P newex 24 310 83 9240586 s $0packbang2;
#P outlet 180 367 15 0;
#P message 246 304 323 9240586 script new $3 hidden newex 640 $2 40 9109513 pcontrol;
#P message 279 346 229 9240586 newobj 133 105 44 9109513 p soundbank;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 390 209 103 9240586 counter 0 0 1000;
#P inlet 237 128 15 0;
#P outlet 221 370 15 0;
#P inlet 373 210 15 0;
#P inlet 283 127 15 0;
#P window setfont "Sans Serif" 9.;
#P number 161 178 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 242 201 31 9240586 + 26;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 536 333 60 9109513 font type;
#P comment 416 267 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 373 237 133 9240586 sprintf %imypcontrol1;
#P newex 247 271 103 9240586 pack 0 0 objname;
#P window setfont "Sans Serif" 9.;
#P comment 410 180 100 9109513 x and y coordinates;
#P comment 552 315 42 9109513 font size;
#P connect 2 0 16 0;
#P connect 2 0 17 0;
#P connect 6 0 7 0;
#P connect 17 2 15 0;
#P connect 14 0 10 0;
#P connect 19 0 6 0;
#P connect 11 0 6 0;
#P connect 2 0 14 0;
#P connect 6 0 2 0;
#P connect 8 0 2 1;
#P connect 19 0 2 1;
#P fasten 3 0 2 2 378 267 344 267;
#P connect 12 0 3 0;
#P connect 9 0 3 0;
#P connect 18 0 12 0;
#P connect 21 0 12 2;
#P connect 20 0 12 3;
#P connect 12 0 21 0;
#P connect 18 0 21 1;
#P pop;
#P newobj 522 259 86 9240586 p pcontrol;
#P objectname pcontrol;
#N vpatcher 290 101 971 562;
#P origin 159 39;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 436;
#P objectname u768002018;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u855002020;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 512 199 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 480 89 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 237 44 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 325 96 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P newex 41 332 79 9240586 unpack 0 0 s;
#P newex 135 334 83 9240586 s $0packbang1;
#P outlet 96 383 15 0;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 383 201 103 9240586 counter 0 0 1000;
#P inlet 226 128 15 0;
#P outlet 210 370 15 0;
#P inlet 337 191 15 0;
#P inlet 272 127 15 0;
#P window setfont "Sans Serif" 9.;
#P number 150 178 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 231 201 31 9240586 + 26;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 525 333 60 9109513 font type;
#P comment 405 267 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 363 243 163 9240586 sprintf %imyopendefinition;
#P newex 236 271 103 9240586 pack 0 0 objname;
#P message 238 299 236 9240586 script new $3 message 720 $2 40 8 open;
#P window setfont "Sans Serif" 9.;
#P comment 399 180 100 9109513 x and y coordinates;
#P comment 541 315 42 9109513 font size;
#P connect 3 0 16 0;
#P connect 16 2 14 0;
#P connect 3 0 15 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 18 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 9 0 3 1;
#P connect 18 0 3 1;
#P fasten 4 0 3 2 368 267 333 267;
#P connect 13 0 4 0;
#P connect 10 0 4 0;
#P connect 17 0 13 0;
#P connect 20 0 13 2;
#P connect 19 0 13 3;
#P connect 13 0 20 0;
#P connect 17 0 20 1;
#P pop;
#P newobj 702 260 103 9240586 p opendefinition;
#P objectname opendefinition;
#P window setfont "Sans Serif" 9.;
#N vpatcher 5 40 882 586;
#P origin 0 30;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 204 244 188 9109513 sprintf script hidden connect %s 0 trigger 0;
#P button 650 98 15 0;
#P window linecount 0;
#P newex 599 73 68 9109513 r $0packbang1;
#P newex 690 122 29 9109513 zl reg;
#P newex 727 189 174 9109513 sprintf script hidden connect %s 2 %s 0;
#P inlet 862 33 15 0;
#P newex 108 117 22 9109513 t b;
#P button 345 91 15 0;
#P newex 294 66 68 9109513 r $0packbang1;
#P newex 385 115 29 9109513 zl reg;
#P newex 422 182 174 9109513 sprintf script hidden connect %s 0 %s 0;
#P newex 97 75 68 9109513 r $0packbang1;
#P newex 141 144 29 9109513 zl reg;
#P newex 188 211 174 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 557 26 15 0;
#P inlet 344 21 15 0;
#P inlet 171 48 15 0;
#P outlet 644 491 15 0;
#P outlet 372 484 15 0;
#P outlet 182 490 15 0;
#P connect 8 0 13 0;
#P connect 12 0 7 0;
#P connect 13 0 7 0;
#P connect 3 0 7 1;
#P connect 19 0 0 0;
#P connect 6 0 0 0;
#P connect 7 0 6 0;
#P connect 7 0 19 0;
#P connect 11 0 12 0;
#P connect 4 0 6 1;
#P connect 9 0 1 0;
#P connect 12 0 10 0;
#P connect 4 0 10 1;
#P connect 10 0 9 0;
#P connect 5 0 9 1;
#P connect 15 0 2 0;
#P connect 17 0 18 0;
#P connect 18 0 16 0;
#P connect 4 0 16 1;
#P connect 16 0 15 0;
#P connect 14 0 15 1;
#P pop;
#P newobj 549 185 159 9109513 p connect;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 371 87 971 487;
#P origin 185 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 426;
#P objectname u107002026;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u551002028;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 476 245 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 73 370 79 9240586 unpack 0 0 s;
#P newex -33 371 83 9240586 s $0packbang1;
#P outlet 123 428 15 0;
#P newex 470 140 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 227 95 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 315 147 130 9240586 r $0soundbankcounter;
#P objectname receive;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 356 251 103 9240586 counter 0 0 1000;
#P inlet 210 166 15 0;
#P outlet 184 409 15 0;
#P inlet 336 249 15 0;
#P inlet 246 166 15 0;
#P window setfont "Sans Serif" 9.;
#P number 124 217 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 205 240 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 499 372 60 9109513 font type;
#P comment 379 306 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 339 284 152 9240586 sprintf %imysoundbtext;
#P newex 210 310 103 9240586 pack 0 0 objname;
#P message 211 338 303 9240586 script new $3 user textedit 150 $2 630 $1 34 34 10;
#P window setfont "Sans Serif" 9.;
#P comment 373 219 100 9109513 x and y coordinates;
#P comment 515 354 42 9109513 font size;
#P connect 3 0 19 0;
#P connect 19 2 17 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 15 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 15 0 3 1;
#P connect 9 0 3 1;
#P fasten 4 0 3 2 344 306 307 306;
#P connect 13 0 4 0;
#P connect 10 0 4 0;
#P connect 14 0 13 0;
#P connect 20 0 13 2;
#P connect 16 0 13 3;
#P connect 13 0 20 0;
#P connect 14 0 20 1;
#P pop;
#P newobj 758 76 113 9240586 p soundbanktext;
#P objectname soundbanktext;
#N vpatcher 215 43 979 570;
#P origin 15 36;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 426;
#P objectname u398002030;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u418002032;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 640 213 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 221 331 79 9240586 unpack 0 0 s;
#P newex 120 329 83 9240586 s $0packbang3;
#P outlet 525 443 15 0;
#P message 402 381 361 9240586 script new $3 hidden newex 150 $2 100 9109513 $0loadsamples;
#P message 317 335 356 9240586 script new $3 hidden newex 150 $2 100 9109513 loadsamples1;
#P newex 634 141 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 526 215 103 9240586 counter 0 0 1000;
#P newex 391 96 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 479 148 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P inlet 380 130 15 0;
#P outlet 354 373 15 0;
#P inlet 506 213 15 0;
#P inlet 416 130 15 0;
#P window setfont "Sans Serif" 9.;
#P number 294 181 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 375 204 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 686 330 60 9109513 font type;
#P comment 549 270 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 509 248 157 9240586 sprintf %imyloadsamp;
#P newex 380 274 103 9240586 pack 0 0 objname;
#P window setfont "Sans Serif" 9.;
#P comment 543 183 100 9109513 x and y coordinates;
#P comment 702 312 42 9109513 font size;
#P connect 2 0 19 0;
#P connect 2 0 20 0;
#P connect 6 0 7 0;
#P connect 2 0 16 0;
#P connect 16 0 10 0;
#P connect 13 0 6 0;
#P connect 11 0 6 0;
#P connect 6 0 2 0;
#P connect 13 0 2 1;
#P connect 8 0 2 1;
#P fasten 3 0 2 2 514 270 477 270;
#P connect 14 0 3 0;
#P connect 9 0 3 0;
#P connect 3 0 18 0;
#P connect 12 0 14 0;
#P connect 21 0 14 2;
#P connect 15 0 14 3;
#P connect 14 0 21 0;
#P connect 12 0 21 1;
#P pop;
#P newobj 613 259 76 9240586 p loadsamp;
#P objectname loadsamp;
#P inlet 175 -33 15 0;
#P outlet 185 594 15 0;
#N vpatcher 258 45 934 409;
#P origin 131 30;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 426;
#P objectname u897002034;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u596002036;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 539 218 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 104 341 79 9240586 unpack 0 0 s;
#P newex 0 352 83 9240586 s $0packbang1;
#P outlet 154 399 15 0;
#P newex 518 147 113 9240586 r $0soundbankreset;
#P objectname receive[2];
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 410 221 103 9240586 counter 0 0 1000;
#P newex 275 102 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 382 151 127 9240586 r $0soundbankcounter;
#P objectname receive;
#P inlet 264 136 15 0;
#P outlet 238 379 15 0;
#P inlet 390 219 15 0;
#P inlet 300 136 15 0;
#P window setfont "Sans Serif" 9.;
#P number 178 187 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 259 210 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 553 342 60 9109513 font type;
#P comment 433 276 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 393 254 103 9240586 sprintf %imydrop;
#P newex 264 280 103 9240586 pack 0 0 objname;
#P message 265 308 263 9240586 script new $3 user dropfile 150 $2 630 $1 0;
#P window setfont "Sans Serif" 9.;
#P comment 397 186 100 9109513 x and y coordinates;
#P comment 569 324 42 9109513 font size;
#P connect 3 0 19 0;
#P connect 19 2 17 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 14 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 14 0 3 1;
#P connect 9 0 3 1;
#P fasten 4 0 3 2 398 276 361 276;
#P connect 15 0 4 0;
#P connect 10 0 4 0;
#P connect 13 0 15 0;
#P connect 20 0 15 2;
#P connect 16 0 15 3;
#P connect 15 0 20 0;
#P connect 13 0 20 1;
#P pop;
#P newobj 548 71 61 9240586 p dropbox;
#P objectname dropbox;
#P fasten 7 0 8 0 527 330 33 330;
#P fasten 6 0 9 0 707 436 36 436;
#P fasten 3 1 8 1 684 283 136 283;
#P fasten 3 1 10 1 684 375 138 375;
#P fasten 7 0 9 1 527 363 139 363;
#P fasten 10 0 1 0 35 400 190 400;
#P fasten 5 0 1 0 554 290 190 290;
#P fasten 4 1 1 0 866 98 190 98;
#P fasten 0 1 1 0 604 143 190 143;
#P fasten 5 1 1 0 628 290 190 290;
#P fasten 5 2 1 0 702 254 190 254;
#P fasten 8 0 1 0 33 408 190 408;
#P fasten 3 0 1 0 618 300 190 300;
#P fasten 7 1 1 0 603 327 190 327;
#P fasten 6 1 1 0 800 328 190 328;
#P fasten 9 0 1 0 36 304 190 304;
#P connect 0 0 5 0;
#P fasten 3 1 5 1 684 148 603 148;
#P fasten 4 0 5 2 763 139 652 139;
#P pop;
#P newobj 861 260 116 9240586 p soundbankconnect;
#B color 1;
#P objectname soundbankconnect[1];
#N thispatcher;
#Q end;
#P newobj 861 283 73 9240586 thispatcher;
#P window setfont "Sans Serif" 9.;
#N counter;
#X flags 0 0;
#P newobj -214 359 66 9109513 counter;
#P objectname receive[2];
#P window setfont "Fixedwidth Serif" 10.;
#P newex -285 330 38 9240586 t b b;
#B color 5;
#P objectname trigger;
#P window setfont "Proportional Serif" 10.;
#P comment -244 444 61 9175050 store a preset;
#P window setfont "Fixedwidth Serif" 10.;
#P number -229 464 35 10 0 0 0 141 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[3];
#P newex -262 513 27 9240586 i;
#P message -267 537 53 9240586 store $1;
#P message -45 564 83 9240586 storagewindow;
#P message -44 538 81 9240586 clientwindow;
#P newex 230 26 74 9240586 prepend set;
#B color 5;
#P objectname $0sb[2];
#P newex -346 585 92 9240586 autopattr $0sb;
#B color 5;
#X prestore number[3] 1 0 1;
#X prestore staticnumer 1 0 70;
#P objectname $0sb;
#P window setfont "Sans Serif" 9.;
#P user textedit 314 25 633 53 0 139 9;
#P objectname textsomething;
#P window setfont "Fixedwidth Serif" 10.;
#P newex -346 565 200 9240586 pattrstorage $0sb @autorestore 0;
#B color 5;
#X client_rect 28 48 695 388;
#X storage_rect 98 25 617 570;
#P objectname $0sb[1];
#P user dropfile 332 21 602 53 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 2;
#P comment 802 184 100 9109513 bang to create new drop & text box;
#P window linecount 1;
#P comment 535 58 100 9109513 static drop & text;
#P connect 7 0 3 0;
#P connect 8 0 3 0;
#P connect 9 0 3 0;
#P connect 2 0 13 0;
#P connect 10 0 9 0;
#P connect 13 0 10 0;
#P connect 11 0 10 1;
#P connect 14 0 11 0;
#P connect 13 1 14 0;
#P connect 2 0 6 0;
#P connect 6 0 4 0;
#P connect 16 0 15 0;
#P hidden connect 18 0 17 0;
#P hidden connect 19 0 17 1;
#P pop;

and the abstraction

#N vpatcher 15 55 929 646;
#P origin -102 -152;
#P window setfont "Sans Serif" 9.;
#P newex 173 101 60 9109513 prepend set;
#P outlet 177 130 15 0;
#P inlet 173 71 15 0;
#P user dropfile 159 21 271 58 0;
#P connect 0 0 3 0;
#P connect 1 0 3 0;
#P connect 3 0 2 0;
#P pop;


May 6, 2006 | 2:56 pm

It’s the update. Update to v. 4.5.7 and this patch will work fine.

jb


May 23, 2006 | 8:32 am

Hi,
got the update and now pattrstorage sees all the changes.

Now I am trying to save and recall data from a xml file. I have managed to save the xml, but I am having problems recalling the xml and pattrstorage presets. THe content of the xml’s files is correct (shows the data acurately), but I cannot make it appear in the patch. surely I am missing something…

Please, check the patch below. It is a simplified version of the patch I am working on. I tried to simulate the functioning of the original patch, but I havent automated all the tasks, sorry…

Open the main patch ‘pattrfolders’ first. The other two patches are abstractions.

Any help would be really appreciated.
thanks
d

max v2;
#N vpatcher 0 0 1024 702;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 434 279 54 9109513 abstraction;
#P objectname abstraction;
#P comment 419 249 100 9109513 doubl click to open;
#P pop;

max v2;
#N vpatcher 0 0 1024 702;
#P origin -102 -152;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 173 101 60 9109513 prepend set;
#P outlet 177 130 15 0;
#P inlet 173 71 15 0;
#P user dropfile 159 21 271 58 0;
#P connect 1 0 3 0;
#P connect 0 0 3 0;
#P connect 3 0 2 0;
#P pop;

max v2;
#N vpatcher 0 0 1024 702;
#P origin -582 -137;
#P window setfont "Sans Serif" 9.;
#P number 18 490 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P comment 822 507 171 9109513 -drop the same folder as before;
#P comment 821 490 171 9109513 -name the cue as before;
#P window setfont "Fixedwidth Serif" 10.;
#P hidden newex -231 384 27 9240586 + 1;
#P window setfont "Sans Serif" 9.;
#P comment 338 127 42 9109513 2;
#P comment 820 470 171 9109513 close patch , open again and…;
#P comment 813 537 42 9109513 6;
#P comment 820 440 42 9109513 5;
#P comment 816 359 42 9109513 4;
#P comment 812 310 42 9109513 3;
#P comment 805 199 42 9109513 1;
#P window linecount 2;
#P comment 842 56 100 9109513 follow the steps top to bottom:;
#P number 935 416 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname testnumber;
#P window setfont "Sans Serif" 12.;
#P window linecount 1;
#P comment 336 149 151 9109516 Drop folders down here…;
#P window setfont "Sans Serif" 9.;
#P comment 865 346 133 9109513 drop folder / xml path;
#P comment 880 534 112 9109513 RECALL XML file;
#P user textedit 859 311 979 327 32896 139 9;
#P objectname textedit;
#P hidden message -72 290 14 9109513 1;
#P hidden newex -71 262 51 9109513 r loadbang;
#P objectname receive[8];
#P hidden toggle -5 263 15 0;
#P hidden message -20 295 53 9109513 border $1;
#P user dropfile 860 359 1002 401 1;
#N vpatcher 187 222 787 622;
#P origin 506 78;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P comment 325 8 100 9109513 name;
#P inlet 177 73 15 0;
#P newex 253 302 94 9109513 r $0bangsavewindow;
#P objectname receive[7];
#P newex 491 294 76 9109513 r $0bangsbrecall;
#P objectname receive[6];
#P window linecount 0;
#P newex 171 159 23 9109513 t b;
#P objectname receive[1];
#P outlet 486 455 15 0;
#P inlet 320 34 15 0;
#P message 216 167 15 9109513;
#P newex 209 133 57 9109513 prepend set;
#P button 283 94 15 0;
#P newex 592 244 57 9109513 prepend set;
#P newex 580 214 67 9109513 pack read xml;
#P message 578 327 15 9109513;
#P newex 434 182 19 9109513 t b;
#P newex 512 177 49 9109513 tosymbol;
#P newex 413 221 68 9109513 pack write xml;
#P newex 333 97 48 9109513 route text;
#P message 362 337 15 9109513;
#P newex 382 253 57 9109513 prepend set;
#P newex 414 149 133 9109513 sprintf %s %s soundbank.xml;
#P newex 135 -26 119 9109513 autopattr sb @autoname 1;
#P objectname sb;
#P comment 96 123 100 9109513 save path;
#P connect 13 0 17 0;
#P connect 20 0 13 0;
#P connect 12 0 14 0;
#P connect 17 0 14 0;
#P connect 13 0 14 0;
#P connect 15 0 12 0;
#P connect 15 0 5 0;
#P connect 19 0 4 0;
#P connect 3 0 4 0;
#P connect 6 0 3 0;
#P connect 8 0 6 0;
#P connect 14 0 2 0;
#P connect 2 0 8 0;
#P connect 7 0 6 1;
#P connect 9 0 16 0;
#P connect 4 0 16 0;
#P connect 2 0 7 0;
#P connect 5 0 2 1;
#P connect 18 0 9 0;
#P connect 11 0 9 0;
#P connect 8 0 10 0;
#P connect 10 0 11 0;
#P connect 7 0 10 1;
#P pop;
#P newobj 868 410 58 9109513 p namefilter;
#B color 4;
#P objectname namefilter[1];
#P hidden newex 861 557 96 9109513 s $0bangsavewindow;
#P button 867 439 18 5;
#P objectname sbbangrecall[1];
#P hidden newex 906 558 90 9109513 s $0bangsbrecall;
#P button 858 533 18 5;
#P objectname sbbangrecall;
#P comment 927 175 100 9109513 reset place & names;
#P message 956 200 14 9109513 5;
#P button 858 203 15 0;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 185 80 953 492;
#P origin 0 72;
#P window setfont "Sans Serif" 9.;
#P window linecount 0;
#P comment 479 302 100 9109513 naming;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 292 269 27 9240586 + 1;
#P objectname +;
#P newex 284 241 27 9240586 i;
#P window setfont "Sans Serif" 9.;
#P number 261 200 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[2];
#P window setfont "Fixedwidth Serif" 10.;
#P newex 334 218 50 9240586 del 500;
#P newex 338 196 80 9240586 r $0loadbang;
#P objectname receive;
#P window setfont "Sans Serif" 9.;
#P message 522 95 14 9109513 5;
#P message 617 96 14 9109513 0;
#P window setfont "Fixedwidth Serif" 10.;
#N counter 0 5 1000;
#X flags 0 0;
#P newobj 484 176 103 9240586 counter 0 5 1000;
#P window setfont "Sans Serif" 9.;
#P newex 385 45 129 9109513 autopattr $0sb @autoname 1;
#X prestore number[2] 1 0 5;
#P objectname $0sb[1];
#P window linecount 3;
#P comment 118 146 100 9109513 change 2nd number (40) to change distance between rows;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 1;
#P newex 598 173 113 9240586 s $0soundbankreset;
#P newex 130 276 103 9240586 s $0soundbankexp;
#P newex 482 266 134 9240586 s $0soundbankcounter;
#P newex 115 245 121 9240586 expr ($i1 * 40) +50;
#N counter 0 5 1000;
#X flags 0 0;
#P newobj 259 173 103 9240586 counter 0 5 1000;
#P window setfont "Fixedwidth Serif" 14.;
#P comment 223 145 60 9240590 Add cue;
#P inlet 588 45 15 0;
#P inlet 224 21 15 0;
#P window setfont "Sans Serif" 9.;
#P comment 149 310 100 9109513 window placemnt;
#P connect 4 0 5 0;
#P connect 5 0 7 0;
#P connect 1 0 4 0;
#P connect 4 0 16 0;
#P connect 17 0 18 0;
#P connect 16 0 17 1;
#P connect 18 0 4 2;
#P connect 13 0 4 2;
#P connect 14 0 15 0;
#P connect 11 0 6 0;
#P connect 1 0 11 0;
#P connect 2 0 13 0;
#P connect 12 0 11 2;
#P connect 12 0 8 0;
#P connect 2 0 12 0;
#P pop;
#P newobj 858 222 110 9240586 p soundbankcreate;
#B color 2;
#P objectname soundbankcreate[1];
#N vpatcher 4 27 995 665;
#P origin 0 113;
#P window setfont "Sans Serif" 9.;
#N vpatcher 5 40 877 686;
#P button 299 128 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 294 94 68 9109513 r $0packbang4;
#P newex 385 145 41 9109513 zl reg;
#P newex 422 212 174 9109513 sprintf script hidden connect %s 0 %s 2;
#P inlet 557 56 15 0;
#P inlet 344 51 15 0;
#P outlet 372 514 15 0;
#P connect 5 0 6 0;
#P connect 3 0 0 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 30 367 113 9109513 p connect;
#N vpatcher 5 40 877 686;
#P window setfont "Sans Serif" 9.;
#P newex 108 147 22 9109513 t b;
#P newex 97 105 75 9109513 r $0packbang2;
#P newex 141 174 40 9109513 zl reg;
#P newex 188 241 193 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 383 65 15 0;
#P inlet 171 78 15 0;
#P outlet 182 520 15 0;
#P connect 5 0 6 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 3 0 0 0;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 31 338 113 9109513 p connect;
#N vpatcher 5 40 877 686;
#P button 299 128 15 0;
#P window setfont "Sans Serif" 9.;
#P newex 294 94 75 9109513 r $0packbang2;
#P newex 385 145 41 9109513 zl reg;
#P newex 422 212 189 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 557 56 15 0;
#P inlet 344 51 15 0;
#P outlet 372 514 15 0;
#P connect 5 0 6 0;
#P connect 3 0 0 0;
#P connect 6 0 4 0;
#P connect 1 0 4 1;
#P connect 4 0 3 0;
#P connect 2 0 3 1;
#P pop;
#P newobj 28 295 113 9109513 p connect;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 290 101 971 562;
#P origin 148 39;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 276;
#P objectname u440001015;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u770001017;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 520 213 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 502 82 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 259 37 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 330 114 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P newex 130 309 79 9240586 unpack 0 0 s;
#P newex 24 310 83 9240586 s $0packbang2;
#P outlet 180 367 15 0;
#P message 246 304 323 9240586 script new $3 hidden newex 640 $2 40 9109513 pcontrol;
#P message 279 346 229 9240586 newobj 133 105 44 9109513 p soundbank;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 390 209 103 9240586 counter 0 0 1000;
#P inlet 237 128 15 0;
#P outlet 221 370 15 0;
#P inlet 373 210 15 0;
#P inlet 283 127 15 0;
#P window setfont "Sans Serif" 9.;
#P number 161 178 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 242 201 31 9240586 + 26;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 536 333 60 9109513 font type;
#P comment 416 267 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 373 237 133 9240586 sprintf %imypcontrol1;
#P newex 247 271 103 9240586 pack 0 0 objname;
#P window setfont "Sans Serif" 9.;
#P comment 410 180 100 9109513 x and y coordinates;
#P comment 552 315 42 9109513 font size;
#P connect 2 0 16 0;
#P connect 2 0 17 0;
#P connect 6 0 7 0;
#P connect 17 2 15 0;
#P connect 14 0 10 0;
#P connect 19 0 6 0;
#P connect 11 0 6 0;
#P connect 2 0 14 0;
#P connect 6 0 2 0;
#P connect 19 0 2 1;
#P connect 8 0 2 1;
#P fasten 3 0 2 2 378 267 344 267;
#P connect 12 0 3 0;
#P connect 9 0 3 0;
#P connect 18 0 12 0;
#P connect 21 0 12 2;
#P connect 20 0 12 3;
#P connect 12 0 21 0;
#P connect 18 0 21 1;
#P pop;
#P newobj 522 259 86 9240586 p pcontrol;
#P objectname pcontrol;
#N vpatcher 290 101 971 562;
#P origin 159 39;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 276;
#P objectname u251001019;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u869001021;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 512 199 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 480 89 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 237 44 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 325 96 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P newex 41 332 79 9240586 unpack 0 0 s;
#P newex 135 334 83 9240586 s $0packbang1;
#P outlet 96 383 15 0;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 383 201 103 9240586 counter 0 0 1000;
#P inlet 226 128 15 0;
#P outlet 210 370 15 0;
#P inlet 337 191 15 0;
#P inlet 272 127 15 0;
#P window setfont "Sans Serif" 9.;
#P number 150 178 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 231 201 31 9240586 + 26;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 525 333 60 9109513 font type;
#P comment 405 267 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 363 243 163 9240586 sprintf %imyopendefinition;
#P newex 236 271 103 9240586 pack 0 0 objname;
#P message 238 299 236 9240586 script new $3 message 720 $2 40 8 open;
#P window setfont "Sans Serif" 9.;
#P comment 399 180 100 9109513 x and y coordinates;
#P comment 541 315 42 9109513 font size;
#P connect 3 0 16 0;
#P connect 16 2 14 0;
#P connect 3 0 15 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 18 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 18 0 3 1;
#P connect 9 0 3 1;
#P fasten 4 0 3 2 368 267 333 267;
#P connect 13 0 4 0;
#P connect 10 0 4 0;
#P connect 17 0 13 0;
#P connect 20 0 13 2;
#P connect 19 0 13 3;
#P connect 13 0 20 0;
#P connect 17 0 20 1;
#P pop;
#P newobj 702 260 103 9240586 p opendefinition;
#P objectname opendefinition;
#P window setfont "Sans Serif" 9.;
#N vpatcher 5 40 882 586;
#P origin 0 30;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 204 244 188 9109513 sprintf script hidden connect %s 0 trigger 0;
#P button 650 98 15 0;
#P window linecount 0;
#P newex 599 73 68 9109513 r $0packbang1;
#P newex 690 122 29 9109513 zl reg;
#P newex 727 189 174 9109513 sprintf script hidden connect %s 2 %s 0;
#P inlet 862 33 15 0;
#P newex 108 117 22 9109513 t b;
#P button 345 91 15 0;
#P newex 294 66 68 9109513 r $0packbang1;
#P newex 385 115 29 9109513 zl reg;
#P newex 422 182 174 9109513 sprintf script hidden connect %s 0 %s 0;
#P newex 97 75 68 9109513 r $0packbang1;
#P newex 141 144 29 9109513 zl reg;
#P newex 188 211 174 9109513 sprintf script hidden connect %s 0 %s 0;
#P inlet 557 26 15 0;
#P inlet 344 21 15 0;
#P inlet 171 48 15 0;
#P outlet 644 491 15 0;
#P outlet 372 484 15 0;
#P outlet 182 490 15 0;
#P connect 8 0 13 0;
#P connect 12 0 7 0;
#P connect 13 0 7 0;
#P connect 3 0 7 1;
#P connect 6 0 0 0;
#P connect 19 0 0 0;
#P connect 7 0 6 0;
#P connect 7 0 19 0;
#P connect 11 0 12 0;
#P connect 4 0 6 1;
#P connect 9 0 1 0;
#P connect 12 0 10 0;
#P connect 4 0 10 1;
#P connect 10 0 9 0;
#P connect 5 0 9 1;
#P connect 15 0 2 0;
#P connect 17 0 18 0;
#P connect 18 0 16 0;
#P connect 4 0 16 1;
#P connect 16 0 15 0;
#P connect 14 0 15 1;
#P pop;
#P newobj 549 185 159 9109513 p connect;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 371 87 971 487;
#P origin 185 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 266;
#P objectname u469001023;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u172001025;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 476 245 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 73 370 79 9240586 unpack 0 0 s;
#P newex -33 371 83 9240586 s $0packbang1;
#P outlet 123 428 15 0;
#P newex 470 140 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#P newex 227 95 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 315 147 130 9240586 r $0soundbankcounter;
#P objectname receive;
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 356 251 103 9240586 counter 0 0 1000;
#P inlet 210 166 15 0;
#P outlet 184 409 15 0;
#P inlet 336 249 15 0;
#P inlet 246 166 15 0;
#P window setfont "Sans Serif" 9.;
#P number 124 217 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 205 240 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 499 372 60 9109513 font type;
#P comment 379 306 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 339 284 152 9240586 sprintf %imysoundbtext;
#P newex 210 310 103 9240586 pack 0 0 objname;
#P message 211 338 303 9240586 script new $3 user textedit 150 $2 630 $1 34 34 10;
#P window setfont "Sans Serif" 9.;
#P comment 373 219 100 9109513 x and y coordinates;
#P comment 515 354 42 9109513 font size;
#P connect 3 0 19 0;
#P connect 19 2 17 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 15 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 9 0 3 1;
#P connect 15 0 3 1;
#P fasten 4 0 3 2 344 306 307 306;
#P connect 13 0 4 0;
#P connect 10 0 4 0;
#P connect 14 0 13 0;
#P connect 20 0 13 2;
#P connect 16 0 13 3;
#P connect 13 0 20 0;
#P connect 14 0 20 1;
#P pop;
#P newobj 758 76 113 9240586 p soundbanktext;
#P objectname soundbanktext;
#N vpatcher 215 43 979 570;
#P origin 15 36;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 266;
#P objectname u125001027;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u850001029;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 640 213 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 221 331 79 9240586 unpack 0 0 s;
#P newex 120 329 83 9240586 s $0packbang3;
#P outlet 525 443 15 0;
#P message 402 381 361 9240586 script new $3 hidden newex 150 $2 100 9109513 $0loadsamples;
#P message 317 335 308 9240586 script new $3 hidden newex 150 $2 100 9109513 abst;
#P newex 634 141 115 9240586 r $0soundbankreset;
#P objectname receive[2];
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 526 215 103 9240586 counter 0 0 1000;
#P newex 391 96 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 479 148 130 9240586 r $0soundbankcounter;
#P objectname receive;
#P inlet 380 130 15 0;
#P outlet 354 373 15 0;
#P inlet 506 213 15 0;
#P inlet 416 130 15 0;
#P window setfont "Sans Serif" 9.;
#P number 294 181 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 375 204 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 686 330 60 9109513 font type;
#P comment 549 270 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 509 248 157 9240586 sprintf %imyloadsamp;
#P newex 380 274 103 9240586 pack 0 0 objname;
#P window setfont "Sans Serif" 9.;
#P comment 543 183 100 9109513 x and y coordinates;
#P comment 702 312 42 9109513 font size;
#P connect 2 0 19 0;
#P connect 2 0 20 0;
#P connect 6 0 7 0;
#P connect 2 0 16 0;
#P connect 16 0 10 0;
#P connect 13 0 6 0;
#P connect 11 0 6 0;
#P connect 6 0 2 0;
#P connect 8 0 2 1;
#P connect 13 0 2 1;
#P fasten 3 0 2 2 514 270 477 270;
#P connect 14 0 3 0;
#P connect 9 0 3 0;
#P connect 3 0 18 0;
#P connect 12 0 14 0;
#P connect 21 0 14 2;
#P connect 15 0 14 3;
#P connect 14 0 21 0;
#P connect 12 0 21 1;
#P pop;
#P newobj 613 259 76 9240586 p loadsamp;
#P objectname loadsamp;
#P inlet 175 -33 15 0;
#P outlet 185 594 15 0;
#N vpatcher 258 45 934 409;
#P origin 131 30;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 610 38 106 9109513 autopattr @autoname 1;
#X prestore number 1 0 266;
#P objectname u243001031;
#P window setfont "Fixedwidth Serif" 10.;
#N vpatcher 115 205 715 605;
#P inlet 522 98 15 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 58 642 106 9109513 autopattr @autoname 1;
#X prestore number[5] 1 0 0;
#P objectname u869001033;
#P window setfont "Fixedwidth Serif" 10.;
#P window linecount 0;
#P newex 288 259 27 9240586 + 1;
#P objectname +[1];
#P newex 280 237 27 9240586 i;
#P newex 514 161 26 9240586 t b;
#P objectname receive[4];
#P window setfont "Sans Serif" 9.;
#P number 316 235 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[5];
#P outlet 261 482 15 0;
#P inlet 304 102 15 0;
#P connect 5 0 1 0;
#P connect 3 0 4 0;
#P connect 4 0 5 0;
#P connect 2 0 4 1;
#P connect 0 0 2 0;
#P connect 7 0 3 0;
#P pop;
#P newobj 539 218 62 9240586 p keepcue;
#P objectname receive[5];
#P window linecount 0;
#P newex 104 341 79 9240586 unpack 0 0 s;
#P newex 0 352 83 9240586 s $0packbang1;
#P outlet 154 399 15 0;
#P newex 518 147 113 9240586 r $0soundbankreset;
#P objectname receive[2];
#N counter 0 0 1000;
#X flags 0 0;
#P newobj 410 221 103 9240586 counter 0 0 1000;
#P newex 275 102 103 9240586 r $0soundbankexp;
#P objectname receive[1];
#P newex 382 151 127 9240586 r $0soundbankcounter;
#P objectname receive;
#P inlet 264 136 15 0;
#P outlet 238 379 15 0;
#P inlet 390 219 15 0;
#P inlet 300 136 15 0;
#P window setfont "Sans Serif" 9.;
#P number 178 187 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 259 210 31 9240586 + 16;
#P objectname +;
#P window setfont "Sans Serif" 9.;
#P comment 553 342 60 9109513 font type;
#P comment 433 276 100 9109513 number box names;
#P window setfont "Fixedwidth Serif" 10.;
#P newex 393 254 103 9240586 sprintf %imydrop;
#P newex 264 280 103 9240586 pack 0 0 objname;
#P message 265 308 263 9240586 script new $3 user dropfile 150 $2 630 $1 0;
#P window setfont "Sans Serif" 9.;
#P comment 397 186 100 9109513 x and y coordinates;
#P comment 569 324 42 9109513 font size;
#P connect 3 0 19 0;
#P connect 19 2 17 0;
#P connect 7 0 8 0;
#P connect 2 0 11 0;
#P connect 14 0 7 0;
#P connect 12 0 7 0;
#P connect 7 0 3 0;
#P connect 3 0 2 0;
#P connect 9 0 3 1;
#P connect 14 0 3 1;
#P fasten 4 0 3 2 398 276 361 276;
#P connect 15 0 4 0;
#P connect 10 0 4 0;
#P connect 13 0 15 0;
#P connect 20 0 15 2;
#P connect 16 0 15 3;
#P connect 15 0 20 0;
#P connect 13 0 20 1;
#P pop;
#P newobj 548 71 61 9240586 p dropbox;
#P objectname dropbox;
#P fasten 7 0 8 0 527 330 33 330;
#P fasten 6 0 9 0 707 436 36 436;
#P fasten 3 1 8 1 684 283 136 283;
#P fasten 3 1 10 1 684 375 138 375;
#P fasten 7 0 9 1 527 363 139 363;
#P fasten 9 0 1 0 36 304 190 304;
#P fasten 6 1 1 0 800 328 190 328;
#P fasten 7 1 1 0 603 327 190 327;
#P fasten 3 0 1 0 618 300 190 300;
#P fasten 8 0 1 0 33 408 190 408;
#P fasten 5 2 1 0 702 254 190 254;
#P fasten 5 1 1 0 628 290 190 290;
#P fasten 0 1 1 0 604 143 190 143;
#P fasten 4 1 1 0 866 98 190 98;
#P fasten 5 0 1 0 554 290 190 290;
#P fasten 10 0 1 0 35 400 190 400;
#P connect 0 0 5 0;
#P fasten 3 1 5 1 684 148 603 148;
#P fasten 4 0 5 2 763 139 652 139;
#P pop;
#P newobj 857 243 116 9240586 p soundbankconnect;
#B color 1;
#P objectname soundbankconnect[1];
#N thispatcher;
#Q end;
#P newobj 857 266 73 9240586 thispatcher;
#P window setfont "Sans Serif" 9.;
#N counter;
#X flags 0 0;
#P hidden newobj -212 258 66 9109513 counter;
#P objectname receive[2];
#P window setfont "Fixedwidth Serif" 10.;
#P hidden newex -283 229 38 9240586 t b b;
#B color 5;
#P objectname trigger;
#P window setfont "Proportional Serif" 10.;
#P hidden comment -242 343 61 9175050 store a preset;
#P window setfont "Fixedwidth Serif" 10.;
#P hidden number -227 363 35 10 0 0 0 141 0 0 0 221 221 221 222 222 222 0 0 0;
#P objectname number[3];
#P hidden newex -260 412 27 9240586 i;
#P hidden message -265 436 53 9240586 store $1;
#P message 1 464 83 9240586 storagewindow;
#P message 2 438 81 9240586 clientwindow;
#P hidden newex -343 490 92 9240586 autopattr $0sb;
#B color 5;
#X prestore number[3] 1 0 0;
#X prestore testnumber 1 0 0;
#P objectname $0sb;
#P hidden newex -344 464 182 9240586 pattrstorage $0sb @savemode 0;
#B color 5;
#X client_rect 0 0 640 240;
#X storage_rect 0 0 640 240;
#P objectname $0sb[1];
#P window setfont "Sans Serif" 9.;
#P window linecount 2;
#P comment 824 165 100 9109513 bang to create new drop & text box;
#P window linecount 1;
#P comment 887 440 71 9109513 SAVE XML file;
#P comment 859 294 100 9109513 name xml file;
#P comment 932 401 100 9109513 test number;
#P comment 4 513 100 9109513 recall pattr presets;
#P hidden connect 47 0 5 0;
#P hidden fasten 25 0 5 0 873 409 -339 409;
#P hidden connect 8 0 5 0;
#P hidden connect 7 0 5 0;
#P hidden connect 9 0 5 0;
#P hidden connect 23 0 13 0;
#P hidden connect 10 0 9 0;
#P hidden connect 13 0 10 0;
#P hidden connect 44 0 10 1;
#P hidden connect 11 0 44 0;
#P hidden connect 14 0 11 0;
#P hidden connect 13 1 14 0;
#P hidden connect 29 0 30 0;
#P hidden connect 28 0 27 0;
#P hidden connect 30 0 28 0;
#P connect 16 0 15 0;
#P hidden connect 18 0 17 0;
#P hidden connect 27 0 26 0;
#P hidden connect 23 0 24 0;
#P hidden fasten 26 0 25 0 865 433 873 433;
#P hidden connect 21 0 22 0;
#P hidden fasten 31 0 25 1 864 338 921 338;
#P hidden connect 19 0 17 1;
#P pop;


May 23, 2006 | 8:36 am

sorry, you may need the name of the abstractions. i forgot to include them:

Main: pattrfolders
first abstraction: abst
second abstraction: abstraction


May 23, 2006 | 11:57 am

So here’s what my max window shows when the write message is sent (I
added some prints here)

print: write Bellyache:/Users/jeremydb/Desktop/abst/ pah.xml soundbank.xml


May 23, 2006 | 12:08 pm

Sorry – message seems to have gotten cut off…

So here’s what my max window shows when the write message is sent (I
added some prints here)

print: write Bellyache:/Users/jeremydb/Desktop/abst/ pah.xml soundbank.xml

So you’re using [ sprintf %s %s soundbank.xml ] which is 100% _not_ what
you want here. However, I’m not really clear what it is that you do
want, since you seem to want to give the xml file 2 different names, or
save it in some special place or something, but it’s not clear from the
comments or the patch.

However, I’m guessing that you would probably like [ sprintf %s%s ]

jb


May 23, 2006 | 1:43 pm

Jeremy,
I dont know how you get that print message (?)

If I print after the ‘pack write xml’ object , this is what I get:

pack: write C:/Documents and Settings/DV Customer/Desktop/amen/ mine soundbank.xml

and also an xml file in the amen folder called ‘mine soundbank.xml’

where ‘mine’ is the name given into the text box. ‘soundbank’ in sprintf is just to make it easier for me to identify the type of xml file , as there are a few being saved from different parts of the (original) patch. But it is not necessary, so I guess I could get rid of it if it was sttoping pattrstorage from working…

However, I think the .xml in the after sprintf %s%s seems necessary to add the file extension at the end of the name, since the xml in the pack object is just providing the second inlet to the pack object , and never sems to be added to the name…

d


May 23, 2006 | 9:36 pm

oh,I guess you entered ‘pah.xml’ in the name box…

perhaps I should explain what I want to do in my patch in general.
As you can see, you can create several drop boxes that are connected to the abstraction ‘abst’. In my original patch, those abstractions include a buffer/js.folderiter/coll combination that plays back the files included in the folder that you dropped in the drop area. I would like to save and recall the xml file to be able to recall the folder path into the text box, and then bang it to reload the files into abst’s buffer.
It gets more complicated, as the patch we are working in is itself an abstraction (called ‘abstraction’). The reason for this is that in my original patch you can script/create as many as these as you want from the top ‘pattrfolder’ patch. It is here that you name each of the ‘abstraction’ patches, and where you define the save path for all the xml files. By the way, I do need to save each xml file with two names: first, the name given to the ‘abstraction’; second the type of data saved in the xml file. This is because for every ‘abstraction’, I am saving more than one xml file…

hope this gives a bit of context
dan


May 25, 2006 | 9:07 am

The read and write messages to pattrstorage take one optional symbol
argument, which is the name of the .xml file, partially or fully qualified.

So:

write Bellyache:/test/afile.xml
write "Bellyache:/a folder/afile.xml"
write afile.xml

are all valid. Note that symbols containing spaces _must_ be enclosed in
double-quotes. The "symout" argument to the sprintf object will ensure
that the output of that object is a single symbol (Max Reference Manual,
p.550). Nevertheless, whitespace does count in file names and paths,
and these:

write Bellyache:/test/ afile.xml
write Bellyache:/ a folder / a file.xml
write "Bellyache:/a folder/ a file.xml"

won’t work either, assuming that the file is located at
Bellyache:/test/afile.xml

The patch I looked at was inserting spaces into the file name and file
path due to its use of a [sprintf %s %s] or similar, rather than a
[sprintf symout %s%s]. This was clear from the excerpt I posted previous
from the Max window, as well as the one you posted.

So, you need to pay some attention to this detail, at which point,
pattrstorage will work just as it should.

jb

Am 23.05.2006 um 23:36 Uhr schrieb dan:
> hope this gives a bit of context


Viewing 14 posts - 1 through 14 (of 14 total)