private void AddProject() { HEWDataContext context = new HEWDataContext(); Project projectObj = new Project(); projectObj.Name = txtName.Text.Trim(); projectObj.Description = txtDescription.Text.Trim(); projectObj.IsHome = cbIsHome.Checked; projectObj.IsSide = cbIsSideMenu.Checked; projectObj.CategoryID = Int16.Parse(ddlCategories.SelectedValue); context.Projects.InsertOnSubmit(projectObj); context.SubmitChanges(); Response.Redirect("Default.aspx"); }
private void detach_Projects(Project entity) { this.SendPropertyChanging(); entity.ProjectsCategory = null; }
private void attach_Projects(Project entity) { this.SendPropertyChanging(); entity.ProjectsCategory = this; }
partial void DeleteProject(Project instance);
partial void UpdateProject(Project instance);
partial void InsertProject(Project instance);