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

Bar object

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

  • NinjaTrader_Kate
    replied
    Hello Leeroy_Jenkins,

    Thank you for your reply.

    Using NinjaTrader.Data.Bar is not documented and we would recommend to pass your function the Open[0], High[0], Low[0], Close[0] and Time[0] values instead as cincai suggested.

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

    Leave a comment:


  • Leeroy_Jenkins
    replied
    Can someone from NT help with this please?
    I don't wanna pass OHLC values if it's possible to pass a bar.

    Leave a comment:


  • cincai
    replied
    Just use the default code will do

    Leave a comment:


  • cincai
    replied
    No need use those unnecessary thing.

    Just use
    High[0], Low[0], Close[0]. Open[0]

    The value Zero(0) indicator that current bar.

    When it is value of 2, it means 2 bar ago.

    Leave a comment:


  • thaison316
    started a topic Bar object

    Bar object

    I'm trying to pass the bar object to one of my function but "Cannot implicitly convert type double to Ninjatrader.data.bar"

    here code reads
    Code:
    Bar b = Bars[0];
    I'm just trying to pass the bar info (e.g., High, Low, Close, Open)

    what am I doing wrong?

    Thanks

Latest Posts

Collapse

Topics Statistics Last Post
Started by josh18955, 03-25-2023, 11:16 AM
6 responses
436 views
0 likes
Last Post Delerium  
Started by FAQtrader, Today, 03:35 PM
0 responses
5 views
0 likes
Last Post FAQtrader  
Started by rocketman7, Today, 09:41 AM
5 responses
18 views
0 likes
Last Post NinjaTrader_Jesse  
Started by frslvr, 04-11-2024, 07:26 AM
9 responses
127 views
1 like
Last Post caryc123  
Started by selu72, Today, 02:01 PM
1 response
14 views
0 likes
Last Post NinjaTrader_Zachary  
Working...
X