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

DLL Interface Ask() Method

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

  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your reply.

    If you're seeing data from both the example application and your custom application in the T&S window but not the chart, that seems more like a possible error in rendering the chart than a problem with the scripts themselves. At this point, I'd like to look at your log and trace files. Rather than post them here as they may contain personally identifiable information, please send them directly to us through the platform.

    You can send these by going to the Control Center-> Help-> Email Support

    Ensuring 'Log and Trace Files' is checked will include these files. This is checked by default.

    Please reference the following ticket number in the body of the email: 3206004 ATTN Kate W. with a link to this post in the body of the email as well.

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

    Leave a comment:


  • proptradingshop
    replied
    Hey Kate,

    No luck unfortunately. I tried the steps you mentioned above. I am able to get the data in the T & S window (can even get my custom app that is pushing data from Kraken to push to the T & S window) but can't get anything to show on the charts or hit OnMarketData().

    When I am NOT connected to the external data I am able to get data for MSFT on the chart perfectly fine.

    Please let me know if it would help if I do another video of creating a chart to see if I am missing something.

    Leave a comment:


  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your reply.

    Let's have you restart your PC, then start up NinjaTrader, open a MSFT chart, set the chart trading hours to Default 24/7 since we're outside of regular trading hours at this point, then connect to the Simulated Data Feed just to make sure there's not something weird going on with the charts themselves. Do you see bars on the chart?

    Once you've tested that, try restarting Visual Studio, connecting to the External Data Feed, and running the example project one more time with it set to historical.

    If you still don't see data, try setting the Data Series settings to Ask and then Bid instead of Last, rerunning the example project each time. Do either of those show bars on the chart if Last still doesn't work?

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

    Leave a comment:


  • proptradingshop
    replied
    Hi Kate,

    Name: MSFT, Type: Stock, Description: Microsoft Corporation under instrument window.

    Chart is set to last 1 min, you can review that in the video I posted.

    I was on 8.0.24.2 but upgraded but still can't get anything on the chart.


    Last edited by proptradingshop; 08-03-2021, 03:02 PM.

    Leave a comment:


  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your reply.

    To confirm, you haven't edited the project itself or changed the trading hours template listed for MSFT in the Instruments window, have you? It should be listed as US Equities RTH.

    Changing to ask or bid data would cause that not to be shown on the chart since that would show Last data with the settings you've got for the chart.

    I'm not sure it's anything specific to this instrument, though, since you're also having trouble with your crypto symbols with your own application.

    Let's make sure you're on the correct version of the platform - if you look under Help > About in the Control Center, what is the version number listed there? If it's anything other than 8.0.24.3, let's have you update to the latest version to make sure nothing weird from an older version might be causing the issue.

    To update NinjaTrader if necessary, please follow the steps below:
    • First, copy your license key from NinjaTrader under Help> License Key then exit NinjaTrader
    • Click on the link: https://ninjatrader.com/PlatformDirect
    • Enter your license key and press Submit
    • Select 'Download'
    • Critical: Before running the installer, ensure NinjaTrader is closed.
    If you're on the correct version already, let's have you run a repair on the installation. To run a repair, go to the uninstall a program section of the Windows control panel. Find NinjaTrader in the list, right click on it and select "Repair". If the repair is successful, please test with the example application again.

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

    Leave a comment:


  • proptradingshop
    replied
    Hey Kate,

    End date is set to 08/03/2021

    Yes...I was able to see the T & S info come into the window when clicking on the button in the external app.

    My goal was essentially to be able to get the data in the OnMarketData() method of my indicator that is applied to the chart and that does not seem to be working for me.

    I appreciate your effort & support.

    Leave a comment:


  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your reply.

    Generally speaking, we can see issues if you have NinjaTrader 7 running at the same time you're trying to use the external data feed, but I don't see that you've got that running from your video.

    Can you confirm what is shown for the chart end date when opening it?

    If you open a Time and Sales window and then run the example application, do you see data coming through there?

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

    Leave a comment:


  • proptradingshop
    replied
    Hi Kate, it does not seem to be working for me.
    1. I am set to external connection
    2. I have AT interface enabled
    3. I create a 1min chart on MSFT
    4. Run the application and hit send button
    5. I see the code being hit but cant see anything on the chart
    I have attached a link to a video below, maybe you can spot what I am doing wrong.

    Leave a comment:


  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your reply.

    Looks like those lines are already uncommented so you should be good to go there - I may have commented them out in my own install to test something and just didn't remember. Are you using historical as the option, and do you have an MSFT chart open prior to pressing the Send MSFT option?

    I've created a short video demonstrating the example:


    Please let us know if we may be of further assistance to you.

    Leave a comment:


  • proptradingshop
    replied
    Hi Kate,

    Thanks for the response, I ran the application...Can you specify in which file you are referring to uncomment the lines? I do not see any comments in the cs files. While running the application I placed some breakpoints on ToggleSend and can see the breakpoint being hit but don't see any data on the chart in NT. I have AT enabled and am connected to the external connection.

    Click image for larger version

