When working with a ListBox control, you can use the ___________ property to set the data field that serves as the value for each item.
- DataTextField
- DataValueField
- DataSource
- DataMember
The correct option is 2. DataValueField. This property is used to set the data field that serves as the value for each item in a ListBox control. It is essential for data binding and displaying meaningful values to users.
Loading...
Related Quiz
- The ___________ class is responsible for managing database connections efficiently.
- Which method is used to execute a non-query command and retrieve the number of rows affected?
- In LINQ to SQL, what is the purpose of the DataContext class?
- Connection pooling helps in efficiently managing and reusing database ___________.
- How does Entity Framework handle database schema changes in a Code-First approach?