Remote Connection want work.
I tried to make a remote connection in c# but faild. Here is my code, can somebody help me? string strAppDir = Path.GetDirectoryName(Assembly.GetExecutingAssembly().GetModules()[0].FullyQualifiedName); string strConfDir = strAppDir +…
why when i type } in visual studio C# it matches with a different { basically it looks like this:
so my question is why is the first { highlighted with the } at the end of if (movemnt > 0.05) {anim.SetBool("isRunning", true); {anim.SetBool("isRunning", true)
Windows Key container
Hi, My application stores data in an SQLite database. I want to store 1 attribute encrypted so that it cannot be changed outside the program. This may only be changed from within the program. I don't want to put the key for the encryption in the code.…
C# foreach loop for true boolen
Good Afternoon, i have created a program that a class will check if bool is true or false but the issue i have is a simple, if(elfbool1 == true ) { then do something } this works fine but i want to check each bool at once as i want each…
How many Serilog logger instances should be created for different .net app on same machine?
I am new to Serilog. Trying to understand below scenario. If we have 2 different .net application/controls referring to common serilog config file. The file will contain custom prefix tags corresponding to each application. Each app/custom control has…
How to override ToString of double?
I want to override the function of a double how to do it? for example: double total=0.5; string t=total.ToString(); I want it return a format that is specified.
ArrayTypeMismatchException Source array type cannot be assigned to destination array type
I'm tying to get the values in a manually created array into a System based array. Exception Details: System.ArrayTypeMismatchException Message=Source array type cannot be assigned to destination array type. StackTrace: at…
![](https://techprofile.blob.core.windows.net/images/Ux1t8yHNFUmzhY3Zut5I0Q.png?8D88EB)
![](https://techprofile.blob.core.windows.net/images/Ux1t8yHNFUmzhY3Zut5I0Q.png?8D88EB)
C# How to capture console window close
I found few write up for this topic https://stackoverflow.com/questions/4646827/on-exit-for-a-console-application …
![](https://techprofile.blob.core.windows.net/images/bpqI_wINOUGg4BYYipkUVA.png?8D827C)
Xamarin Forms, How can i send the items from a ListView by email
Hi Xamarin Community, I need help with something I am wondering around, how can I send pdf file using Xamarin forms, but in the file I need to bind the items in my listview like description, price, quantity, Hope you can help me Regards
![](https://techprofile.blob.core.windows.net/images/EYfv0aPkdUeP1_hq3r1-mg.png?8D8C4E)
Xamarin Forms, PDF ListView Using PDFSampleListRendererDelegate
Hi Xamarin Forms Community, I am desing a PDF from a listview, but I have a question about the margin of the image attachment I will put the code here: public class PDFSampleListRendererDelegate : PdfListViewRendererDelegate { …
![](https://techprofile.blob.core.windows.net/images/oNyICRtWQ06TbELY4U4oWQ.png?8D88A9)
Problem Serial Port bytes missing with write method
Hi everyone, I am using Visual Studio 2013 (C#) in order to test serial port. I have an array of bytes and I am trying to send it via Serial Port using two USBSerialConverter. The data that I receive is between 14 to 18 bytes of lenght (it change…
C# XML file - collect all elements with the value.
Hello, I have a XML file and need to collect all values from YPOS into a new list with index and value. How can I easily reach this? Thanks in advance. The goal is a list with Index, YPOS 1, 41.352 2, 51.352 3, 61.352 4, 71.352 …
C# regex that should start with alpha numeric but not with space
Hi , I am trying for regex that should take only AlphaNumeric as first character but when i go with [A-za-z0-9], it is also taking white space as valid, how to avoid space as first character in regex C#. please help. below are some valid and…
What is "localhost:44313"
I have an ASP.NET project working with IIS on Azure. In Web.config I have <add key="Url" value="https://localhost:44313" /> and there is a call in the C# code WebRequest request = WebRequest.Create(sURL); where sURL =…
Different nuget-packages are used when compiling using VS and compiling using MSBuild
Consider following .csproj file: <Project Sdk="Microsoft.NET.Sdk.WindowsDesktop"> <PropertyGroup> <OutputType>WinExe</OutputType> …
C# equivalent of Python's pack/unpack and sum?
Is there any function equivalent to Python's struct.pack and struck.unpack in C# that allows me to pack and unpack values like this? comman_type = 1 command_class=5 command_code=0x14 arg0=0 arg1=0 packed_message =…
How will click-once work when upgrading to .Net 5.0?
We have several WPF applications that we distribute using Click-Once delivery. Fortunately this technology continues to work, mostly, as we don't want to start dealing with direct client installations. Will this technology continue to be supported with…
![](https://techprofile.blob.core.windows.net/images/CL9sTc5zkUClnOVlnXO8DA.png?8DCA31)
Can you answer this queue act?
Accept characters using the Implementation of Array Structure, then save it to Queue. If the value to be stored in the queue is equivalent to input of the user, count and display its occurrence. Count the total values inputted by the user. If…
Impersonate session security context error without applying impersonation
Hi, So I have an app that creates a SQL connection with MARS enabled and also impersonation, but it doesn't do calls in more than one thread (legacy system), and that app calls a service that also creates a SQL connection with MARS enabled, but without…
![](https://techprofile.blob.core.windows.net/images/c4mRkDtLdU6n6fSv2i9uBg.png?8D843C)
Mocking IEventGridClient using the Moq library
I'm trying to mock IEventGridClient from the Microsoft.Azure.EventGrid NuGet package with the Moq library for unit testing purposes. Mock<IEventGridClient> client = new(); client.Setup(x => x.PublishEventsAsync(It.IsAny<string>(), …
![](https://techprofile.blob.core.windows.net/images/PoffudUF4UKngNj2ZyNaEw.png?8D9C1A)
![](https://techprofile.blob.core.windows.net/images/PoffudUF4UKngNj2ZyNaEw.png?8D9C1A)