There are 2 (almost identical) pages describing MsgBox :
Since there’s also InputBox Function
I’d tend to think the MsgBox statement
is obsolete …
But who knows …
any idea, clue ?
There are 2 (almost identical) pages describing MsgBox :
Since there’s also InputBox Function
I’d tend to think the MsgBox statement
is obsolete …
But who knows …
any idea, clue ?
Just drop the statement page. We don’t handle it in any special way, it’s just SbRtl_MsgBox function.
thanks.
looks like the tip of an iceberg ?
croos-over from VBA ?
Mid
is a different beast. Mid
function returns a value. Mid
statement replaces in-place.
There is a tiny difference between Mid-function ( it returns the part-string described by start and optional lenght )
and the Mid-Statement ( it changes the first Argument according to the defined start , length, replace-string )
sub main
original_text = "This is the original Text"
msgbox mid( original_text , 13, 8) 'function-call shows: »original«'
msgbox original_text 'shows: »This is the original Text«'
mid( original_text, 13, 8, "new" ) 'statement'
msgbox original_text 'shows: »This is the new Text«'
end sub
FTR: we have three “statement functions” in Basic: besides Mid
, they are Date
and Time
. This is specified in basic/source/runtime/stdobj.cxx: see where LFUNCTION_
is used there.
But for these two latter, statement behavior is not implemented: see e.g. Time
returning error when trying to write to it.
Aha, there’s also MkDir
statement, which is not decorated as such in the mentioned file - will fix that.
will it be? should it be?
a bugzilla on this ?
No idea; I have no intention working on that - would you expect someone running across some fact in the code to necessarily have knowledge if this is really needed to someone?
thanks.
looks much more explanatory than the example in the help page.
do you mind if I put it in there?
of course take it!