Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

how to sendmail() with current symbol and close price

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

    how to sendmail() with current symbol and close price

    how to sendmail() with current symbol and closing price when the condition is met?

    #2
    Try this post. Josh was very helpful

    NinjaTrader Customer Service



    Join Date: May 2007
    Location: Denver, CO
    Posts: 4,087



    Code:
    SendMail("[email protected]", "[email protected]", "Trade Alert", "Long strategy triggered on " + Instrument.MasterInstrument.Name + " in " + Bars.Period.Value + "-" + Bars.Period.Id + " time frame.");
    The body of your email would end up as something like this:
    "Long strategy triggered on ER2 in 1-Minute time frame."
    __________________

    Comment


      #3
      thanks...

      I also like to add current time and price when email was sent...how can i do that?

      Comment


        #4
        Hi tbtrades,

        Add Time[0] and Close[0] to your message string.

        Code:
        SendMail("[email protected]", "[email protected]", "Trade Alert", "Long strategy triggered on " + Instrument.MasterInstrument.Name + " in " + Bars.Period.Value + "-" + Bars.Period.Id + " time frame." + " Time: " + Time[0] + " Price: " + Close[0]);
        Josh P.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by hayleeabb, Today, 04:21 PM
        1 response
        5 views
        0 likes
        Last Post NinjaTrader_ShawnB  
        Started by mg.watts, Today, 03:17 PM
        1 response
        15 views
        0 likes
        Last Post NinjaTrader_ChrisL  
        Started by JTizz, Today, 01:20 PM
        1 response
        8 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by omermirza, Today, 12:39 PM
        2 responses
        13 views
        0 likes
        Last Post omermirza  
        Started by mballagan, Today, 01:02 PM
        1 response
        10 views
        0 likes
        Last Post NinjaTrader_Kate  
        Working...
        X