Question:
Is .Net platform independent?
Zer0 ur Eg0
2009-12-30 23:48:38 UTC
They say a .net source code is first compiled to a CIL code which makes it platform independant.If yes, then why don' t .net applications run on all Operating systems like Linux?
Can anybody also explain who executes or compiles the CIL code.I am goint nuts about them..can anybody explain in a simple understandable manner how all this conversion works.Thanks.
Three answers:
peteams
2009-12-31 05:09:22 UTC
.NET is a collection of technologies. Some of these technologies are platform independent, some are not. Some of these technologies are standards, some are not.



The .NET development tools create CIL. This is then compiled to native code on the target machine.



It is possible to have the application compiled when it is installed. Often the CIL will be compiled "Just In Time", JIT, the first time during a session when it is required.



.NET code will run on most of the common platforms you will encounter, including Mac, iPhone, Linux, etc. Platforms like Windows will be able to run them exactly as if they were native applications. Platforms like iPhone require that they go through a further compilation stage to create the native application before they are installed.



The libraries of functions available to applications vary from platform to platform. So trying to do a specifically Windows thing on an iPhone is not going to work.



As indicated in other answers to your question, there is religion involved here. .NET originated from Microsoft, and some people don't like Microsoft. There are alternative technologies, Java and Open Source perhaps being the most pervasive.



In my religious view of things, I can make far more money writing .NET applications than Java bytecode applications. Not only is it more lucrative for me to do that, it is also a happier experience because I am more in tune with the tools .NET provides.



Time principle development lanugage of .NET is C#, the principle development language of Java bytecode is Java. C# was designed with the benefit of first seeing the Java langauge and, in my opinion, they have fixed many of the nasties in Java.



You can deliver applications as source code, however doing so allows people to reuse your code without paying license fees or abiding by terms of use. As I make money from writing these applications it is often not in my benefit to effectively give away these rights.
jplatt39
2009-12-31 01:20:17 UTC
There is something called Mono which allows it to run on Linux, however Mono is very`buggy. No .Net is not platform independent. In fact I know a couple of AIX programmers whose opinion of it is even lower than mine. What is AIX? It is IBM's proprietary Unix. It is NOT focused on an Intel platform the way Windows and the Linux which most of us deal with are. Microsoft's record for interoperability is very bad, and .Net is an example of this: it works best on Intel platforms and on the Windows Operating System.



Oh, I should mention that Mono is bankrolled by Novel, and was developed by the guy behind the GNOME desktop which Ubuntu uses.
Roharme
2009-12-30 23:54:16 UTC
first of all .net is not free, it belongs to Windows. And its not like java ,which follows "Write once and run anywhere"





visit:

http://www.infosyndrome.com


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...