This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

break list up

Old posts that have not been replied to for several years.
Locked
O
Ofloo
Owner
Posts: 953
Joined: Tue May 13, 2003 1:37 am
Location: Belguim
Contact:

break list up

Post by Ofloo »

break a line up in many lines on certain length i know llength but how do i split up a space with out changing the contents and add /n

ive tryed

Code: Select all

if {[llenght $list] <= 11 } {set list [lreplace $list 11 11 [lindex $list 11]\n]}
but that seemed to add some unwanted chars like {}
XplaiN but think of me as stupid
User avatar
BarkerJr
Op
Posts: 104
Joined: Sun Mar 30, 2003 1:25 am
Contact:

Post by BarkerJr »

join $list "\n"
O
Ofloo
Owner
Posts: 953
Joined: Tue May 13, 2003 1:37 am
Location: Belguim
Contact:

Post by Ofloo »

what about the next 11 like

110 chars = 10 lines or should be ..

so i would need kinda a foreach .. but foreach what ? what is the condition ? for sutch a thing ??
XplaiN but think of me as stupid
Locked