• 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 TazoTodua, Today, 02:10 AM
    1 response
    5 views
    0 likes
    Last Post TazoTodua  
    Started by vhjscv, Yesterday, 10:31 PM
    0 responses
    9 views
    0 likes
    Last Post vhjscv
    by vhjscv
     
    Started by buick, Yesterday, 09:37 PM
    0 responses
    6 views
    0 likes
    Last Post buick
    by buick
     
    Started by Hagar, Yesterday, 07:12 PM
    0 responses
    9 views
    0 likes
    Last Post Hagar
    by Hagar
     
    Started by jtrading82, Yesterday, 01:55 PM
    4 responses
    30 views
    0 likes
    Last Post bppayne
    by bppayne
     
    Working...
    X