Top ".net" questions

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

Get a DataTable Columns DataType

DataTable dt = new DataTable(); dt.Columns.Add(new DataColumn(gridColumn1, typeof(bool))); I was expecting the result of the below …

c# .net datatable datagridviewcolumn
Awaiting multiple Tasks with different results

I have 3 tasks: private async Task<Cat> FeedCat() {} private async Task<House> SellHouse() {} private async Task&…

c# .net async-await task-parallel-library .net-4.5
How can I remove item from querystring in asp.net using c#?

I want remove "Language" querystring from my url. How can I do this? (using Asp.net 3.5 , c#) Default.aspx?Agent=10&…

c# .net asp.net query-string
Sending HTTP POST with System.Net.WebClient

Is it possible to send HTTP POST with some form data with System.Net.WebClient? If not, is there another …

.net vb.net http webclient
Where is the Global.asax.cs file?

I am using VS 2008. I have created a new Asp.net web site project from File->New->Website-&…

c# asp.net .net visual-studio-2008 global-asax
Why can't I use the 'await' operator within the body of a lock statement?

The await keyword in C# (.NET Async CTP) is not allowed from within a lock statement. From MSDN: An await …

c# .net async-await
Why "Data at the root level is invalid. Line 1, position 1." for XML Document?

I am using a third-party DLL which transmits an XML document over the internet. Why would the DLL be throwing …

.net xml xmldocument xmlreader
Returning anonymous type in C#

I have a query that returns an anonymous type and the query is in a method. How do you write …

c# .net anonymous-types return-type
Sometimes adding a WCF Service Reference generates an empty reference.cs

Sometimes adding a WCF Service Reference generates an empty reference.cs and I cannot reference the service anywhere in the …

c# .net wcf
Authentication failed because remote party has closed the transport stream

I am developing a TCP client to connect OpenSSL server with the certificate authentication. I have using .crt and .key …

.net openssl x509certificate sslstream