Questions tagged as 'c#'

1
answer

Unity3D: How can I move GameObjects from the same script independently?

I created a script in Unity3D that causes a GameObject to move sinusoidal. The movement occurs perfectly, but when more than one GameObject containing this script is in the scene all move like a mirror of each other and not in a...
asked by 17.02.2017 / 20:53
2
answers

TimeSpan time difference in 24hr format

I am asking this question because I have not located any topic with my problem, which is very similar to others. I have 2 fields TimeSpan? with one referring to the entry time and the other to the exit time . I want to know the t...
asked by 07.02.2017 / 14:56
1
answer

Return message along with UnauthorizedResult

I'm using .NET Core 2 to create a dependency that will be injected into an API. The idea is to create a middleware to control incoming requisitions and act on a set of business rules. It is worth pointing out that I can not change the API itse...
asked by 12.09.2017 / 16:43
1
answer

Converting DOCX File to PDF C #

I have an application and I need to convert a file DOCX to PDF without losing the formatting. I found some DLLs that help, but for corporate use you have to buy licenses so it gets tricky. Complementing I did some more resear...
asked by 29.08.2017 / 17:26
1
answer

How to generate Thumbnail using MediaToolKit

I need to generate a thumbnail from a video when uploading it to my application, I would like an explanation of how to use the MediaToolKit to do this, thank you in advance.     
asked by 17.03.2017 / 20:39
2
answers

Auto Refresh in Xamarin.forms application from time to time

I'm developing an application that on the main screen will have a few buttons, and these buttons access a URL sending commands on and off all through HttpClient and persisting all this information. I have the following scenario: I have 3...
asked by 29.03.2017 / 22:55
1
answer

What is AsyncPostBackTrigger Class?

How should I use and what does this type of class?     
asked by 26.03.2017 / 04:25
1
answer

Iterate an array (vector) via IEnumerator? For what reason?

In what case would it make sense for me to forgo an array using loops "normal" ( for/foreach/while ) via index to use IEnumerator as shown in Example 3? Example1 //Usando for int[] array = new int[]{1, 2, 3, 4, 5 };  ...
asked by 20.03.2017 / 12:10
1
answer

How to bulkcopy an excel file into an sql table

I wanted to bulkcopy an excel file into an sql table. But it's giving me this error when I try to send to sql:    System.InvalidOperationException: 'The specified ColumnName' TransDate '   does not match any column of data source. ' The co...
asked by 30.10.2017 / 12:09
2
answers

Doubt in method declaration [duplicate]

Note the following code: class Program { int marks; static int maxmarx = 50; void CalcularPorcentagem() { int porcento = (this.marks * 100) / Program.maxmarx; Console.WriteLine(porcento); } After tes...
asked by 26.07.2017 / 15:16