All Questions
985
questions
23
votes
1
answer
67k
views
Can any c# application be run on linux [duplicate]
I am developing a game server in c#. Server talks to clients via sockets and sends byte[] using custom packet protocol.
The question is, will this software be windows os specific or will be able to ...
13
votes
1
answer
15k
views
How do I pass returnUrl to Login page in Blazor Server application?
I have a simple Blazor server application, with Identity using Individual Authentication. I created the app from the VS 2019 standard dotnet new template.
In some parts of the app I would like to ...
12
votes
2
answers
20k
views
How to use websockets in asp.net core
im trying to develop a game where i store a scoreboard in a text file which is stored on server (currently on localhost). I am using http get and post calls in order to communicate with the server and ...
11
votes
3
answers
10k
views
Report Local time and not Server Time From UTC
I have created a page where weather data is displayed for the user as reported by the server. The time is saved as UTC, how can one show the local user's or browser's time from a Blazor Server app?
10
votes
2
answers
17k
views
Server Client Application with .NET and Xamarin
I searched around the internet a lot of hours but I couldn't find anything that matches my case.
I simply want to implement a Server/Client App with TCP or UDP where my Android App (Xamarin) acts as ...
8
votes
1
answer
6k
views
How to design my online Game Server for Unity3d?
Recently, I have been doing multiplayer game development in unity3d. I have got the pretty good idea of how the Unity's MasterServer works in unity.
But now I want to make my own game server from ...
7
votes
4
answers
868
views
Change Entity Framework Connecting String To Server
Here is what i have so far :
<add name="gymEntities1" connectionString="metadata=res://*/DateModel.csdl|res://*/DateModel.ssdl|res://*/DateModel.msl;provider=System.Data.SqlClient;provider ...
7
votes
1
answer
605
views
FBRemoteEvent crashes app
I am having fb remote event with which I listen to database and I start it with my app load inside thread.
When I run it on my Windows 10 (local pc) it works normally and perfect BUT when I run it on ...
6
votes
1
answer
413
views
SSL data read and write transfer rate managing efficiently in Server
How to control data write and read efficiently?
OR
What are the possible reason for decreasing read/write speed?
Is there any mistake in my code?
Currently it is very slow.
I am using below code:
...
5
votes
2
answers
7k
views
Microsofts Asynchronous Server Socket Example
I have a question regarding this question ("Asynchronous server socket multiple clients").
Either Microsoft changed the example since Groos answer or I really don't get it -
in the example it says:
...
5
votes
1
answer
2k
views
Unity asset bundle server automation
I am developing an application in Unity where users can upload their own 3d-models. I have been searching for ways to implement this and the best way to load models from all types seems to be asset ...
5
votes
1
answer
2k
views
WebRTC media server
two days ago I started looking into WebRTC, looked at a view examples and tested it a bit myself, and it looks really interesting.
However my qustion is, what would be a good way of implementing a ...
5
votes
1
answer
3k
views
Async() methods in WCF test client
I wrote a simple WCF service and when I debug the project I get a WCF client window in which each service method has an async() version (for example, for the method ConnectMessages() from the service ...
4
votes
3
answers
18k
views
C# - Websocket - Sending Message Back To Client
I've been working on a C# Web Socket server for roughly 24 hours.
I've currently figured out how to complete a handshake and get the connection initialized.
Also I've figured out how to take the byte[]...
4
votes
1
answer
8k
views
c# Access to the path denied on ubuntu 18.04 server
My friend and I wanted to make a discord server. I made the bot in c# and needed something to host it on so it can run 24/7, I've chosen Digitalocean. I created a ubuntu 18.04 droplet, installed ...
4
votes
1
answer
3k
views
TCP socket server how to tell when data received from client is complete?
I'm playing with some asynchronous TCP socket server code that I found at MSDN and I'm unclear on how to detect that I've received all the data that a client is supposed to send. In the MSDN example, ...
4
votes
1
answer
1k
views
How can I use SslStream/AuthenticateAsServer with a self signed cert/key?
I'd like to write (with C# and dotnet 4.8) a TCP service that uses TLS for security. To that end I'd like to use SslStream together with TcpListener, but I keep getting strange errors.
My experimental ...
4
votes
1
answer
7k
views
How do I run C# within a Node.js server application?
I have a node.js application and a C# algorithm. The algorithm puts out 15 numbers that represent symbols on a digital slot machine. The node server is posting and getting data from Firebase and the ...
4
votes
1
answer
2k
views
NetworkStream ReadAsync and Read in the same method
I'm trying to build a scalable server application with persistent TCP connections. The serialization library I use is synchronous and converting it to the APM would cause a big overhead (I already ...
4
votes
1
answer
39k
views
System.Net.Sockets.SocketException (10060): A connection attempt failed because the connected party did not properly respond after a period of time
I have a functionality to call rest services from my web application. I am doing this in c#.net code
My Code
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Accept.Add(new
...
4
votes
1
answer
6k
views
C# Unable to connect to remote server (WebException, SocketException)
I try to POST some data from a website to a webservice, but i got those exceptions :
System.AggregateException: Une ou plusieurs erreurs se sont produites. --->
System.Net.Http....
4
votes
1
answer
2k
views
processor affinity group C#
I'm using Windows Server 2016 with 72 cores. I see that there are 2 groups of processors. my .net app will use one or the other groups. I need to be able to force my app to use the Group of my choice.
...
4
votes
1
answer
209
views
Where is CurrentCulture retrieved from in C# application
I have an application deployed across several servers
When I display CultureInfo.CurrentCulture.Name using System.Globalization, some sites display en-GB and some en-US
Where is this setting being ...
4
votes
0
answers
658
views
How to get the requested target host from an SslStream as a server
With this code, for example:
private static void OnConnect(IAsyncResult ar)
{
var clientConnection = listener.EndAcceptTcpClient(ar);
listener....
4
votes
1
answer
637
views
How to read text file from server and store in dictionary using c#
I'm supposed to receive a text file from the server and then read the file and store it in a dictionary in the client.
I've read the file but I'm not sure how to take out the information in the file ...
3
votes
2
answers
3k
views
C# out of memory exception in GetThumbnailImage on a server
I am running the below code to create a thumbnail when a user sends us an image:
public int AddThumbnail(byte[] originalImage, File parentFile)
{
File tnFile = null;
try
{
...
3
votes
2
answers
8k
views
Why can't I connect to my server using my public IP?
I have a server program and a client program. While developing the program I run the server and the client on the same machine for convenience. The server starts listening to incoming connections ...
3
votes
1
answer
6k
views
C# Download all https certificates from a website
I want to save all certificates from a URL to disk. So for example https://www.google.de
If I browse this page with Firefox, I can see three certificates.
With Firefox I can export them all, and ...
3
votes
2
answers
11k
views
C# Async Socket Server - BeginReceive in Callback
I have a simple asynchronous socket server written in C# (pretty much Microsoft's example), however the issue with this example is that it accepts only one message from a client and then shuts down. I ...
3
votes
1
answer
2k
views
'System.Security.Cryptography.ProtectedData', version: '4.4.0' can not be found
I'm trying to deploy a .NET Core application on Windows Server 2012 Datacenter.
I have installed .NET Core Windows Server Hosting bundle and also made sure uCRT is installed (installed it manually)
...
3
votes
2
answers
3k
views
Grpc - send message from one client to another client that is connected to the same server
Is it possible to send message from one client to another client that is connected to the same server?
I want send data from one client to server Then send to specific client. I think I need to get ...
3
votes
2
answers
3k
views
Simplified LDAP/AD Server on C#
I've searched without much success to the simplest (and yet working) example of an LDAP/AD Server for C#. Many libraries exist to connect to LDAP servers, but not the LDAP Server by itself (on C#).
I ...
3
votes
2
answers
3k
views
Connecting MySQL Server 8.0 using C#
I'm trying to connect MySQL Server 8.0 running on windows to C#. Before this, I was using PhpMyAdmin but now I've installed MySql 8.0 Command Line Client and I want to connect my program with it. It ...
3
votes
2
answers
4k
views
How can server application check if a client application is online?
I have a server application which monitors the clients' activities in the network (all codes are in C# winforms). The server application already has IP addresses of client computers. I want to know ...
3
votes
3
answers
2k
views
Split messages over tcp
Im having a little trouble in a uni project. Im sending a tcp message from a C++ client to a C# server and the server is receiving it in 2 parts. Is it possible to stop it from down this? I output the ...
3
votes
1
answer
774
views
When using SignalR how does my Web Server know where localhost is?
I am using SignalR in a web application that is hosted on a separate server that has nothing to do with the client.
In the code, I have a function that connects to a SignalR Self-Hosted Service (C#) ...
3
votes
1
answer
420
views
C# Winforms Authenticate with Microsoft Onedrive
Is is possible to login to Microsoft's OneDrive API without having to use a Browser-based OAuth mechanism?
I have a server application in C# that I would like to connect to a OneDrive account and ...
3
votes
1
answer
609
views
Kill multi threading Server's thread c#
I have a program that starts a server thread, in that thread I wait for user connections, but sometimes (if the user presses "E") I want to close that server thread but it's not working. I tried
'...
3
votes
1
answer
2k
views
The method or operation is not implemented. while stopping IIS website in C#
So Let me tell you that I am developing a IIS monitoring Website in MVC 5
I try to stop an application within C# code but it always throw exception. mentioned in the title.
I am using code:
...
3
votes
1
answer
2k
views
Starting Opc Ua Server from public access to ServerManager Class throws NullPointerException
I tried to start an OPC UA Server this way: http://documentation.unified-automation.com/uasdkdotnet/2.1.0/html/L3ServerTutGSLess01.html
ApplicationLicenseManager.AddProcessLicenses(Assembly....
3
votes
1
answer
971
views
Compile C# code on server
I am using a remote windows VM to edit/develop a survey system. Using Microsoft Visual Web Developer 2010 Express as my IDE. I want to compile this project but the option is disabled. I’m not even ...
3
votes
1
answer
2k
views
Programmatically login 10 users to remote desktop session
I am trying to create an application that will programmatically login 10 users using RDP. The purpose is to autologin these users so someone does not have to manually do it. The first server I ...
3
votes
1
answer
3k
views
Simple Webrtc relay bridge Server in C#
I have a fully working peerTopeer (P1, P2) webRTC. To handle peerTopeer failures, I am trying for a simple exchange of bytes via a server in c# between P1 and P2 on a windows machine, as I don't want ...
3
votes
1
answer
3k
views
Best practice: Connect WPF to remote SQL database
I know that there are a lot of questions regarding this topic, however after four days of reading and googling, I am kind of stuck and need somebody to clarify some things for me please.
My situation:...
3
votes
2
answers
1k
views
Communicating Erlang server with c# program
I'm trying to write Erlang server for my program but still having some problem which I can't handle with. When using this (I wrote client in erlang to test server):
send(Socket, Message) ->
BinMsg ...
3
votes
0
answers
356
views
My multi-thread online Server gets too slow when multiple clients connect, C#
I'm trying to develop an online game just for fun, with a server and at least 2 clients playing in a single "room". My logic goes as follow, first have the server wait for a client to connect, after ...
3
votes
0
answers
1k
views
C# Launch Steam Game with server infos
Currently I am working on a program that should launch a steam game and connect it to a server. My code:
Process.Start("steam://rungameid/346110", "138.201.77.6:27015");
It launches the game, but it ...
3
votes
1
answer
2k
views
how to connect Signalr client to Signalr server on Different computers using winform
Hello guys i am making a server client architecture where each client is on different computer and server is on different computers so all client must connect to server but it's not working on ...
3
votes
1
answer
719
views
AuthenticateAsServerAsync hangs
I'm using
await stream.AuthenticateAsServerAsync(serverCert, true, SslProtocols.Tls, false);
In my application to secure a connection.
Unfortunately in rare cases (roughly one out of 1000) this ...
3
votes
0
answers
1k
views
ASP.NET MVC app take much more RAM on server than on localhost
I've got a problem.
My ASP.NET MVC project takes 9 MB RAM on localhost (tested at ants memory profiler) but at hosting (on server) takes about 400 MB while loading. Then about 150 MB RAM. Why omg? ...