Description
Indicator plays sound when price reach some level.
Parameters:
Price: the target price, 1.29345 for example
Spot price (Bid: 1, Ask: 2): type of spot price. If you want to play sound when Ask price reach the target price then specify 2. If you want to play sound when Bid price reach the target price then specify 1.
In order to hear the sound, please make sure that sounds are enable in your cTrader/cAlgo:
u
algotrader
Joined on 12.11.2012
- Distribution: Free
- Language: C#
- Trading platform: cTrader Automate
- File name: Price Alarm (Sound).algo
- Rating: 2.5
- Installs: 7574
- Modified: 13/10/2021 09:54
Comments
If anyone else has issues using yahoo change the port to 587 that solved my issues.
also see below for correct placement
Notifications.PlaySound(Path.Combine(windowsFolder, "Media", "tada.wav"));
>>>Notifications.SendEmail("fx.alert@yahoo.com.au", "fx.alert@yahoo.com.au", "Price Alert", "TRIGGERED");
triggered = true;
Is it possible to add an email notification to the indicator?
I found this but cant figure out where to place it:
Notifications.SendEmail("***@yahoo.com.au", "***@yhaoo.com.au", "Price Alert", "TRIGGERED");
Have tried a couple of locations in the code namely:
line after:
Notifications.PlaySound(Path.Combine(windowsFolder, "Media", "tada.wav"));
and
at the end of
public override void Calculate(int index)
{
if (triggered)
{
PlayedNotificationLine[index] = Price;
return;
either place i get a failed to send email in the log.
settings are correct as ctrader sends emails on open and close of trades, just cant get it to send with this indicator
Hello ForexShawn,
I'm not interested in payed work. Contact any of these guys: http://ctrader.com/consultants/.
Hi AlgoTrader,
Are you interested in developing cTrader indicators for mutually agreed upon $.
I would like to start with Price Alarm. There are several additions I would like to make to it
including:
a) Make it so the alarm line can be dragged into whatever position desired once it is on the chart
b) Change the alarm so it can be set to ring just once or multiple times
Thank you in advance for your feedback.
Could any one modify this code to sound an alarm with vertical/time lines?
Thanks
Notifications.PlaySound(@"C:\my file.mp3");
It doesn’t play the sound for me too.
Could you tell me how should I modify the code if I want to write the absolute path to the sound file, please?
So, instead of this row:
Notifications.PlaySound(Path.Combine(windowsFolder, "Media", "tada.wav"));
what should I write?
Thanks.
good work Algotrader. Very useful. I was wondering if it can be set to repeat the alarm until the user shuts it off. I'm a terrible programmer and your assistance would be greatly appreciated
Why does it need Unlimited Access?
(it asks for that, when you first apply it, which is a no-go for me)