Follow @endyourif rss Facebook LinkedIn

What is the difference between String and string in C#? What is the difference between String and string in C#?

Published on Jan 24, 2020

Short answer: nothing. string is an alias to System.String. This also holds true for int and System.Int32.

If you want my personal preference I always use the lowercase version aka the alias. Why? Because I don't need to add the following reference: using System; in each file. I know, it's a little OCDish, but what can I say...

Tags: ASP.NET MVC and Web API Tutorial | c# | string

My Books
ASP.NET MVC 5 With Bootstrap and Knockout.js
Knockout.js Building Dynamic Client-Side Applications
20 Recipes for Programming MVC 3
20 Recipes for Programming PhoneGap
Rapid Application Development with CakePHP