コード例 #1
0
 public void SendEmail(Communicator.EmailMsg Msg, bool AdminMail)
 {
 }
コード例 #2
0
        void marketOrder_onOrderSend(object sender, MarketOrder.OrderSendEvent e)
        {
            if (e.Success)
            {
                EmailMsg msg = new EmailMsg();
                msg.Title = "New Trade";
                msg.Body = "an Order was generated and sucessfully send to the Market. \n" + e.Trade.ToString() +
                  "go to " + @"http://www.alsitm.com/Trades.aspx" + " to view trade history\n"
                            + @"http://www.alsitm.com/charts/Statssummary.html" + " to view profit summary chart\n"
                            + @"http://www.alsitm.com/charts/TradeHistory.html" + " to view trade history chart\n"
                            + @"http://www.alsitm.com/charts/TradeDifference.html" + " to view actual trade difference chart";

                SmsMsg sms = new SmsMsg()
                {
                    text="New Order",
                };
                DoStuff.Email.SendEmail(e.Trade, msg, false);
                DoStuff.SMS.SendSms(e.Trade,sms , false);
                WebUpdate.SendOrder(e.Trade, false);
                WebUpdate.SendOrderToWebDB(e.Trade);
            }
            else
            {
                EmailMsg msg = new EmailMsg();
                msg.Title = "Trade input Failed";
                msg.Body = "an Order was generated but could not be send to Excel. \n" + e.Trade.ToString();

                SmsMsg sms = new SmsMsg()
                {
                    text = "Order Submission Failed",
                };                
                DoStuff.SMS.SendSms(e.Trade, sms, true);
                DoStuff.Email.SendEmail(e.Trade, msg, true);
            }
        }
コード例 #3
0
 public static void SendEmail(Trade trade, EmailMsg Msg, bool AdminEmail)
 {
     _Msg = Msg;
     _EmailTrade = trade;
     _Admin = AdminEmail;
     BW = new BackgroundWorker();
     BW.DoWork += new DoWorkEventHandler(BW_DoWork);
     BW.RunWorkerAsync();
 }
コード例 #4
0
        void marketOrder_onOrderMatch(object sender, MarketOrder.OrderMatchEvent e)
        {
            EmailMsg msg = new EmailMsg();
            msg.Title = "Order Matched";
            msg.Body = e.Trade.ToString();
            WebUpdate.SendOrder(e.Trade, true);
            SmsMsg sms = new SmsMsg()
            {
                text = "Order Matched",
            };
            DoStuff.SMS.SendSms(e.Trade, sms, true);
            DoStuff.Email.SendEmail(e.Trade, msg, true);
            WebUpdate.SendOrderToWebDB(e.Trade);

        }