Category "c++sharp"

Data driven coded UI test with excel file as a data source

I built a coded UI test and I want to make it a data driven test , I want to get the data from an excel file ( Data.xls )located in the same directory with the

Deserialized Object Has All Values Set to Null

I'm trying to deserialize JSON into a custom object but all my properties are set to null and not sure what's going on. Does anyone see anything wrong? JSON Ex

How to get fibonacci in c#

Guys I have a question regarding on fibonacci..How do I get the fibonacci series that the number will also end on user input...example if I put 21 the output mu

Deploy/programmatically create Outlook Rule to run Script

I need to deploy an Outlook rule that runs a script. So in other words I need deploy both an Outlook rule and the script it runs. I know I can get users to impo

Can a cascade delete rule be added in a migration?

In a FluentMigrator migration, if I'm defining a relationship, say: Create.Table("RelatedTable") .WithColumn("RelatedTableId").AsGuid().PrimaryKey() .W

.NET console application as Windows service

I have console application and would like to run it as Windows service. VS2010 has project template which allow to attach console project and build Windows serv

Comparing MD5 hashes between XLSX files with identical content

We have an internal web application that accepts a file of varying formats from a user in order to import large amounts of data into our systems. One of the mo

Unable to debug VSIX project

I'm trying to develop my first visual studio extensions project, I have VS10 SDK installed and was able to create a new project and can build it fine, however w

How do I resolve the issue the request matched multiple endpoints in .Net Core Web Api

I notice that there are a bunch of similar questions out there about this topic. I'm getting this error when calling any of the methods below. Microsoft.A

Environment Variable for debugging in Visual Studio 2022

I have a problem in Environment Variable in Visual studio 2022. When I use Development there is no problem and it takes development AppSettings, But when I rem

How do I disable request validation without setting RequestValidationMode to 2.0?

We've just upgraded to ASP.NET 4.0, and found that requestValidation no longer works. The MSDN docs suggest we need to set requestValidationMode in web.config t

The constraint reference 'string' could not be resolved to a type. (netcoreapp3.0)

I have got an error. This is my Startup class. public void ConfigureServices(IServiceCollection services) { services.AddControllers(); } public void Confi

How to get all appointments including the private ones?

I want to list all Outlook appointment times in a specific time range and I am only interested in start and end time of the appointments. I'm using this code s

Access to the path denied error in C#

I have read a similar post, but i just cant figure out the problem. I have changed the windows permissions and changed routes. When i try to save a file it th

How do I determine the Windows 'Download folder' path?

On my machine, it's here: string downloadsPath = Path.Combine( Environment.GetFolderPath(Environment.SpecialFolder.UserProfile), "Downloads"); But on a

.Net Core 3.0 possible object cycle was detected which is not supported

I have 2 entities that are related as one to many public class Restaurant { public int RestaurantId {get;set;} public string Name {get;set;} public Li

Deserializing JSON response without creating a class

From the result of an API call I have a large amount of JSON to process. I currently have this Object convertObj = JsonConvert.DeserializeObject(responseFromS

Reasons for and against objects handling their own persistence [closed]

I am looking at different options for persistence modelling in Windows Phone using Isolated Storage. One of the ideas I have come up with was

Decrypt ".AspNetCore.Session" cookie in ASP.NET Core

In Asp.Net core, a cookie is created when you configure your app to app.UseSession(). By default the cookie is called ".AspNetCore.Session". Its value identifi

C# UDP Broadcast and receive example

Problem: I am trying to bind a udp socket on a specific address. I will broadcast out a message. That same socket will need to be able to receive messages. Cur