Trusted by the world’s leading companies
Overview
The Syncfusion .NET Excel library offers comprehensive support for data validation. It enables users to enforce predefined rules that restrict the type and format of data that can be entered into a cell.
Data Validation Code Example
This example code shows how to add dropdown list validation toan Excel worksheet using the Syncfusion .NET Excel library with just a few lines of C# code.
Key features of data validation
Discover how data validation in the Excel Library enables control over data entry, ensuring that input meets defined criteria to maintain accuracy and consistency within Excel worksheets.
Text length validation
Users can restrict the text length in a cell, ensuring data meets defined character limits and preventing errors in the worksheet.
Time validation
Restrict the entry of time values within a specified range, ensuring data accuracy when working with time-related data.
List validation
Create a dropdown list of predefined values, allowing selection from specific options to ensure consistency and reduce input errors.
Number validation
Restrict the cell input to numbers within a specified range, ensuring that only valid numerical values are entered for accurate data analysis.
Date validation
Restrict the entry of dates to within a specified range, to maintain data accuracy when dealing with date-sensitive information.
Custom validation
Define custom rules using formulas to validate data entry, providing flexibility in enforcing specific criteria that fit your needs.
Explore Data Validation References
Discover valuable resources from our blog and knowledge base articles to enhance your efficiency in using data validation.
Knowledge base
How to create list data validation for more than 255 characters in C# VB.NET?
Knowledge base
How to set DataRange for data validation from a different sheet using C# VB.NET?
Knowledge base
How to create multiple dependent dropdown lists with multi-selection in an Excel document using C#
Explore these resources for comprehensive guides, knowledge base articles, insightful blogs, and ebooks.
Product Updates
Technical Support
Frequently Asked Questions
Can I set text length data validation using the Syncfusion Excel library?
Yes, you can set text length data validation using the Syncfusion Excel library. This functionality lets users to specify the length of text allowed in a cell or range of cells within an Excel workbook.
Can I add list values from specific cell ranges using the Syncfusion Excel library?
Yes. You can select any cell range within the workbook to create list validation.
Can I add an error box title in data validation?
Yes. You can customize the title of the error box dialogue in data validation.
Is it possible to set the data validation rule to use only whole numbers?
Yes. You can set the cell data validation to use only whole numbers so that it accepts only whole number values.
Can I create a dropdown using the Syncfusion Excel library?
Yes, you can use list validation to create a dropdown in the Excel document with a predefined range of values.
Can I add a tooltip message to the data validation cells using the Syncfusion Excel library?
Yes. You can provide an input message to the user as a tooltip in the Excel cells.
Is it possible to use Excel functions in the data validation formulas?
Yes. You can use any Excel function in the formula to validate the cell value.
Our Customers Love Us
Here are some of their experiences.
Want to create, View, and edit Excel files in C# or VB.NET?
No credit card required.
Awards
Greatness—it’s one thing to say you have it, but it means more when others recognize it. Syncfusion® is proud to hold the following industry awards.