Questions tagged as '.net'

1
answer

Run fast things synchronously and things delayed asynchronously?

Generally, in .NET, I run time-consuming things asynchronously so I do not catch the visual thread . In a simple example, if I have a loading in the UI, in case slow things run without awaited , they catch that loading , which was execute...
asked by 18.02.2017 / 11:41
2
answers

Doing operations / handling DateTime

The idea is for the user to type in a textbox a horaEntrada and in another the horaSaida in which case these 2 variables should have the format "HH: mm" hours and minutes, only, after that by method get and set...
asked by 03.11.2016 / 22:03
1
answer

Negative return of Array.BinarySearch ()

I needed to make a comparison of the genre of methods normally created as inList or something of the sort. Searching the Microsoft documentation, I found Array.BinarySearch(T[], T) . I made this operation in my code and I was in dou...
asked by 01.02.2016 / 18:44
2
answers

I need a code that gives the error AccessViolationException

My teacher has passed a series of exercises and in them I need to create a code to give the error AccessViolationException . But I am not able to create a code that from this error (I do not want to do the error handling). I need someth...
asked by 19.09.2015 / 20:03
2
answers

Can an exception cause the closing of a SqlConnection?

I am building the connection treatment and this question came to mind, even though I could not find a satisfactory answer. So I came here to ask the most experienced programmers. Is there any possibility that when a exception is thrown a...
asked by 06.01.2016 / 17:06
2
answers

Get partial name of a process

Is there any way I can get a process that is running by a partial name, like what happens with like in a SQL search? Why I ask this: I have a team viewer custom here for the company. The problem is that if I happen to h...
asked by 07.01.2016 / 20:40
1
answer

Is there any free algorithm to check for C # syntax?

I am creating a small text editor that has C # code. Is there any way from within the program itself, regardless, to check if the syntax is correct? Note: I'm not using C # to do the text editor. I'm just after a syntax algorithm. It can be i...
asked by 24.12.2015 / 15:09
3
answers

Close the panel when the mouse comes out

I have Panel in a Form any where Panel is less than Form . I need to do the following: when the mouse leaves the top of Panel it should be closed how could I do this? Note: I'm trying to do this in Windows...
asked by 08.12.2015 / 13:29
1
answer

Increase the size of a string

Is it possible to increase the size of a string in the code? string sIdentComanda = ""; if (objComandaParametro.ComandaParametros[0].IsControlaNrComanda) { sIdentComanda += " Comanda: " + nrComanda; }...
asked by 27.08.2015 / 15:54
1
answer

Error in DateTime attribute in C # writing to MySQL

I am trying to insert into MySQL database the date of birth of the user, in C # the attribute date_match is of type DateTime and in MySQL the attribute date_match is of type Date , to insert C # I am doing doing so: DateTime nasci...
asked by 28.04.2016 / 13:34