NinjaTrader Support Forum  

Go Back   NinjaTrader Support Forum > NinjaScript File Sharing > NinjaScript File Sharing Discussion

NinjaScript File Sharing Discussion Discussion for shared NinjaScript files.

Reply
 
Thread Tools Display Modes
Old 02-20-2011, 12:57 PM   #1
rem77
Junior Member
 
Join Date: Jun 2010
Posts: 15
Thanks: 0
Thanked 0 times in 0 posts
Default draw a line + sound alert when this line is crossed ?

Hi,

I would like to draw a line and to hear a sound alert when this line is crossed.
do you know how to do this ( or maybe there is some indicator doing this ) ?

Thanks for your help.
Regards
rem77 is offline  
Reply With Quote
Old 02-20-2011, 01:13 PM   #2
NinjaTrader_Bertrand
NinjaTrader Customer Service
 
NinjaTrader_Bertrand's Avatar
 
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
Default

rem77, for just an alert on crossing a price level set you could check into the Price Alert indicators published here on the forums in our sharing section - http://www.ninjatrader.com/support/f...splay.php?f=37

With NT7 you could monitor a hand drawn line and then 'get' it's ending value programmatically and issue then an alert via PlaySound() or Alert() if this value is crossed by price -

http://www.ninjatrader.com/support/h...7/drawline.htm
NinjaTrader_Bertrand is offline  
Reply With Quote
Old 02-20-2011, 03:40 PM   #3
rem77
Junior Member
 
Join Date: Jun 2010
Posts: 15
Thanks: 0
Thanked 0 times in 0 posts
Default

Hi Bertrand,

thank you for the answer.
To "monitor a hand drawn line" is just what I would like. Unfortunately my programming knowledge in NT7 is at 0 stage and I can not find any indicator doing this.

Assuming that it is not too complicated, could somebody code such an indicator ?

Thanks in advance
rem77

PS
Bertrand,
would it be possible to add to the next version of NT7:
an alert feature to hand drawn line properties, where this alert would be activated in case of crossing of this line ?
rem77 is offline  
Reply With Quote
Old 02-21-2011, 12:18 AM   #4
NinjaTrader_Bertrand
NinjaTrader Customer Service
 
NinjaTrader_Bertrand's Avatar
 
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
Default

Thanks for the suggestion rem77, this is already on our list for future consideration.
NinjaTrader_Bertrand is offline  
Reply With Quote
Old 05-10-2012, 02:26 PM   #5
rickmaz
Junior Member
 
Join Date: May 2011
Posts: 4
Thanks: 0
Thanked 0 times in 0 posts
Default was wondering

I was wondering about this also. I would really help but what i need is the ability to set a high and low value via a line or whatever and be alerted audible and maybe even email (email not necessary) but the key to my request is i need to have it set to alert me when the price closes ABOVE my high line or BELOW my low line on a close of the candle or time period whether it be a 3m 15 min or 30 min chart. alert on price hit is good too but more important is alert on price close above or below set range.
rickmaz is offline  
Reply With Quote
Old 05-10-2012, 02:35 PM   #6
NinjaTrader_Brett
NinjaTrader Customer Service
 
NinjaTrader_Brett's Avatar
 
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
Default

Rick,

You should be able to do this already in NinjaTrader.

Right click on the chart and add the Price Alert. Here you type in the price you want an alert and set calculate on bar close to true instead of false. You will get a sound alert when this line is hit and this way the alert will only trigger when the bar closes.

-Brett
NinjaTrader_Brett is offline  
Reply With Quote
Old 05-10-2012, 02:37 PM   #7
NinjaTrader_RyanM
NinjaTrader Customer Service
 
NinjaTrader_RyanM's Avatar
 
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
Default

Thanks for the post rickmaz. I created an indicator here that can help alert on crossing of manually drawn lines. Apply it to a chart and then and it will check if any of your lines are eligible (must set one point in past and one point in future). If price crosses it raises alert to File > New > Alerts window.
http://www.ninjatrader.com/support/f...d=4&linkid=472
NinjaTrader_RyanM is offline  
Reply With Quote
Old 07-13-2012, 08:57 AM   #8
rickmaz
Junior Member
 
Join Date: May 2011
Posts: 4
Thanks: 0
Thanked 0 times in 0 posts
Default

thanks, I am wondering. is there option to set the alert to trigger only when the bar closed. Anotherwards I want it to close above or below a line not just cross it.
rickmaz is offline  
Reply With Quote
Old 07-13-2012, 09:08 AM   #9
NinjaTrader_RyanM
NinjaTrader Customer Service
 
NinjaTrader_RyanM's Avatar
 
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
Default

Yes, you could set CalculateOnBarClose = true (each indicator has this setting) and it will only check for crosses on bar close.
NinjaTrader_RyanM is offline  
Reply With Quote
Old 09-20-2012, 08:03 PM   #10
bxstr106
Junior Member
 
Join Date: May 2012
Posts: 2
Thanks: 0
Thanked 3 times in 2 posts
Default Line Alert

You can draw a trend line or a horizontal line and when is cross a alarm will set!LineAlert.zip

ES 12-12 (5 Min) 2012-09-20.jpg
bxstr106 is offline  
Reply With Quote
The following user says thank you to bxstr106 for this post:
Old 10-11-2012, 08:59 AM   #11
bougie
Member
 
Join Date: Feb 2011
Posts: 55
Thanks: 9
Thanked 2 times in 2 posts
Default

Does this work for a window that just had an indicator in it? For example, I have a window with just RSI, and would like it to make an alert once the line is crossed. I can only get it to work on a chart with price bars.

Thanks.
bougie is offline  
Reply With Quote
Old 04-29-2013, 07:43 PM   #12
mickael28
Junior Member
 
Join Date: Mar 2013
Posts: 17
Thanks: 5
Thanked 0 times in 0 posts
Default

Quote:
Originally Posted by NinjaTrader_RyanM View Post
Thanks for the post rickmaz. I created an indicator here that can help alert on crossing of manually drawn lines. Apply it to a chart and then and it will check if any of your lines are eligible (must set one point in past and one point in future). If price crosses it raises alert to File > New > Alerts window.
http://www.ninjatrader.com/support/f...d=4&linkid=472

Hello,

This would be my 1st indicator, how do you use it?

I imported it successfully (I was prompted during the installation that some of my local files were more up to date, so I didn't overwrite them). After that it said that the installation had been successful.

Then I went to the indicators and picked a Price Alert indicator where I can enter a specific price.

But... how will this work with every line, horizontal line, etc that I draw? I've just draw a few and there's no alert when the price closes above it?
mickael28 is offline  
Reply With Quote
Reply

Tags
alert, line, trendline

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Draw Line Help safetrading Indicator Development 2 01-20-2011 02:33 PM
Alert on line fskidd Version 7 Beta General Questions & Bug Reports 1 01-12-2010 07:16 AM
line alert achiever Miscellaneous Support 3 09-23-2009 03:13 PM
Can draw dot, arrow, etc. but cannot draw line cunparis Strategy Development 10 03-21-2009 01:44 AM
how to draw a parallel line to a trend line? tradewiz Charting 4 12-19-2007 04:42 AM


All times are GMT -6. The time now is 03:18 PM.