Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Sound Alert Help

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Sound Alert Help

    Dear Support,
    Hi, ChelseaB,

    I have used similar code to the following for generating sound alerts for many indicators. In this case the alert Draw.Text and and Draw.Line are fine and drawn in both chart and market analyzer, however the sound alert is not played.

    I am using a daily and 5M chart, the last NT8 version, and my sound file is located in the default NT location.

    Anything changed in the most recent NT version or something wrong with the Alert line code?

    Code:
    // Draw Divergences
    
    [COLOR=#e74c3c]private string         alert3Sound             = NinjaTrader.Core.Globals.InstallDir+@"\sounds\RegularDivergence.wav";[/COLOR]
    
    Draw.Line(this,"dive1"+ (showHistory ? CurrentBar.ToString() : ToString()), false, CurrentBar - lastlobar, lastlo, CurrentBar-prevlobar, prevlo, Brushes.DarkGreen, DashStyleHelper.Dot, 1);
    Draw.Text(this,"rgdBuy"+ (showHistory ? CurrentBar: 0), IsAutoScale,"rgd".ToString(), CurrentBar -(lastlobar+prevlobar)/2, (prevlo+lastlo)/2,-10, Brushes.DarkGreen, textFont, TextAlignment.Center, Brushes.Transparent, Brushes.Transparent, 0);
    
    DivergenceDetect[0] = 1;
    
    [COLOR=#e74c3c]Alert("rgdUp", Priority.High,Instrument.MasterInstrument.Name + " "+BarsPeriod.ToString() + " RGD Buy" , alert3Sound, rearmTime, Brushes.DarkGreen,Brushes.GreenYellow);[/COLOR]

    #2
    Hello aligator,

    Thank you for your post.

    Do any sounds come from the platform? If not, it may be muted in your volume settings for Windows.

    If you run a compile in the editor, do you hear the compile completed sound?

    Thanks in advance; I look forward to assisting you further.

    Comment


      #3
      Originally posted by NinjaTrader_Kate View Post
      Hello aligator,

      Thank you for your post.

      Do any sounds come from the platform? If not, it may be muted in your volume settings for Windows.

      If you run a compile in the editor, do you hear the compile completed sound?

      Thanks in advance; I look forward to assisting you further.
      Yes to all your questions. As I said earlier, other actions based on the same conditions (i.e. Draw.Text, Draw.Line) work fine. Only the sound Alert will not sound.

      Comment


        #4
        Hello aligator,

        Thank you for your reply.

        Do you receive any kind of error message in the log regarding the sound? If so, what is the full text of the error?

        If you go to the Program Files (x86) > NinjaTrader 8 > Sounds folder is the RegularDivergence.wav file located in that folder? If you click it in that folder and open it in your sound file player of choice, does the sound play?

        Thanks in advance; I look forward to assisting you further.

        Comment


          #5
          Originally posted by NinjaTrader_Kate View Post
          Hello aligator,

          Thank you for your reply.

          Do you receive any kind of error message in the log regarding the sound? If so, what is the full text of the error?

          If you go to the Program Files (x86) > NinjaTrader 8 > Sounds folder is the RegularDivergence.wav file located in that folder? If you click it in that folder and open it in your sound file player of choice, does the sound play?

          Thanks in advance; I look forward to assisting you further.
          Thank you Kate, I resolved a misspelling issue.
          Last edited by aligator; 08-21-2020, 12:00 PM.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          597 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          343 views
          1 like
          Last Post Geovanny Suaza  
          Started by Mindset, 02-09-2026, 11:44 AM
          0 responses
          103 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by Geovanny Suaza, 02-02-2026, 12:30 PM
          0 responses
          556 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          555 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X