+2006-07-30 Andrew Skiba <andrews@mainsoft.com>
+
+ * FormView.cs: init BottomPagerRow.ItemIndex with 0; gracefully
+ handle null result of GetData().
+
2006-07-30 Andrew Skiba <andrews@mainsoft.com>
* FormView.cs: use TableStyle for ControlStyle.
}
if (showPager && PagerSettings.Position == PagerPosition.Bottom || PagerSettings.Position == PagerPosition.TopAndBottom) {
- bottomPagerRow = CreateRow (-1, DataControlRowType.Pager, DataControlRowState.Normal);
+ bottomPagerRow = CreateRow (0, DataControlRowType.Pager, DataControlRowState.Normal);
InitializePager (bottomPagerRow, dataSource);
table.Rows.Add (bottomPagerRow);
}
OnItemInserting (args);
if (!args.Cancel) {
DataSourceView view = GetData ();
- if (view == null) throw new HttpException ("The DataSourceView associated to data bound control was null");
+ if (view == null)
+ return;
view.Insert (currentEditNewValues, new DataSourceViewOperationCallback (InsertCallback));
} else
EndRowEdit ();