Intersoft WebGrid Documentation
How-to: Set default text for specific columns
See Also Send comments on this topic.

Glossary Item Box

WebGrid can assign default values to the NewRow interface when user clicks on the NewRow area.

In this topic, you will learn how to set default text for specific columns when adding new row.

To set default text for specific columns

  1. Open WebGrid.NET Designer and click See all properties.
  2. Set AllowAddNew to Yes, AllowEdit to Yes, MarkDefaultValueAsDirty to False and NewRowLostFocusAction to AlwaysPrompt.
  3. Go to Advanced tab. Select Columns and choose ContactName.
  4. Set DefaultValue to Maria.
  5. Run the project. When you click on the NewRow, WebGrid will automatically assign value "Maria" on ContactName column.

See Also

©2012 Intersoft Solutions Corp. All Rights Reserved.