Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How do I clear the alert window in code?

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

    How do I clear the alert window in code?

    Hi,

    When I load my indicator, I want to clear the alert window of all its contents, how do I do that?

    Thank you in advance.

    #2
    Hello KhaosTrader,

    Thank you for your post.

    There is no function in NinjaScript that is exposed to clear the alerts window in code. I will look into whether there is an undocumented means to perform this action from a NinjaScript object.

    Comment


      #3
      Thank you, looking forward to your findings.

      Comment


        #4
        Actually a better thing for me would be the ability to iterate through the entries of the AlertWindow, the goal would be to also be able to delete alerts that were older than 1 hour....

        Comment


          #5
          Hello KhaosTrader,

          Thank you for your response.

          Unfortunately, there would not be a means to clear the displayed alerts in the Alerts Log. I will forward this as a suggestion to development.

          Comment


            #6
            Hello KhaosTrader,

            Thank you for your patience.

            The request to remove alerts from the Alert Log in NinjaScript has been given the ID SFT-1643.

            Comment


              #7
              Hi,

              It would be better to be able to access the collection also.. This is because it might be handy to have your code delete the last X alerts or delete alerts older than X minutes, or delete all low priority alerts that are y minutes old.. etc...

              Comment


                #8
                Hello KhaosTrader,

                Access by time was added to the suggestion.

                Comment


                  #9
                  Actually, what I am saying, is also it would be good to be able to retrieve and iterate through the alerts such that you can delete particular alerts according to program logic, that would be most flexible..

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by jeronymite, 04-12-2024, 04:26 PM
                  3 responses
                  43 views
                  0 likes
                  Last Post jeronymite  
                  Started by frankthearm, Today, 09:08 AM
                  4 responses
                  10 views
                  0 likes
                  Last Post frankthearm  
                  Started by yertle, Today, 08:38 AM
                  5 responses
                  15 views
                  0 likes
                  Last Post NinjaTrader_BrandonH  
                  Started by adeelshahzad, Today, 03:54 AM
                  3 responses
                  18 views
                  0 likes
                  Last Post NinjaTrader_BrandonH  
                  Started by bill2023, Yesterday, 08:51 AM
                  6 responses
                  27 views
                  0 likes
                  Last Post NinjaTrader_Erick  
                  Working...
                  X