Top ".net" questions

Do NOT use for questions about .NET Core - use [.net-core] instead.

Using Case/Switch and GetType to determine the object

Possible Duplicate: C# - Is there a better alternative than this to ‘switch on type’? If you want to switch …

c# .net reflection switch-statement case
How to add New Column with Value to the Existing DataTable?

I have One DataTable with 5 Columns and 10 Rows. Now I want to add one New Column to the DataTable and …

c# asp.net .net visual-studio-2008 datatable
How to open a web page from my application?

I want to make my WPF application open the default browser and go to a certain web page. How do …

c# .net wpf
Create instance of generic type whose constructor requires a parameter?

If BaseFruit has a constructor that accepts an int weight, can I instantiate a piece of fruit in a generic …

c# .net generics
Introducing FOREIGN KEY constraint may cause cycles or multiple cascade paths - why?

I've been wrestling with this for a while and can't quite figure out what's happening. I have a Card entity …

.net entity-framework foreign-keys ef-code-first entity-framework-4
Total number of items defined in an enum

How can I get the number of items defined in an enum?

c# .net enums
Order of items in classes: Fields, Properties, Constructors, Methods

Is there an official C# guideline for the order of items in terms of class structure? Does it go: Public …

c# .net coding-style code-cleanup code-structure
Convert String to Type in C#

If I receive a string that contains the name of a class and I want to convert this string to …

c# .net string types
How to play a sound in C#, .NET

I have a Windows application written in C#/.NET. How can I play a specific sound when a button is …

c# .net audio
What are .NET Assemblies?

What are .NET Assemblies? I browsed over the net and I am not able to understand the definition.

c# .net