What is .Net can anyone please explain

Eisasuarez

Well-known Member
Joined
Mar 23, 2012
Messages
653
Hi

can someone explain what .net is. I have seen explanations but none makes sense

Can someone explain or show a diagram so i can understand what it does.

I have seen asp.net, vb.net, microsoft.net etc and its confusing

i know Vba,Sql, c++,c# etc are languages you write in a program

but what is .net.

is it like the vba window where you write vba code? Is that called vb.net framework?
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
No, the framework supplies the libraries and runtimes that allow a program written in a .Net language to actually work. Vaguely similar to the references you have in VBA and the .dll that actually contains the VB runtime.
 
Upvote 0
Hi Eisasuarez
user-offline.png

your question prompted me to register so that I can reply.
I'm not sure what your experience and levels are (I can't provide a diagram) but I'll do my best to explain what .net is.

Microsoft was gaining enormous popularity in the business market in the 90s. They had VBA for Excel and Access, then Word and Powerpoint even, they had compilers for C++ (Visual C++) and the very popular VB. VB got very mature with Version 6. At around that time, the Web was getting more and more important for business, and they had a clunky old technology called ASP (Active Server Pages) This used VBScript at the back and sent back html to the requesting browser.

Microosft worked for hard between about 1998 and 2001 to create a brand new technology/suite of tools to compete viably in the coming internet age. So gone were VB6, VBA (both of whch used an object technology protocol called COM), C++, vbscript and various other tools. An in came .Net. The most key thing to know about .net is that it's fully object-oriented, allowing for encapsulation, polymorphism and inheritance, the holy OO trinity.

.Net is mainly 3 things.
1) a compiler (the Common Language Runtime or CLR)- this is like a mini-operating system that can run .net programs you write.
2) a language that can target this compiler, here there were many but the two main ones were C# and VB.net
3) the vast underlying libraries that were written to be compatible with the .net Compiler or CLR

let's look at each of these
the Compiler or CLR is really a Microsoft version (rewrite) of something like the java runtime. A piece of software that loads the .net program you've written that in whatever language that will call on the underlying .net libraries. You can't do anything without this. You can't run an Excel VBA macro without Excel so in a sense Excel is the compiler and run-time of an Excel VBA program.

The language became much less important in one sense because any language that conformed to the spec could target the CLR and the libraries.

The libraries are key, in there you have things like string, double, bool, ArrayList, and quite literally across about 30+ dlls thousands of other classes.

very famous .net libraries do specialised things like
access data from robust back-end database servers like SQL Server, DB2, Ingres, MySQL or Oracle (ADO.net) but getting replaced with LINQ and Entity Framework
ASP.net ...a heavily souped up version of the 90s ASP - a web framework for writing web apps - this is slowly getting replaced with ASP.net MVC (model view controller)
Winforms - writing windows apps - also debatable whether it's getting replaced but if it is it's stuff like WPF or Silverlight a much more complicated version of Winforms with more capabilities but much harder to learn
Cryptography
Regular expressions

etc..etc..

There are many .net libraries.

in conclusion, .net is a platform for running the .net programs you've written in a .net language and that consume the contents of underlying .net libraries that contain primitive (but highly useful functionality like strings and integers) and other libraries that help you build GUIs (Web or Windows) and target services or Write internet applications that run on a server but appear on a client's browser.
.net Was built to allow for a convergence of technologies using the Object-Oriented paradigm but in a much more complete and thorough way than had existed in COM or VB6/VBA. The idea was that you could write a .Net program (that targets .net libraries) in a language of your choice and you could use robust industrial strength object orientation to express your business solution/design.

I hope this helps.

P.S: VBA has not gone. but it has been deprecated as a standalone environment (the way VB6 was) and can now only automate office apps. it just seems as if MS cannot (or are not even trying) to kill VBA. We shall see.
 
Last edited:
Upvote 0
Thank you for taking time out to explain

In conclusion, .Net has a library that say in a vba scenario that vba can understand


in excel vba, you will not be able to write vba code without .net

So when we write vba code and access functions like mid, instr etc,
these are stored in a library in .net which also compiles the code?

how is structured for excel vba
 
Upvote 0
No. VBA is not a .Net language.
 
Upvote 0
Thanks Rory so in a brief structure guide, how does it work.

So what framework does Vba use?

I hear .net has a library and class. Briefly what is that library / class
what type of things?

So say C# is a .net language

what is the structure?

C# is a language
There are many functions and objects in that language. Say there was a string/mid function
these functions are stored in the library on the framework so c# already knows how these functions work (its like calling the function, classes) from the framework.
This is already compiled using the CLR
This is already understood by machine code

so im trying to understand in steps what it holds, how its structured to work.

so to take excel vba for example.

in this you have you have a library that holds functions (is this like .net framework)
these functions are already compiled to how it works using another language

Would love to know the structure so its easier to understand in human language to how this is working with other languages

just a step by step breakdown. I hear it has libraries classes etc but what does it hold
how does c# or and languages work with this framework

thank you
 
Upvote 0
I can't explain .Net better than any of the myriad articles on the web, I'm afraid.

VBA has nothing whatsoever to do with .Net, so what is the purpose of the question?
 
Upvote 0
I think you're confusing .Net a newer and far more advanced technology that enables the creation of robust enterprise and internet systems, with VBA, which is a pretty decent language that pretty much only automate a Microsoft Office application.
.Net as Rory has said has nothing to do with VBA. Confusingly you can automates an Office App with .net but for that you need something called Interop, and these are .net Assemblies that have been compiled especially to communicate with the equivalent VBA .dll and thus they are a half-way house solution (hence Interop = interoperation). There is nothing wrong with automating say Excel from .net if you need to do something from within some enterprise solution or you need access to .net native classes or functionality. However for most solutions even highly complex ones, VBA is more than adequate, because the Office functionality itself is so powerful.

but...VBA = old technology used pretty much only to automate an Office apps and needs an office app to work (if you discount the VBA of VB6)

.net = a robust enterprise framework for creating standalone applications that do not in any require MS Office and can communicate with a wide range of data sources and protocols etc..
 
Upvote 0

Forum statistics

Threads
1,215,375
Messages
6,124,588
Members
449,174
Latest member
chandan4057

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top