I need to create a C # executable and I have the doubts: Do with thread or do with task ?
In practice is there any difference between using Task and the "traditional" multi-thread ??
Is it true that a task...
How can I compile a string inside C #?
Example: Console.WriteLine(\"Hello World\"); .
As if it were a eval of JavaScript?
I had a project to load a code into a text file or something else.
I have a big question as to where to put my query SQL, whether in the code or the bank .
I currently have a procedure that is set up according to the parameters I have, ie filtros .
Procedure
@escopoVerificacao varchar(MAX) =...
In .NET you can see the multiple ways to initialize a string with an empty value, commonly known as "double quote".
Is there a proper way to do this? And what would be the practical difference between using:
var nome = String.Empty;...
I often see terms like LINQ query and lambda expressions .
Then the question came up, What I'm doing is a LINQ query, a lambda expression, or both?
Ex1:
var query = Produtos.Where(p => p.Descr.StartsWith("A")).Take(10);
Ex2:
var...
I'm using MSTest which is the default unit testing platform in visual studio and I have this test here:
[TestMethod]
[ExpectedException(typeof(InvalidOperationException))]
public void Board_nao_destroi_unidades_flutuantes()
{...
When I put a constructor of a class in C # as private , I get the following error:
I would like to know the technical explanation for the reason for this error and if there is any use case of constructor (or one of the constructors)...
I have the following value:
43239.110000000001
I used this command:
txtSomatorio.Text = String.Format( "{0:#.#,##}", somatorio);
I achieved this:
43239,11
How do I display it like this?
43.239,11
Although I am aware of what would be best to use, I ask this question for teaching purposes since I see several examples of people using double in C #. But I've had problems with double for coin calculations and read in several pla...