Exemple #1
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             BullPutSpread bullputspread = context.BullPutSpreads.Find(identifier);
             context.Entry(bullputspread).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #2
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             WeekCandlestick weekcandlestick = context.WeekCandlesticks.Find(identifier);
             context.Entry(weekcandlestick).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #3
0
        public static int Save(BullPutSpread bullputspread)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(bullputspread).State = bullputspread.IsNew ?
                                                     EntityState.Added :
                                                     EntityState.Modified;

                context.SaveChanges();

                return(bullputspread.Identifier);
            }
        }
        public static int Save(WeeklyIncomeComboCount weeklyincomecombocount)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(weeklyincomecombocount).State = weeklyincomecombocount.IsNew ?
                                                              EntityState.Added :
                                                              EntityState.Modified;

                context.SaveChanges();

                return(weeklyincomecombocount.Identifier);
            }
        }
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             FutureContract futurecontract = context.FutureContracts.Find(identifier);
             context.Entry(futurecontract).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
        public static int Save(TradeTicket tradeticket)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(tradeticket).State = tradeticket.IsNew ?
                                                   EntityState.Added :
                                                   EntityState.Modified;

                context.SaveChanges();

                return(tradeticket.Identifier);
            }
        }
        public static int Save(WeeklyIncomeActionPlan weeklyincomeactionplan)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(weeklyincomeactionplan).State = weeklyincomeactionplan.IsNew ?
                                                              EntityState.Added :
                                                              EntityState.Modified;

                context.SaveChanges();

                return(weeklyincomeactionplan.Identifier);
            }
        }
Exemple #8
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             Call call = context.Calls.Find(identifier);
             context.Entry(call).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #9
0
        public static int Save(PairCondor paircondor)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(paircondor).State = paircondor.IsNew ?
                                                  EntityState.Added :
                                                  EntityState.Modified;

                context.SaveChanges();

                return(paircondor.Identifier);
            }
        }
Exemple #10
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             RiskParameters riskparameters = context.RiskParameters.Find(identifier);
             context.Entry(riskparameters).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #11
0
        public static int Save(Call call)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(call).State = call.IsNew ?
                                            EntityState.Added :
                                            EntityState.Modified;

                context.SaveChanges();

                return(call.Identifier);
            }
        }
Exemple #12
0
        public static int Save(RiskParameters riskparameters)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(riskparameters).State = riskparameters.IsNew ?
                                                      EntityState.Added :
                                                      EntityState.Modified;

                context.SaveChanges();

                return(riskparameters.Identifier);
            }
        }
Exemple #13
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             OptionDate optiondate = context.OptionDates.Find(identifier);
             context.Entry(optiondate).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #14
0
        public static int Save(OptionDate optiondate)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(optiondate).State = optiondate.IsNew ?
                                                  EntityState.Added :
                                                  EntityState.Modified;

                context.SaveChanges();

                return(optiondate.Identifier);
            }
        }
Exemple #15
0
        public static int Save(EconomicEvent economicevent)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(economicevent).State = economicevent.IsNew ?
                                                     EntityState.Added :
                                                     EntityState.Modified;

                context.SaveChanges();

                return(economicevent.Identifier);
            }
        }
Exemple #16
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             PairCondor paircondor = context.PairCondors.Find(identifier);
             context.Entry(paircondor).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #17
0
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             EconomicEvent economicevent = context.EconomicEvents.Find(identifier);
             context.Entry(economicevent).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
        public static int Save(Security security)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(security).State = security.IsNew ?
                                                EntityState.Added :
                                                EntityState.Modified;

                context.SaveChanges();

                return(security.Identifier);
            }
        }
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             TradeTicket tradeticket = context.TradeTickets.Find(identifier);
             context.Entry(tradeticket).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             Security security = context.Securities.Find(identifier);
             context.Entry(security).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             WeeklyIncomeActionPlan weeklyincomeactionplan = context.WeeklyIncomeActionPlans.Find(identifier);
             context.Entry(weeklyincomeactionplan).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
Exemple #22
0
        public static int Save(WeekCandlestick weekcandlestick)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(weekcandlestick).State = weekcandlestick.IsNew ?
                                                       EntityState.Added :
                                                       EntityState.Modified;

                context.SaveChanges();

                return(weekcandlestick.Identifier);
            }
        }
 public static void Delete(int identifier)
 {
     using (TradeProAssistantContext context = new TradeProAssistantContext())
     {
         try
         {
             WeeklyIncomeComboCount weeklyincomecombocount = context.WeeklyIncomeComboCounts.Find(identifier);
             context.Entry(weeklyincomecombocount).State = EntityState.Deleted;
             context.SaveChanges();
         }
         catch { }
     }
 }
        public static int Save(FutureContract futurecontract)
        {
            using (TradeProAssistantContext context = new TradeProAssistantContext())
            {
                context.Entry(futurecontract).State = futurecontract.IsNew ?
                                                      EntityState.Added :
                                                      EntityState.Modified;

                context.SaveChanges();

                return(futurecontract.Identifier);
            }
        }