Page 1 of 1

[Implemented] SelectElement() should have a return value

Posted: Thu Mar 18, 2010 9:43 am
by infratec
Hi PB Team,

at the moment I have a program, where it is possible that I call SelectElement() with an
invalid index.
At the moment I have to use

Code: Select all

if index < ListSize()
 SelectElement(Test(), index)
to check this before.
More elegant would be, if I can check the result of SelectElement() like

Code: Select all

if SelectElement(Test(), index)
Best regards,
Bernd

Re: SelectElement() should have a return value

Posted: Thu Mar 18, 2010 9:47 am
by Fred
Actually it alreday does that as it returns the list item data adress if the element is found.

Re: SelectElement() should have a return value

Posted: Thu Mar 18, 2010 10:00 am
by infratec
Thanks Fred for the fast response.

Than you have only to adjust the helpfile.
There is still written:
Rückgabewert:
Dieser Befehl hat keinen Rückgabewert.
in englsih:
Return value:
This function does not return any value.
Bernd