Top ".net" questions

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

Convert DataTable to List<T>

I have an strongly typed DataTable of type MyType, I'd like convert it in a List<MyType>. How …

c# .net generics datatable
DateTime vs DateTimeOffset

Currently, we have a standard way of dealing with .NET DateTime's in a TimeZone aware way: Whenever we produce a …

c# .net datetime timezone datetimeoffset
Best way to resolve file path too long exception

I created a app that downloads all document libraries in a SP Site , but at one point it giving me …

c# .net string file sharepoint
Insert into C# with SQLCommand

What's the best way to INSERT data into a database? This is what I have but it's wrong.. cmd.CommandText = "…

c# .net ado.net sqlcommand
Display a tooltip over a button using Windows Forms

How can I display a tooltip over a button using Windows Forms?

.net winforms button tooltip
Simplest way to have a configuration file in a Windows Forms C# application

I'm really new to .NET, and I still didn't get the hang about how configuration files work. Every time I …

.net xml winforms configuration
How do you simulate Mouse Click in C#?

How do you simulate Mouse clicks in C# winforms applications?

c# .net winforms
How to shut down the computer from C#

What's the best way to shut down the computer from a C# program? I've found a few methods that work …

c# .net windows shutdown
What reference do I need to use Microsoft.Office.Interop.Excel in .NET?

I am interested in using C# to manipulate/Automate Excel files. After browsing the web I have found VSTO but …

c# .net office-interop visual-studio-express