Le Kevin Blog Blog


What’s new in C# 8.0

C# 8.0 adds the following features and enhancements to the C# language: Readonly members Default interface methods Pattern matching enhancements: Switch expressions Property patterns Tuple patterns Positional patterns Using declarations Static local functions Disposable...


.Net Web API 2 returns query string instead of XML or JSON

public HttpResponseMessage Get(…) { string AllResults = "";   ScanResultModel returnRec;   returnRec = this.Get(…);   AllResults = Helpers.GetXMLFromObject(returnRec);   AllResults = AllResults.Replace("StatusMessage", "STATUS_MSG");   retUrl = retUrl + "?returnXML=" + AllResults;   var...