Defining multiple variables.

Posted by ojfoggin on 02-Jun-2009 05:44

Is there any way of defining multiple variable of the same type in one line?

something like...

define variable li-year, li-month, li-day as int no-undo.

or something?

Thank you!

Oliver

All Replies

Posted by Admin on 02-Jun-2009 06:09

Not in the way you probably would expect it

You can have many statements in a single line (usually a bad practice), but it works:

DEFINE VARIABLE i AS INTEGER NO-UNDO. DEFINE VARIABLE j AS INTEGER NO-UNDO .

But it's a feature I missed as well many times.

Posted by ojfoggin on 02-Jun-2009 06:11

Thanks.... I think

There's quite a lot that I miss from my Java programming that seem like very simple but effective little shortcuts.

Posted by ChUIMonster on 02-Jun-2009 07:06

Me too!

This thread is closed