Questions tagged as '.net'

4
answers

Button with pause function

I have a small application that inserts images into the database. There are many images and sometimes I need to stop the execution for a period and continue at another time so as not to disturb the work of the client. Anyway, my application i...
asked by 30.01.2015 / 12:28
1
answer

Get specific amount of characters from a textbox

I'm trying to get a specific amount of characters typed into a texbox, the current code is as follows: novaconfiguracao.CupomEstabelecimento = tb_NomeFantasia.Text.Substring(0,48).ToString(); In case of typing less than 48 or more than 48 g...
asked by 05.12.2014 / 18:58
1
answer

Change Windows registry key values

Is it possible to build an application that searches for a key in the Windows registry with an exact name and when it finds its value changed by a user-defined value? If possible what is the best language to implement this? VB.NET?!     
asked by 20.05.2014 / 12:42
2
answers

Keyword for C # equivalent to "synchronized" Java

Problem I'm implementing a connection manager that implements the standard Singleton , managing a pool of single-key connections for each new connection. So I'm trying to get problems with the parallelism of my manager, because it can be c...
asked by 17.08.2016 / 13:53
1
answer

Check if entered value is numeric and if it has 9 characters

How can I check if a value is numeric, and only numeric (no occurrence of periods, dashes, etc.), regardless of how many characters the number contains, in addition to having exactly 9 characters, neither more nor less?    Examples accepte...
asked by 20.03.2014 / 16:55
3
answers

Format a string with time

I'm trying to format a string that already has date and time, but this string just has to get the time I'm trying in this way more does not work: > Recovering from the database. string dtSolicitacao = String.IsNullOrEmpty(Convert.ToStri...
asked by 27.08.2015 / 14:01
1
answer

Error while trying to connect to SQL Server from webservice in IIS 7.5

I'm getting some errors when trying to perform a query on SQL Server from a WebService hosted on an IIS 7.5 server. My connectionString in web.config: <connectionStrings> <remove name="LocalSqlServer" /> <add name="TE...
asked by 17.09.2015 / 18:54
1
answer

Is it possible to get a specific line of txt / csv file using an address?

Is it possible to access a line from a file txt / csv (example below) at its address directly without having to go through each line using C #?     
asked by 17.10.2014 / 20:06
2
answers

Refresh the label without crashing the program

I need to update my label at all times when I use timer it updates, but it crashes the program Program.cs public static String Uso() { ManagementClass mc = new ManagementClass("win32_processor"); ManagementObjectColle...
asked by 11.11.2015 / 18:04
2
answers

How to add an 'ul' in an 'li' HTML element via C # code?

I'm going to have a list with multiple clients, and I wanted to add those clients to a ul element of the HTML element, you have to add those clients dynamically (since each search performed on the system can bring a number of clients) via...
asked by 16.09.2015 / 22:37