views:

2497

answers:

30
+23  Q: 

Why use .NET?

I've often wondered, what is so great about .NET and MsSQL?

I can see a downside being that you have to run it on Windows but I am unaware of any upsides besides it being quite fast, yet so many here use it.

Edit: You are meant to run it on Windows but as Atrophius pointed out you can use Mono

A: 

.Net is a very structured object orientated programming framework which on it's own is language less. You can then choose to use a range of different programming language from C++ to VB.

GateKiller
+35  A: 

I can see a downside being that you have to run it on Windows

That's actually untrue. The Mono Project has made great progress on making .NET applications cross-platform. A client that my company has worked with recently was actually using Mono on Linux servers to run C#.NET Web Services. The system worked out very well and is very stable.

Edit:

kevin d wrote: $$$$$$$$$

This is another really good point. Go have a look at the sheer number of .NET job opportunities there are available and how much they usually pay.

Jeremy Privett
+1  A: 

As far as .NET is concerned, if your goal is to produce software that runs on Windows, and you're ok with the dependency on the runtime, then the .NET Framework provides a huge library to take advantage of.

Though I haven't used it, I believe Mono is designed to support .NET applications on Linux, Solaris, Mac OS X, Windows, and Unix. (Edit: Atrophius beat me to it. :P)

Bill
+50  A: 
  • World-class tooling support with Visual Studio
  • Myriad of managed languages (C#, VB.NET, Managed C++, F#, J#, etc.)
  • Plethora of existing .NET libraries from graphics to databases
  • Interop with existing code investments (via Platform Invoke, COM interop)
  • Ability to reuse code on different platforms (Web/Silverlight, Smart Device/Compact FX, Linux/Mono)
  • .NET code can execute on multiple processor types (x86, x64, etc.)
Chris Smith
+24  A: 

A few things about .net:

  • You can use Visual Studio, which may not be perfect, but sucks less than every other IDE I worked so far with
  • It is constantly being improved - Generics, Windows Workflow, LINQ, WPF, WCF are all nice technologies. Not flawless, but nice
  • The Framework is really good and integrated
  • It is Unicode. I worked with Delphi and PHP before, and that was not really nice to work with once you needed to address internationalization issues :-( (Delphi has Unicode support as far as I know, but the whole Borland-Inprise-Borland-???-CodeGear-Embracadero stuff did not really help convincing me)
  • It's language-agnostic. Sure, VB and C# are the only First Class languages, but Boo, IronRuby, IronPython and Delphi ARE viable Alternatives or about to become such
  • Andreas Hejlsberg is working on C# :-)

So while it is not perfect, but neither is Java, Delphi, PHP, Ruby, Python or LISP. But it does pretty much supports everything through a native Framework without too much need for third party stuff.

Michael Stum
+3  A: 

It may have something to do with the low cost of entry for .NET. One IDE, one framework, one (popular) database, and one (popular) web server.

If you do need help with .NET, there is one source for official documentation and it is accurate, up-to-date, and well-maintained. In addition to MSDN, there is no shortage of other online resources, books, courses, etc. to get you going.

Brad Tutterow
Don't know about you, but MSDN really could be more helpfull.I know the whole thing is huge, but as it is now I rearly find my answer in MSDN. Agree on the community resources though.
borisCallens
+6  A: 

Let me rephrase your question:

I've often wondered, what is so great about PHP and MySQL?

Before your downmod me, read on: In my opinion language/platform/database really makes no difference at all. Its all a matter of preference most of the time. Sure .NET is faster than PHP but how often does that matter? .NET applications are usually fast to develop but not nearly as fast as a Ruby app.

From a .NET developer perspective, MsSQL is nice because it is so integrated with Visual Studio but if I was in charge of a company's IT I would go with MySQL due to the enormous cost savings. Are there any DBA's that can add to the conversation the different between the two in terms of maintenance?

sestocker
A: 

I'm not a DBA, but MSSQL has a lot of advantages over MySQL (with price of course being the big disadvantage). I haven't done performance benchmarks but I think the performance is a bit better. You also have pretty nice tools for ETL, Reporting, and data analysis right out of the box. And it has very nice management tools too, I would imagine that between all this it makes the DBA's life a bit easier.

As others have said, the integration between .net and SQL Server is fantastic also. What is the alternative in your case though? That would make comparisons much easier.

AlexCuse
A: 

It may have something to do with the low cost of entry for .NET. One IDE, one framework, one (popular) database, and one (popular) web server.

If you do need help with .NET, there is one source for official documentation and it is accurate, up-to-date, and well-maintained. In addition to MSDN, there is no shortage of other online resources, books, courses, etc. to get you going.

I know .NET developers that can't program WITHOUT that one IDE. Sounds limiting to me, whereas PHP I can use any text editor ever invented.

As for the rest of your post, it easily applies to PHP except for "low cost of entry", since it is free to get a LAMP environment up and running.

Akira
+3  A: 

I'd like to point out that you don't have to use MSSQL. .Net connects with just about every DBMS system out there. From SQLite to old style dBase. Visual Stuido does too. You don't even need Visual Studio. Notepad will do. Though I admit, Visual Studio helps tons.

I can't say enough good things about .Net. MS got this one right (and that's about the only thing I think MS did right).

Stephen Cox
+1  A: 

"It may have something to do with the low cost of entry for .NET. One IDE, one framework, one (popular) database, and one (popular) web server."

Actually the cost is in the equipment. And if you want more then the basic IDE you need to buy a MSDN subscription (or Visual Studio outright). Keep in mind, you don't need Visual Studio to access .Net. .Net is a framework not an app. Any application can access it. A text editor is all you really need.

Stephen Cox
+2  A: 

What I love the most about .Net is how much better it is to make reusable components with it than any other languages I've used before.

Also, as some people already pointed out, Visual Studio is probably the best IDE around (even though it's not perfect).

GoodEnough
A: 

"Visual Studio is probably the best IDE"

I like XTools (Mac) also. But an IDE is an IDE. They all about the same. One thing VS has over everyone is the documentation. Hands down the best in the business.

Stephen Cox
+1  A: 

While this may not apply to most of us here because we are spending our free or company's time on a beta website about programming questions, I've met many "nine-to-five developers" who are just in it to make as much money doing as little work as possible. When this is your mentality, you just go with whatever has the most job openings and that's usually Java or C#.

go minimal
A: 

You can use Visual Studio, ...but sucks less than every other IDE I worked so far with

Then you haven't used IntelliJ IDEA so far...

Myriad of managed languages

I've never understood the benefit of that. Many different syntaxes compiling the same intermediate code.

You want to know the real benefit of .Net? Competition!
Yes, you have read correctly. Microsoft is good for competition.
The Java community begged for features SUN didn't supplied, but after C# was out there with these features, well, then they implement them, too.

To avoid misunderstandings: I really like .Net

John Smithers
+5  A: 

Then you haven't used IntelliJ IDEA so far...

Or Visual Studios with Resharper

Owen
+3  A: 

Can I just say this .Net is not so great. Its good but not great. Essentially what makes .net so ubiquitous is that

  • its Microsoft
  • and that Microsoft has pushed this on us.

The average Windows developers have been waiting to for the next new thing from the mid 90s where they were stuck with VB6 or Delphi. Unfortunately Delphi was muscled out of the market by Ms and its own incompetence.

I still find it slower performance than writing a native app for win32 and it needs the runtime installed.

Having said that its advancing. C# is becoming less verbose with .net 3.x (i forget which one introduced vars and lambdas) but to say that its great is wrong. Its effectively another Java.

John Nolan
Saying that .NET is not so great that it is Microsoft is just saying that a person is a criminal because his skin is black.
Andrei Rinea
I think you have missed the point. .Net is popular because Microsoft is popular, not because Microsoft is good or bad.
John Nolan
Speaking as someone who does most of his work in Java, its effectively a better [single-ish platform] Java.
Kevin Montrose
I'd argue that it is the successor to Delphi. Andreas Hejlsberg was not hired by accident.
Wyatt Barnett
+1  A: 

I agree with the low cost of entry being an attraction to .NET. In addition to only needing notepad (which is true for Java, PHP and other technologies), Microsoft gives away express versions of Visual Studio and SQL Server. For free!

Tundey
And the Express editions are free including for commercial use!
Andrei Rinea
Yeah, but out there in Java land there is everything for free, if you addd Postgres or MySQL, you get a whole full she-bang stack for free, not just a basic something version, so that's not really a point I'd say.
André
Comparable to MySQL we have SQL Server Express.
Andrei Rinea
Not everything is free in Java land. All those enterprise bean container stuff aren't free.
Tundey
@Tundey - Ummmm... yes they are - GlassFish and JBoss are both free and open-source full stack J2EE application servers.
Nate
+1  A: 
* its Microsoft
* and that Microsoft has pushed this on us.

The average Windows developers have been waiting to for the next new thing from the mid 90s where they were stuck with VB6 or Delphi. Unfortunately Delphi was muscled out of the market by Ms and its own incompetence.

IMHO you've nailed it right there.

For the majority of people, computers == windows == microsoft. Apple are slowly changing this but it's not there yet.

Therefore, if you want to write non-web software for the majority of people, you write software for windows

Microsoft have decreed that The Way To Write Windows Software Is .NET

There you go

Orion Edwards
+1  A: 

Some time ago, Microsoft declared that Win32 was basically deprecated and that the future of the Windows API is .NET. If you're starting a new Windows application now, and you want to make good use of the platform you're running on, then you should use .NET.

Windows Presentation Foundation, for example, is intended to be the "next generation" drawing API for Windows.

They problem with Microsoft's direction here is that any developer who wants to create cross-platform applications needs to stay away from these platform-specific technologies. You can't write a portable application that uses WPF.

MSSQL is another story - the two aren't really that closely related.

stevex
@stevex: Ironically, Microsoft then went ahead and did things like make it impossible for purely-managed 64-bit applications to access the same Registry entries that 32-bit applications will see, other than by (1) using hard-coded locations which Microsoft says will break in future, or (2) using the win32 to access the Registry directly. What were they thinking!?
supercat
+2  A: 

Compared to COM, .NET is far easier to work with; it's worth migrating to just for the thousands and thousands of .NET Framework classes.

Compared to LAMP (for example), um... it's just a whole different model from what you're used to.

I use .NET when the application realm is Windows-centric, when applications like Office are important components, or when the client requires it.

catfood
+1  A: 

.Net can be used to make WEB, to make WinForm, to create console application, to create Mobile Application, to create OS Services and many other type of program without having to change a lot of code. The framework is strong and has the possibility to be close on the OS (well, at least XP/Vista). Of course, it can go on Linux too with some adaptation.

The IDE let you create fast GUI too :)

Daok
+2  A: 

I develop in .NET all the time. I've also been exposed to several other languages. I would describe C# and by extension .NET as a programming language/environment that is as intuitive as VB6 but just as powerful as C or C++.

While I agree that Microsoft and they're money pushing it certainly helped the adoption rate. Now that it has been in production for several years it has a reputation of its own.

While there have been many times I've had to role my own .NET libraries for various reasons the breadth of the Microsoft shipped libraries is pretty darn impressive.

+3  A: 

Well Orion,

Apple is the same. I would say apple is even EVIL then Microsoft. They guard everything so close to their chest that it is impossible to create revolutionary products on it. If you innovate (Look at this : http://yro.slashdot.org/yro/08/09/19/179236.shtml), they can kill your products easy if they find it lucrative!.

At least MS is better in that respect. I would admit that I am a Microsoft developer at heart.

Dev S
+1  A: 

The real question is:

Why not use .NET?

Chris Pietschmann
Because it's expensive, and the ".net way" is letting your view controls know about datasets or worse, SQL queries. I'd take java thank you very much
Pablo Fernandez
It can't cost more than a license of Windows XP Home edition or sth...Sorry Pablo you are either misinformed either misinforming. Either way do something about this.
Andrei Rinea
it don't even cost a windows xp license, since you can run it for free and there are many free open source editor.MS editor itself is free (express edition)
Omar Abid
@Andrei: you van code on MonoDevelop.
Callum Rogers
I know you can use Mono. Pablo is the one that doesn't.
Andrei Rinea
+1  A: 

.Net is good, however, I'd be extremely wary of using SQL Server on a web application. Once you cross into the enterprise domain, the costs go to around 23k per processor, so if you have a quad processor box, thats 92k just for the database. For many companies, that is simply too much. If you look at MySQL, the costs are far more reasonable. We had not looked at the licensing fees too closely, but the difference in cost to us to move to MySQL paid for the developer to do the port, and there was a lot of cash left over that we could use for pay raises, better computers and so forth.

+1  A: 

I think It gets used because it's for windows and windows has a big market. Also there are good designers for both web and Win Forms. There is also lot of sample applications and most businesses are either using Java or .NET, I think many companies consider integration with windows/MS Office and go with .NET.

eschneider
A: 

There is also a Delphi for .Net

http://www.turboexplorer.com/article/33892/images/33892/turbo_cplus_datasheet.pdf

http://www.turboexplorer.com/article/33890/images/33890/turbo_delphi_datasheet.pdf

and TurboExplorer is also Free (for all Borland programmers)

yelinna
A: 

Coming from many years in the Delphi world I've found Visual Studio/C#/.NET world to be a good choice to develop solutions. ( I do miss being a rebel though...)

On the bottom line, it's where the jobs/available developers are at.

dverespey
+1  A: 

I found C# as the most powerful language among the most populars ones.

Maybe the most constantly updated.

It has the most widely support and content in web.

A lot of people know how to program .NET so it's easier to find good qualified people.

It's easy to change from the old fashioned WinForms to Web or Mobile platform.

I think is one of the easier languages to learn for young people, maybe just behind Ruby.

Rulas