this thing will drive you crazy with every tick even after the condition has passed.
if h crosses above whatever then PlaySound(C:\MultiCharts\whatever.wav");
so i am going to try
if h crosses above whatever and h[1]<whatever then PlaySound(C:\MultiCharts\whatever.wav");
all the settings for alerts are ignored i have found out they don't work for programed sounds. like play only once per bar.
PlaySound "STF UP" already! [SOLVED]
- Mark Brown
- Posts: 181
- Joined: 29 Nov 2016
- Has thanked: 111 times
- Been thanked: 17 times
- TJ
- Posts: 7740
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2221 times
Re: PlaySound "STF UP" already! [SOLVED]
Try this:
Code: Select all
Var:
intrabarpersist playonce(0);
if h crosses above wattever and playonce <> currentbar
then
begin
playonce = currentbar;
playsound("c:\soundfiles\wattever.wav");
end;
- TJ
- Posts: 7740
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2221 times