Long Commands And Word Wrap

Hey all-

I am rewriting a script I wrote a while ago, and would like to know if there is a way to make very long commands more readable? I have a button who needs to update a set of scroll-lists, and I want to make sure to clear them before I repopulate them, so the command ends up being one very long line of unreadable code. Is there a way to put "carraige returns" into a command so that I can more easily read it when I return to it later?

ie.

if ( something == something else){

 blah blah blah

}
do this
{
else (do this )
}

now when I tie that to a button it looks like this:

button = button -c "if ( something == something else){blah blah blah}do this{else (do this )}";

As you can see this is not very legible.. Can I fix this?

Thanks

Sheriff

Hi, I think you can use proc.

proc doThis()
{

}

button = button -c "doThis()";

If you abhor procs then you can do:

CODE
button = button -c
  ("if ( something == something else){"+
   "  blah;"+
   "  blah;"+
   "  blah;"+
   "}"+
   "else {(do this )}");

Note the extra parenthesis!