Hallo, [EMAIL PROTECTED] hat gesagt: // [EMAIL PROTECTED] wrote: > I'd like to send an entire external text file (xml) over tcp on a bang. > I'm currently struggling with the textfile object and netsend. Are there > better ways? > > Textfile assumes I want to send a line at a time, while netsend wants a > message with "send" at the start and then the entire string I want to > send. A message with "send $1" only sends the second word of any line.
To dynamically prepend a "send" in front of a list of unknown length you can use [list prepend send]. This will generate a message: "list send a b c d ..." However [netsend] wants to get a message not starting with "list send" but only with "send ..." so you need to use an additional [list trim] to remove the "list"-part. All together this will be like this: [textfile] | [list prepend send] | [list trim] | [netsend] Ciao -- Frank Barknecht _ ______footils.org_ __goto10.org__ _______________________________________________ PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list