![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Jan 2012
Posts: 5
Thanks: 1
Thanked 2 times in 2 posts
|
I cannot find the problem with this indicator - I was literally following someone doing a webinar and for the life cannot see what is wrong.
error - "Cannot implicitly convert type 'double' to 'NinjaTrader.Data.DataSeries' Line 95 Can someone please help me out. Now when I create another separate Indicator - and try to compile - it gives me the same error and references the above indicator. Any help would be appreciated I have attached the indicator. Thanks, |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Hi scott,
The compile error is caused by this section: Code:
[Browsable(false)] // this line prevents the data series from being displayed in the indicator properties dialog, do not remove
[XmlIgnore()] // this line ensures that the indicator can be saved/recovered as part of a chart template, do not remove
public DataSeries Signal
{
get { return _signal[0]; }
}
The structure for that section of code would be needed if you wanted to expose the value of _signal from another indicator, using the public Signal that's linked to it. If you want to maintain this functionality, try with this change: Code:
[Browsable(false)] // this line prevents the data series from being displayed in the indicator properties dialog, do not remove
[XmlIgnore()] // this line ensures that the indicator can be saved/recovered as part of a chart template, do not remove
public DataSeries Signal
{
get { return _signal; }
}
Ryan M
NinjaTrader Customer Service |
|
|
|
|
The following user says thank you to NinjaTrader_RyanM for this post: |
|
|
|
#3 |
|
Junior Member
Join Date: Jan 2012
Posts: 5
Thanks: 1
Thanked 2 times in 2 posts
|
Ryan - figured it out - thank you that was it.
Last edited by scott__; 02-24-2012 at 01:47 PM.
|
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
What should I be looking for? For help resolving your compile errors, please see my last reply for two different approaches.
Ryan M
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Junior Member
Join Date: Jan 2012
Posts: 5
Thanks: 1
Thanked 2 times in 2 posts
|
sorry - my lack of understanding at this point lead to the response. I made the change you recommended and all is good
Thanks again |
|
|
|
|
The following user says thank you to scott__ for this post: |
|
|
|
#6 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Great that took care of it. Thanks for updating us!
Ryan M
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Daily indicator, Minute Input Series (Beginner question) | markus1000 | Indicator Development | 7 | 01-27-2012 12:32 PM |
| Beginner Help with Backtesting | IN0V8R | Charting | 3 | 04-20-2011 11:09 AM |
| Beginner strategy | w84larisa | Strategy Development | 2 | 05-04-2010 08:48 AM |
| Beginner | Drake60 | Installation and Licensing | 1 | 01-14-2005 03:37 AM |