private void loadToQuestionSet(Section value) { var questionSetToLoad = questionContextTo.Load(questionContextTo.GetQuestionsForSectionsQuery(value.SectionId)); questionSetToLoad.Completed += new System.EventHandler(questionSetToLoad_Completed); }
/// <summary> /// Устаревший метод для добавления новых объектов в набор EntitySet Sections. Взамен можно использовать метод .Add связанного свойства ObjectSet<T>. /// </summary> public void AddToSections(Section section) { base.AddObject("Sections", section); }
public bool OnCanDeleteSection(Section section) { return section != null; }
/// <summary> /// Создание нового объекта Section. /// </summary> /// <param name="sectionId">Исходное значение свойства SectionId.</param> /// <param name="name">Исходное значение свойства Name.</param> /// <param name="bookId">Исходное значение свойства BookId.</param> public static Section CreateSection(global::System.Int32 sectionId, global::System.String name, global::System.Int32 bookId) { Section section = new Section(); section.SectionId = sectionId; section.Name = name; section.BookId = bookId; return section; }
public void OmDeleteSection(Section section) { section.IsDeleted = true; var sectionSubmitionResult = sectionContext.SubmitChanges(); sectionSubmitionResult.Completed += new EventHandler(sectionSubmitionResult_Completed); }