Name:	nt-api.PNG
Views:	274
Size:	71.0 KB
ID:	1166244

    Leave a comment:


  • NinjaTrader_Kate
    replied
    Hello proptradingshop,

    Thank you for your post.

    The DLL interface is provided as-is and support is limited to the resources available below.

    DLL interface - https://ninjatrader.com/support/help.../functions.htm

    Example application (Unsupported example) - https://ninjatrader.com/support/foru...442#post514442

    Are you able to run the NT8API example from the link above and see data coming in when you select Historical and then Send MSFT? You'll need to uncomment lines 118-119 and 147-154 to see data on a chart. Please ensure you have the AT interface enabled under Tools > Options > Automatic Trading Interface and ensure you are connected to the External connection.

    Please let us know if we may be of further assistance to you.

    Leave a comment:


  • proptradingshop
    replied
    I even tried adding the following to a custom indicator to see if I can print the values, added the indicator to the chart for the (custom)symbol that I am pushing BID/ASK data to and do not get anything.

    Code:
    protected override void OnMarketData(MarketDataEventArgs e)
    {
    if (e.MarketDataType == MarketDataType.Last)
    Print("[OnMarketData] Last = " + e.Price + " " + e.Volume);
    else if (e.MarketDataType == MarketDataType.Ask)
    Print("[OnMarketData] Ask = " + e.Price + " " + e.Volume);
    else if (e.MarketDataType == MarketDataType.Bid)
    Print("[OnMarketData] Bid = " + e.Price + " " + e.Volume);
    }

    Leave a comment:


  • proptradingshop
    started a topic DLL Interface Ask() Method

    DLL Interface Ask() Method

    Hello,

    I am currently using the DLL interface to grab pricing from Kraken for some crypto symbols and trying to pass the BID/ASK data to NT. I am using the following methods in order to accomplish this.
    Code:
    int Ask(string instrument, double price, int size)
    int Bid(string instrument, double price, int size)

    When I call the above methods from my application I get a return value of 0 which indicates success but how can I see this data in NT?

    So for example I get XBT/EUR and convert the symbol name to XBT_EUR and call the above methods and get a return value of 0, but I can not see this data or the instrument inside NT, does the instrument already have to exist within NT?

    Thank you in advance for the support.
    Last edited by proptradingshop; 08-02-2021, 10:40 PM.

Latest Posts

Collapse

Topics Statistics Last Post
Started by Aviram Y, Today, 05:29 AM
0 responses
1 view
0 likes
Last Post Aviram Y  
Started by quantismo, 04-17-2024, 05:13 PM
3 responses
25 views
0 likes
Last Post NinjaTrader_Gaby  
Started by ScottWalsh, 04-16-2024, 04:29 PM
7 responses
34 views
0 likes
Last Post NinjaTrader_Gaby  
Started by cls71, Today, 04:45 AM
0 responses
6 views
0 likes
Last Post cls71
by cls71
 
Started by mjairg, 07-20-2023, 11:57 PM
3 responses
216 views
1 like
Last Post PaulMohn  
Working...
X