Gets or sets a value that indicates whether you have provided your own data-management operations for the DataRepeater control.
Assembly: Microsoft.VisualBasic.PowerPacks (in Microsoft.VisualBasic.PowerPacks.dll)
Virtual mode is designed for use with large stores of data. When the True, you create a DataRepeater with a set number of items and then handle the ItemValueNeeded event to populate the items. Virtual mode requires implementation of an underlying data cache to handle the population, editing, and deletion of DataRepeater items based on actions of the user. For more information about how to implement virtual mode, see Virtual Mode in the DataRepeater Control.property is set to
The following code example demonstrates how to change the behavior of a DataRepeater control, depending on the value of the property. It assumes that you have a form that contains a DataRepeater control named DataRepeater1 that is bound to the Products table of the Northwind database.
Private Sub Form1_Load(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles MyBase.Load ' If the DataRepeater is in virtual mode, ' do not allow adds or deletes. If DataRepeater1.VirtualMode = True Then DataRepeater1.AllowUserToAddItems = False DataRepeater1.AllowUserToDeleteItems = False ' Disable the Add button. ProductsBindingNavigator.AddNewItem.Enabled = False ' Disable the Delete button. ProductsBindingNavigator.DeleteItem.Enabled = False End If End Sub
- 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.