Questions tagged as 'c#'

1
answer

How to make a date in ISO 8601 format but be in the same a DateTime [closed]

I wanted to know how I can transform a DateTime into an ISO 8601 format but keep it in a DateTime type     
asked by 28.08.2017 / 16:39
1
answer

How to get the correct DPI?

I'm trying to get DPI from the monitor, but it always returns 96, I've researched and found a lot of people with the same problem. float dx, dy; Graphics g = this.CreateGraphics(); try { dx = g.DpiX;...
asked by 14.08.2017 / 06:35
1
answer

How to unlock the accordions even when some excepetion

I have a screen that frees accordions as soon as the client's code is validated with personal information, etc. But if some exception occurs it locks the accordions , how could it be done to make it clear even if it gives som...
asked by 14.08.2017 / 19:37
1
answer

Problems communicating with the webService made available by the government [duplicated]

I have a problem communicating with the eSocial webService, my certificate is correct, but still can not establish a secure connection, it displays the following message: "Error making HTTP request for     
asked by 21.09.2017 / 16:28
1
answer

Enable tabbing in fields ReadOnly = true | Visual Studio

Hello, I have this code in the event of the ComboBox, when I select that it is Physical person it enables the pertinent fields and blocks the ones of "Legal" person and vice versa. But it is still possible for me to move over the fields disab...
asked by 21.09.2017 / 18:35
2
answers

Connect to SQL with AppConfig

How can I make a connection to SQL with the connectionstring in AppConfig? I did this, but I wish it could be by AppConfig, how can I do it? private void button1_Click(object sender, EventArgs e) { string connectionString = @"Da...
asked by 21.09.2017 / 16:24
1
answer

How to use AsNoTracking when working with Repository

I have a generic repository and I have a Controllers for each of my entities. eventoContactIdOcorrenciaRecebida = dtoEventoContactId.ObterPorCodigoEvento(Convert.ToInt32(codigoEventoContactID)); When I do the search it returns the value cor...
asked by 22.09.2017 / 14:17
1
answer

Question about vector [closed]

I'm trying to list the numbers that the user types but I'm not finding the function, can anyone give me a light? class Program { static void Main(string[] args) { int[] atividade = new int[6];...
asked by 19.08.2017 / 04:13
1
answer

MethodInvoker does not update listBox C #

How to implement a timer that every cycle updates a listbox in C #; Method to create the timer: private void CriaTimer() { System.Timers.Timer aTimer = new System.Timers.Timer(); aTimer.Elapsed += OnTimedEvent; aTimer.Interval =...
asked by 13.09.2017 / 22:41
1
answer

Open Form in tabcontrol specifies

Command to open a form in a specific tabcontrol. Example: in a form I have a tabcontrol with two tabs: register and consult. Then I wanted (with a button) to open this form directly in the consult tab.     
asked by 28.07.2017 / 20:26