When I use this program, there's no way to stop it.
I've been thinking of measuring the character length with STRLEN of Phrase$ and denying any that are too long.
My question is how long is too long, and how short is too short?
Or is there a way of canceling the routine in the middle?
I've also been thinking of using SUBSTR to shorten the string length.
Code:(defun c:SayIt () (setq Phrase$ (getstring T "Enter string: ")) (setq Phrase$l (strlen Phrase$)) (if (< Phrase$l 256) (progn (vl-load-com) (setq sapi (vlax-create-object "Sapi.SpVoice")) (vlax-invoke sapi "Speak" Phrase$ 0) (vlax-release-object sapi) ));end progn/if (princ) );defun c:SayIt