Questions tagged as 'c#'

2
answers

How to make an UPDATE on a BD SQL Server from C Sharp

I have the following code which makes the query. private void EditarUsuario() { miconexion.Open(); string sql = @"UPDATE USUARIOS SET [USUARIO] = @USUARIO, [CLAVE] = @CLAVE"; SqlComm...
asked by 08.03.2017 / 06:05
3
answers

Using List as data source Datagridview ordered

Currently I have a very heavy database query that retrieves a lot of records, painting record to record in the datagrid is too slow so my solution is to retrieve the information through a datatable and then pass that datatable to a List to be ab...
asked by 23.02.2017 / 13:03
1
answer

Add data from one DataGridView to another from another form

I am making an application that allows me to loan several equipment or tools, so I have created a loan form that registers the user and another form that searches for the product in question. The data that I would like to send would be the id of...
asked by 27.03.2018 / 23:25
1
answer

How do I access the event clik of a button that is in a User Control from a Form?

I have a UserControl with a button (and several other things, but the important thing here is that button). In execution, for some action, the program places this UserControl in a FlowLayoutPanel of Form , once set thi...
asked by 11.06.2018 / 08:44
1
answer

Hover effect in C # panel

Is it possible to perform this animation effect CSS in a WindowsForms C # panel?    I do this, but obviously I do not get that result: private void panel_MouseDown(object sender, MouseEventArgs e) { panel_tit...
asked by 15.01.2018 / 22:43
1
answer

how can I use the same object already created in form1 in form2

I have this class public class lista { Nodo l; public lista() { l = null; } public void insertar(int elem) { if (l == null) { l = new Nodo(elem); aux = l; } else...
asked by 03.02.2018 / 19:24
1
answer

How to validate textBox so that it accepts point, comma, and only numbers in a textbox?

Today I come with a problem that I have not been able to solve, I have a textbox that should only be able to insert numbers, commas, and points. I have a validation but this validation allows to insert signs of admiration, interrogation, amon...
asked by 21.01.2018 / 17:17
1
answer

Delete rows from a datagridview

Hello I try to delete rows with the following code but I get an error. I have tried everything but I can not find out why it will not let me erase the rows of the data gridview. private void button_BorrarUv_Click(object sender, EventArgs e) {...
asked by 20.02.2018 / 09:21
2
answers

Problem 'System.OutOfMemoryException' when loading flat file

I am trying to load a large flat file (250 Mb) in a datatable but after loading a considerable amount of records (4 M), I throw the error 'System.OutOfMemoryException' DataTable listaTX = new DataTable("listaTX");...
asked by 11.01.2018 / 22:38
1
answer

Problem to connect Visual Studio project to MySQL database

My problem is as follows, and I can not find a solution. I have a MySQL database, which I want to manage from my application. I have a project in C # with Visual Studio, in which I am using the MVVM architecture, and I am trying to use the...
asked by 12.01.2018 / 17:22