Assembly: Microsoft.VisualBasic.PowerPacks.Vs (in Microsoft.VisualBasic.PowerPacks.Vs.dll)
Use this method to display a new DataRepeaterItem at the bottom of the DataRepeater control. Data for the controls in the DataRepeaterItem will be blank unless a default value is supplied by the DataSourceChanged event or in the method.
When the AllowUserToAddItems property is set to True, users can also add a new DataRepeaterItem by clicking the BindingNavigatorAddNewItem ToolStripButton on the BindingNavigator control, or by pressing CTRL+N when a DataRepeaterItem has focus.
The following example demonstrates how to set default text in the method. It assumes that you have a form that contains a Button named AddNewButton and a bound DataRepeater control named DataRepeater1 that contains a TextBox control named ProductNameTextBox.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.