The good Doctor is going to love this
create a class foo
CLASS foo:
DEF PUBLIC PROPERTY bar AS CHAR NO-UNDO INIT "wow" GET . PRIVATE SET .
END CLASS.
now have a look at this code :
DEF VAR a AS CLASS experiment.foo.
a = NEW foo().
MESSAGE a:"bar" VIEW-AS ALERT-BOX.
funky, huh ?
Haven't found a use for that. Yet .
I always liked this one.
procedure " ".
MESSAGE 'something'
VIEW-AS ALERT-BOX.
end.
procedure " ".
message "something else" view as alert-box.
run " ".
run ' '.
Note that the quotes are NOT part of the name. So you can put spaces into variable and run it.
Or this one:
procedure "".
/* do something */
MESSAGE 'hell world'
VIEW-AS ALERT-BOX.
end.
run value('').
No spaces at all.
yuk ...
jmls wrote:
yuk ...
Indeed, although this is not allowed in OOABL ...
/* no spaces in name */
METHOD ""():
gives: Identifier was left blank or is more than 32 characters. (1700)
/* has space-as-name */
METHOD " "():
gives: ** The first character of must be alphabetic. (257)