[EMAIL PROTECTED] wrote:
Joao Morais wrote:
s := 'hello world';
vsound.speak(s);
speaks using a literal but says randomic words (sometimes says
nothing) using a variable. Is there something that I am missing?
You should use a variable of type WideString:
VAR
S: WideString;
And all
Marco van de Voort wrote:
{$mode objfpc}{$H+}
uses
comobj;
var
vsound: olevariant;
s: string;
begin
vsound := createoleobject('SAPI.SpVoice');
writeln('playing using literal');
vsound.speak('hello world');
writeln('ok (press enter)');
readln;
writeln('now playing using
>
> {$mode objfpc}{$H+}
> uses
>comobj;
> var
>vsound: olevariant;
>s: string;
> begin
>vsound := createoleobject('SAPI.SpVoice');
>writeln('playing using literal');
>vsound.speak('hello world');
>writeln('ok (press enter)');
>readln;
>writeln('now playing using
Joao Morais wrote:
s := 'hello world';
vsound.speak(s);
speaks using a literal but says randomic words (sometimes says nothing)
using a variable. Is there something that I am missing?
You should use a variable of type WideString:
VAR
S: WideString;
And all will be good
Hello,
the following code:
{$mode objfpc}{$H+}
uses
comobj;
var
vsound: olevariant;
s: string;
begin
vsound := createoleobject('SAPI.SpVoice');
writeln('playing using literal');
vsound.speak('hello world');
writeln('ok (press enter)');
readln;
writeln('now playing using a stri