Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Trade Email

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

    Trade Email

    I am trading with NT8. Can I get an email when my Auto strategy has opened/closed a trade? if so how can i do this?

    #2
    Hello MichaelAlexander,

    Thank you for the post.

    You may use the SendMail() function to automate sending emails. You must configure an email account as a default "Mail" Share Service from the General Options before you use this.

    More on SendMail:
    https://ninjatrader.com/support/help.../?sendmail.htm

    More on configuring a share service (see "Managing Share Services"):
    https://ninjatrader.com/support/help...al_section.htm

    The function will be used like so:

    Code:
    EnterLong();
    SendMail("[email protected]", "Trade Alert", "Submit buy order");
    If we may be of any further assistance, please let us know.
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_ChrisL View Post
      Hello MichaelAlexander,

      Thank you for the post.

      You may use the SendMail() function to automate sending emails. You must configure an email account as a default "Mail" Share Service from the General Options before you use this.

      More on SendMail:
      https://ninjatrader.com/support/help.../?sendmail.htm

      More on configuring a share service (see "Managing Share Services"):
      https://ninjatrader.com/support/help...al_section.htm

      The function will be used like so:

      Code:
      EnterLong();
      SendMail("[email protected]", "Trade Alert", "Submit buy order");
      If we may be of any further assistance, please let us know.
      Hello,

      Is there any way to capture screenshot along with auto-email? Any "unsupported" code to do it?

      Looks like we need to use Automation library to activate particular control, then use "Drawing" library to capture screenshot and save locally, and then ShareService to attach image to the email. Any examples on how to accomplish first 2 steps?

      Thanks

      Comment


        #4
        Hello,

        Thank you for the reply.

        There is an undocumented way to do this.

        Please download the example indicator from this thread that takes a screenshot with NinjaScript, post #34:

        https://ninjatrader.com/support/foru...d.php?p=474845

        Note: You will need to add two namespaces to your Using declarations:

        using System.IO;
        using System.Windows.Media.Imaging;

        Creating a screenshot requires a three-step process:

        1.Get a chart object
        2.Call GetScreenshot() on that object to get a BitMap
        3.Save the result

        Then you can use the Share overload that takes a system path to the screenshot.

        Also, keep in mind that this example uses a Dispatcher to run the job asynchronously.

        Please let us know if you have any questions.
        Chris L.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by farzibopsu, Today, 11:52 AM
        0 responses
        4 views
        0 likes
        Last Post farzibopsu  
        Started by exjayess, Today, 11:04 AM
        1 response
        9 views
        0 likes
        Last Post NinjaTrader_ShawnB  
        Started by robertlaub, Today, 11:11 AM
        1 response
        3 views
        0 likes
        Last Post NinjaTrader_ShawnB  
        Started by sdauteuil, Today, 10:28 AM
        0 responses
        5 views
        0 likes
        Last Post sdauteuil  
        Started by KirkHammett, Today, 08:11 AM
        0 responses
        7 views
        0 likes
        Last Post KirkHammett  
        Working...
        X