![]() |
|
|||||||
| NinjaScript File Sharing Discussion Discussion for shared NinjaScript files. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
Hello.
Does anybody know why i can't get my arrows closer to candles on any European market? On any American market is everything OK. 1st picture is European market FGBL. Second NQ. My code is too long for this post. You can find it text format as a attachment. I would be grateful for any help. THANK YOU. Thank you so much. GE.
|
|
|
|
|
|
#2 |
|
Senior Member
Join Date: Dec 2007
Location: Atlanta
Posts: 281
Thanks: 0
Thanked 4 times in 3 posts
|
Try replacing all DrawArrow code:
DrawArrowDown("Down" + CurrentBar, true, 0, High[0] + 1, Color.Red); With: DrawArrowDown("Down" + CurrentBar, true, 0, High[0] + 1*TickSize, Color.Red); thereby creating arrows that are set a fixed number of ticks from the bar |
|
|
|
|
|
#3 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Thanks for this useful advise TAJTrades!
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#4 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
Thank you for your time but it did not work.
As you can see on my pictures it works on US market, but not on European ![]() No clue why. Thank you for any help. |
|
|
|
|
|
#5 |
|
Member
Join Date: May 2007
Posts: 71
Thanks: 0
Thanked 0 times in 0 posts
|
It should work. Try replacing ALL DrawArrow (Up and Down) and DrawText with n*TickSize and vary the value 'n'.
|
|
|
|
|
|
#6 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
|
|
|
|
|
|
#7 | |
|
Senior Member
Join Date: Jan 2008
Location: Madrid, Spain
Posts: 229
Thanks: 2
Thanked 0 times in 0 posts
|
Quote:
Hello, try 1.0 * TickSize. Code:
DrawArrowDown("Down" + CurrentBar, true, 0, High[0] + 1.0*TickSize, Color.Red);
|
|
|
|
|
|
|
#8 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
|
|
|
|
|
|
#9 |
|
Senior Member
Join Date: Jan 2008
Location: Madrid, Spain
Posts: 229
Thanks: 2
Thanked 0 times in 0 posts
|
CS0103 is an error about variables declaration.
The sentence: Code:
DrawArrowDown("Down" + CurrentBar, true, 0, High[0] + 1.0*TickSize, Color.Red);
I think that your code have an error in other place, but not in DrawArrowDown ... If you post the code maybe I could help you. |
|
|
|
|
|
#10 | |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
Quote:
|
|
|
|
|
|
|
#11 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Hi, try using TickSize (remember NinjaScript is case sensitive), then your posted code should work.
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#12 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
|
|
|
|
|
|
#13 |
|
Member
Join Date: Nov 2008
Posts: 62
Thanks: 0
Thanked 0 times in 0 posts
|
|
|
|
|
|
|
#14 |
|
Junior Member
Join Date: Apr 2008
Posts: 20
Thanks: 0
Thanked 1 time in 1 post
|
Hi there. Here is your zip file.
Last edited by genius75; 01-05-2009 at 02:18 AM.
|
|
|
|
|
|
#15 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Great you got it working, a happy 2009 to you as well.
To export a NinjaScript file go to File > Utilities > Export NinjaScript. To get rid of any prorgramming errors showing up in your files then, please see this tip - http://www.ninjatrader-support2.com/...ead.php?t=4678
Bertrand
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| system.math | DaveS | General Programming | 5 | 12-07-2008 03:39 PM |
| using System.Data | pauljff | General Programming | 5 | 10-05-2008 02:55 PM |
| multi-time frame code and entry code | Mark_486 | General Programming | 1 | 05-15-2008 11:54 AM |
| Trading System | abikambic | General Programming | 1 | 03-18-2008 06:22 AM |
| Code->test/debug->change code->retest ... cycle process | bbarroux | Strategy Development | 3 | 10-02-2007 12:44 PM |