Bug in startapp lisp function

#1
I am using CMS Intellicad 10 PE Plus. I have found there is a severe bug in the (startapp) lisp function. According to the documentation it should return an integer greater than 2 on success, and it should return 2 if unsuccessful. It does not do this. I have found that it returns nil in all cases, whether successful or not. Because of this it is impossible to tell if it was successful or not.

I have recently migrated from Intellicad 8.1, and in that earlier version (startapp) did return the proper result code.

Please advise. Is it possible to get this fixed?

Re: Bug in startapp lisp function

#3
I am sorry I have to help you with this. I thought it was obvious what I was saying about the return value of (startapp). You don't need a lisp file. Just type the following into Intellicad at the command prompt (press F2 first to open the Intellicad propmt history window so you can see the results returned by the commands).

(startapp "notepad")
The command above will open notepad, and will return a value of nil.

(startapp( "thisisnothing")
The command above will not open any program because there is no program called "thisisnothing". However, the return value will still be nil.

The documentation in the help file for the list function (startapp) clearly states that the return value should be an integer greater than 2 on success, or 2 if unsuccessful. I would expect the first case above to return an integer greater than 2, and the second case to return 2.

Re: Bug in startapp lisp function

#4
For info this is what I get in version 9.0
Command:
Command:
Rendering support loaded.
Raster image support loaded.
Command: (startapp "notepad")
nil
Command: '_PMTHIST
Notepad did open.

and this is what I get from version 7.1
Adeko Raster loaded.
Command: (startapp "notepad")
33
Command: '_PMTHIST
again Notepad opened.

Re: Bug in startapp lisp function

#5
Yes, your results agree with what I see. But the documentation in the help file clearly states:

"This function starts any other Windows application appname. Optionally, it also loads a filename into that application. When successful, the startapp function returns an integer greater than 2; when unsuccessful, it returns 2."

The return value of nil is incorrect. This function should never return nil. Did you also try (startapp "thisisnothing")? Startapp will fail in this case because there is no such program as "thisisnothing", so it cannot start the application. It should return a value indicating the failure, yet it also returns nil in that case. It always returns nil in Intellicad 10 PE Plus, which means it is impossible to tell if the application was started of not. This is clearly a bug in Intellicad 10 PE Plus.

Do you agree that this is a bug? Is it going to be fixed?