• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

On Transition

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

    On Transition

    Can I call methods that download stuff from web sites and methods that loop through the historical data from the OnStateChange method State == State.Transition ?

    I need to get stuff done when all historical data have been loaded but before processing real time data.

    If not where should I put these methods ?

    Thanks

    #2
    Hello,

    Thank you for the question.

    In general if you are waiting for data to be loaded, you could use the DataLoaded state to know that the Data has been loaded. DataLoaded is called only once after all data series have been loaded. Following this state the Historical state should be run.

    You can certainly test with putting items like this in the various states, likely DataLoaded would be the earliest you could use to ensure the request is not sent when opening menus.

    With using these type of items, if you are doing requests synchronously you may see the user interface become sluggish or freeze during the request, so you may need to look into doing asynchronous requests as well. Unfortunately this would be outside what I can assist with but MSDN has many samples of web related syntax to get you started.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by imunitypills, Today, 12:52 AM
    1 response
    7 views
    0 likes
    Last Post marcus2300  
    Started by ttodua, Today, 02:59 AM
    0 responses
    5 views
    0 likes
    Last Post ttodua
    by ttodua
     
    Started by rikcybella, Today, 01:46 AM
    0 responses
    7 views
    0 likes
    Last Post rikcybella  
    Started by imunitypills, Today, 12:53 AM
    0 responses
    8 views
    0 likes
    Last Post imunitypills  
    Started by Marasty, Today, 12:28 AM
    0 responses
    5 views
    0 likes
    Last Post Marasty
    by Marasty
     
    Working...
    X