Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

BarRequest.Update

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

  • NinjaTrader_Jesse
    replied
    Hello,

    I just wanted to reply back on this item. While formulating a sample for development I noted that I was able to subscribe and unsubscribe at any given point while using a BarsRequest. Could you try the attached sample and see if you are also able to subscribe and unsubscribe? This is an indicator but uses the addon BarsRequest as you would from an addon. It adds two buttons to the toolbar of a chart which then subscribes to AAPL, please change the instrument in the code if needed.

    If this is simply that something was missed in your test and this works for you, I can close the ticket. Otherwise, if this is not working for you, please let me know and we can continue troubleshooting this.

    I look forward to being of further assistance.
    Attached Files

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Thank you for the post.

    I would need to put in a question to development if subscribing later is possible while using this event, Once I have a reply on that I will post back to this thread. This may take some time to get an answer for this item, so in the meantime, I would likely suggest to use the approach that works and then control the data from the update void logically. You could do this by simply using a bool condition to toggle if the logic should be enacted or not.

    I look forward to being of further assistance.

    Leave a comment:


  • GrumpyTrader
    started a topic BarRequest.Update

    BarRequest.Update

    I'm trying to understand the Update event in a BarRequest and how to subscribe / unsubscribe.

    a) If I call the Request method with the Update event already assigned I get the updates.but

    b) If I call the Request method without the Update event assigned and assign it later then I don't get the updates.

    I'm trying to create an addon where I can turn on and off updates on the fly. Any help would be appreciated.

Latest Posts

Collapse

Topics Statistics Last Post
Started by Karado58, 11-26-2012, 02:57 PM
8 responses
14,828 views
0 likes
Last Post Option Whisperer  
Started by Option Whisperer, Today, 09:05 AM
0 responses
1 view
0 likes
Last Post Option Whisperer  
Started by cre8able, Yesterday, 01:16 PM
3 responses
11 views
0 likes
Last Post cre8able  
Started by Harry, 05-02-2018, 01:54 PM
10 responses
3,204 views
0 likes
Last Post tharton3  
Started by ChartTourist, Today, 08:22 AM
0 responses
6 views
0 likes
Last Post ChartTourist  
Working...
X