Showing posts with the label c#

[FIXED] Get derivative method on base class variable

Issue I have two classes a base class b and the derivative. In my code I call a method with a base…

[FIXED] "Browse To Find Source" in Visual Studio 2010

Issue When is "Browse To Find source" enabled in Visual Studio 2010? (see below) image …

[FIXED] VS 2019 and MySQL Entity Framework duplicate database name

Issue I added Entity Framework to my project but I call the toList() method and I'm getting an…

[FIXED] Json serialize and deserialize dynamic object in C#

Issue Summary: I am required to submit a JSON request via C# where part of the payload changes base…

[FIXED] Error occurs while deserialize json object

Issue I have following JSON data: { "Id": 1, "Name1": "Test1", "…

[FIXED] ASP.NET core REST service returns invalid json

Issue We have an ASP.NET core REST service (.NET5). It works fine. But if we call a GET method from…

[FIXED] How to convert JSON to YAML using YamlDotNet

Issue I am trying to convert JSON to YAML using YamlDotNet. This is the code I have: class Progra…

[FIXED] RESTFul API Get method with both FromRouteAttribute and FromQuery

Issue I have an existing RESTFul API that has the below endpoints implemented already. [Route(&quo…

[FIXED] Deserialize a lot of properties from JSON

Issue Here's an example of the JSON file: { "Object": { "series&quo…

[FIXED] Post image src to MVC controller

Issue I'm trying to post the content of an image element to my controller so I can store it in …

[FIXED] ASP.NET File Upload

Issue I am trying to make a server page (C#, asp.net 2.0+) to save an uploaded file from another pa…

[FIXED] Is it possible to insert an image filename into a fileupload when webform is opened?

Issue I was wondering if it is possible to insert the filename of an image on the fileupload when a…

[FIXED] How can I save Image file to SQL database with .NET Core and EF

Issue There is a problem here, the title and description are saving correctly in the SQL database, …

[FIXED] Why I get Null value from view to controller only for one column?

Issue I am practice CRUD operation in ASP.NET Core 6 MVC. I try to upload single image method. The …

[FIXED] The action can't be completed because the file is open in IIS Worker Process

Issue I am uploading a image for a user & saving it on a specified location. The code is workin…

[FIXED] Using RediSearch with NRediSearch (C#), how to apply OR clause on two numeric fields like i.CountyId == id || i.CityId == id

Issue I am developing a .Net Core web app with RediSearch. Previously I have used in-app memory ca…

[FIXED] Format Repeating Decimal as a Fraction

Issue I need to convert decimal values to their fractional equivalents, similar to this previous

[FIXED] Shuffling a string so that no two adjacent letters are the same

Issue I've been trying to solve this interview problem which asks to shuffle a string so that n…

[FIXED] Can pdb files be added to a nuget package?

Issue We are building packages to a local nuget gallary, using azure pipelines (YAML build files) t…

[FIXED] How to know where the pdb files is looking for source code

Issue I have an external dll and a pdb file from C# code. I have the source code downloaded on m…