Site icon Ryadel

ASP.NET C# class to check for Italian Tax Code / Fiscal Code / VAT ID

Classe ASP.NET C# per il controllo e il calcolo formale del Codice Fiscale

There's no Italian programmer (or one who has worked in Italy) who has not had to deal at least once with Italian Tax Codes / Fiscal Codes: we literally run into them everytime we need to work on any context involving the management of someone's personal data: registries, flows, management, economic / financial calculation tools.

For this reason, many years ago, I developed a class in ASP.NET C # helper class that allows you to do most of these operations. Since after many years I continue to use it very much I think it may be useful to share it, in the hope that it will simplify the life of other fellow developers.

This post contains the ENGLISH version of the source code: the italian version is available here, together with a bunch of additional explanation regarding how the Italian Fiscal Codes actually work, including the algorythms that generates them and how to properly verify them: I won't be translating that part because I don't think it would be of any interest for non-italian readers. If you think you need these info, feel free to contact us using the Comments section below this post and we'll be pleased to fill that gap.

That said, here's the C# helper class. Enjoy!

The code is widely commented, so it should be understandable enough for any C# developer.

This English version is the original one, developed by me back in 2002: the italian version is mostly a translation made later to meet the many developers (and colleagues) who were not at ease with the English.

Other languages

Over the years I have developed several portings of this class in various programming languages, including PHP, Objective-C, Swift, Java, JavaScript and Transact-SQL: if you need it, write your request in the comments and I will create other articles on this topic.

That's all for now: happy check!

 

Exit mobile version