Vote for a Text to voice function

Questions about MultiCharts and user contributed studies.
arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Vote for a Text to voice function

Postby arjfca » 24 Jan 2013

Hello

I did wrote a new function request to MC Project Manager about adding a new Text to Voice function

My goal is to be able to create a descriptive string about an actual setup on a specific chart or instrument and have it send as a voice message to the speaker

I got 3 chart opened with 2 instruments on each. When an alarm is triggered, witch setup or charts as created it???

To vote for:
https://www.multicharts.com/pm/viewissu ... no=MC-1230

Martin

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Vote for a Text to voice function

Postby TJ » 24 Jan 2013

Probably not difficult to do, because the TTS Text-to-Speech engine is already comes with the Windows Operating system. All it needs is a routine to invoke it.

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Vote for a Text to voice function

Postby TJ » 24 Jan 2013

at the mean time, you can add an alert which gives you a visual report via a pop up window:

Code: Select all

alert( "Divergence on " + text(barinterval:0:0) + " Chart");

arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Re: Vote for a Text to voice function

Postby arjfca » 24 Jan 2013

at the mean time, you can add an alert which gives you a visual report via a pop up window:

Code: Select all

alert( "Divergence on " + text(barinterval:0:0) + " Chart");
In fact, I did implement it this morning just after having post the request

It Show in the alert the chart definition

Code: Select all

Once begin
ClearDebug;
scale = scaleString;
Print (Scale);
end;

Alert( "Divergence in Top" + " " + Scale);
ScaleString Function:

Code: Select all

//ScaleString: Return a string of the scale in use
Var:
Scale("");

Scale = NumtoStr(Barinterval,0) + spaces(1);

Switch (bartype_ex) begin
Case = 1:
Scale = Scale + "Ticks";
Case = 2:
Scale = Scale +"Minutes";
Case = 3:
Scale = Scale + "Hours";
Case = 4:
Scale = Scale + "Days";
Case = 5:
Scale = Scale + "Weeks";
Case = 6:
Scale = Scale + "Months";
Case = 7:
Scale = Scale + "Years";
Case = 8:
Scale = Scale + "Volume";
Case = 9:
Scale = Scale + "Seconds";
Case = 10:
Scale = Scale + "Quarters";
Case = 11:
Scale = Scale + "Points";
Case = 12:
Scale = Scale + "Change";
Case = 13:
Scale = Scale + "Points";
default:
scale = scale + "Scale";
end; //Switch (bartype_ex) begin
ScaleString= scale;

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Vote for a Text to voice function

Postby TJ » 24 Jan 2013

Nice work. Thanks for sharing.



a small programming tip:
When declaring a string variable, use a $ suffix with the name. This will separate the numeric variables from the string variables, and will help you when you need to trace a bug later on.

eg:

Code: Select all

Var:
Scale$("");

arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Re: Vote for a Text to voice function

Postby arjfca » 24 Jan 2013

Nice work. Thanks for sharing.



a small programming tip:
When declaring a string variable, use a $ suffix with the name. This will separate the numeric variables from the string variables, and will help you when you need to trace a bug later on.

eg:

Code: Select all

Var:
Scale$("");
Very clever. Thanks for the tip

Martin

User avatar
CrazyNasdaq
Posts: 321
Joined: 02 Sep 2009
Location: ITALY
Has thanked: 98 times
Been thanked: 89 times

Re: Vote for a Text to voice function

Postby CrazyNasdaq » 24 Jan 2013

I suggest to modify the first string of the function this way to identify also the instrument and not only the timeframe resolution.

Code: Select all

Scale = text(symbol + " ") + NumtoStr(Barinterval,0) + spaces(1);
Thanks to arjfca for the work and for sharing


Return to “MultiCharts”