About new F# programming language in .NET framework

Logo devnterface d88f51727b3053dd3115e1ef9c566ad79b4c2edb3cd208c06345fc37058bebd9

With the imminent release of version 4.0 of the. NET framework and VisualStudio 2010, Microsoft will introduce a new language that can fully use all the features of the .NET framework. This language is called F#.Unlike the C# programming language, which is an imperative programming language, F# is a functional programming language, based on .NET framework such as C#. F# and C# can call each other directly. As a result, F# has f...

Read more

Implement custom events in .NET framework

Logo devnterface d88f51727b3053dd3115e1ef9c566ad79b4c2edb3cd208c06345fc37058bebd9

Hello everyone, In today’s post I would like to explain how to create .NET custom events. The .NET framework provides specific objects that enables simple creation and use of events.The events allow to an object (or class) to let know other classes or other objects when a specific occurrence occurred. The class that generates and sends the event is called Publisher and the classes that are notified and manage the event are called Subscribers. An event can have multiple subsc...

Read more

LINQ: from xml to C# classes

Logo devnterface d88f51727b3053dd3115e1ef9c566ad79b4c2edb3cd208c06345fc37058bebd9

I continue my post on LINQ and C# programming talking about the conversion from XML file to C# classes. Previously I’ve show how to serilize a C# class into XML file. Let me show you an example. Suppose we have an XML file that contains the list of Italian municipalities with their area code. We now want to load this file into a list of C# objects more convenient to use within our application. Define the file Municipalities.xml ...

Read more

LINQ: serialize C# classes

Logo devnterface d88f51727b3053dd3115e1ef9c566ad79b4c2edb3cd208c06345fc37058bebd9

The version 3.5 of Microsoft’s .NET Framework introudced the LINQ (Language Integrated Query).component.LINQ is a SQL-like language that allows to query different source of data, as objects, xml files and databases.What i’ll show today is how to generate an xml rappresentation of a C# class instance..Suppose to have a C# class Book so defined.123456public class Book { public String title { get; set; } public String author { get; set;...

Read more