1,624,348 questions
0
votes
0
answers
10
views
Forcing Single Implementation Registration
I am looking for a design pattern in .NET Core but couldn't find any.
I have an extension method that registers interfaces:
private static void RegisterImpls(this IServiceCollection services)
{
...
-1
votes
0
answers
36
views
in my training video controller how do i call the upload helper to upload an mp4 video
i have three files "training controller", "add.cshtml" and "uploadhandler.cs" where do i add the call for the uploadhandler to accept the mp4 file in the add.cshtml ...
0
votes
0
answers
21
views
Hikvision SDK - Callback for Motion Detection Events Not Triggered
I'm trying to listen to all motion detection events from a Hikvision camera using their SDK. So far, I have successfully logged into the camera and set up the listening functionality along with a ...
1
vote
0
answers
12
views
Unity build failed; CommandInvokationFailure: Gradle build failed
Unity: 2023.2.18f1
Selected Platform: Android
Firebase SDK: 12.10.1
External Dependency Manager for Unity: 1.2.186
Facing CommandInvokationFailure: Gradle build failed. issue. I have tried all the ...
0
votes
0
answers
33
views
CManagerApi not recognized in C# project using MetaTrader 5 Manager API
I'm trying to use the MetaTrader 5 Manager API in a C# project to monitor real-time order or position updates using the CManagerApi class.
I've already added a reference to the DLL from the official ...
0
votes
1
answer
91
views
How can I refactor a widely-used C# class to support constructor dependency injection without breaking existing usages? [closed]
In my C# ASP.NET Core project, I have a class that is currently instantiated using a parameterless constructor. This class is used in hundreds of places throughout the solution.
I now need to refactor ...
1
vote
0
answers
57
views
How to import c lib and kill process?
There is a .so file imported into my C# project, which has three methods: Start(), RegisterCallBack(Delegate callback), and End().
First, I invoke 'Start()' to create an unmanaged thread. Then I call '...
-1
votes
0
answers
48
views
Is it okay to instantiate a new service in each method? [closed]
I want to use an Azure Durable function because apparently it's good if my application only runs once a year or very rarely.
The logic is like this:
takes all SharePoint items
sends SPItem to a ...
0
votes
0
answers
47
views
Blazor image streaming - Chrome out of memory
We're developing a Blazor application on .NET 8 that streams single .jpeg images (200kB) to the browser. Those images could have a frequency of ~1000 images/minute.
We set the images as a base64 ...
0
votes
0
answers
24
views
Implements generic WinRT interfaces use <AllowUnsafeBlocks>True</AllowUnsafeBlocks>. But where exactly do I place that setting?
I have a MAUI project that's giving multiple errors related to my custom classes \Models\Term.cs and \Models\Course.cs. Visual Studio 2022 gives the same recommendation for both:
Type 'System....
0
votes
1
answer
51
views
Manually added Razor page doesn't render razor component
I started a project as .NET Minimal API - no UI whatsoever. Then I needed to add a visual tool for the API, to show what the service is doing.
For UI I wanted to use Razor pages and components, as it ...
0
votes
0
answers
18
views
Even if it works as HQL, NHibernate linq joining a subquery with grouping and using grouping subquery projections in join key and result causes errors
I need to write an nhibernate query as linq syntax to produce a IQueryable but I have some issues even if it works as HQL query. I need to use IQuerayable for another purpose since hql doesn't result ...
1
vote
0
answers
41
views
PdfiumViewer in c# WPF application
I'm trying to use PDFium.Updated in my c# wpf application programmed in VS2022. I just want to display the pdf file in a seperate window with a usercontrol. Nothing more.
I Installed the Nuget package ...
-2
votes
0
answers
39
views
What errors should I catch on a C# Dot Net http server? [closed]
I am new to C# and maintaing an old game engine that has a TCP/IP server. A game viewer connects to it to play. I discovered a forcibly closed socket can cause the server to stop listening. This means ...
2
votes
1
answer
57
views
Text to speech while highlighting current word
I'm trying to write a simple application using C# that will read the text in a richTextBox and hightlights each word as it is read.
I am using
private SpeechSynthesizer synthesizer;
But when it goes ...