/// <summary> /// Raises the InsertObject event. /// </summary> internal void OnInsertObject(InsertObjectArgs e) { if (InsertObject != null) { InsertObject(this, e); } }
/// <summary> /// Implements the insert behavior for /// the control by raising the /// <see cref="YYTDataSource.InsertObject"/> event. /// </summary> /// <param name="values">The values from /// the UI that are to be inserted.</param> /// <returns>The number of rows affected.</returns> protected override int ExecuteInsert( IDictionary values) { // tell the page to insert the object InsertObjectArgs args = new InsertObjectArgs(values); _owner.OnInsertObject(args); return(args.RowsAffected); }