Questions tagged as 'c#'

1
answer

Group repeated items from a list and add their values C #

I have the following list: List<String> datos = new List<string>(); In it I keep the following data: datos.Insert(0, nomMaterial); //Material1 datos.Insert(1, "$" + costoMaterial);//500.00 datos.Insert(2, areaCuadrada);/...
asked by 14.12.2018 / 02:00
1
answer

Show the product category as a list item in a foreach on asp.net mvc

I have a list in the Sales model where I usually display all the products, but now I need to display the category to which they belong, but only once, for each product category, how could I do this? This is an example of what I want to do P...
asked by 01.12.2018 / 13:46
2
answers

select an item in a DataGridView

very good, I'm trying to select an element of a DataGridView, however, I can not get the selected item because the 'SelectedItem' function does not appear the following code private void myData_SelectionChanged(object sender, EventArgs e)...
asked by 19.10.2018 / 22:50
1
answer

bootstrap-datetimepicker error date format, Asp Mvc

I have in one view an inputbox on which I am using bootstrap-datetimepicker to capture the date, this DTP has the format 'YYYY / MM / DD': <script type="text/javascript"> $(function () { $('#datetimepicker1').date...
asked by 10.06.2016 / 23:53
2
answers

Convert Text to Bar Code C #

I want to convert a text string entered in a TextBox to a barcode, but it has an error: Error: No se puede convertir implicitamente el tipo 'System.Drawing.image' en 'String' I use the following instruction: libraries: using Bar...
asked by 03.09.2018 / 22:53
3
answers

Store variable value when reloading a Windows Form

Good morning, I am developing an application in C # using Windows Forms and user controls, the application that I am developing is a small project for a restaurant which in the table interface, what it does is to click on the corresponding ta...
asked by 06.09.2018 / 23:52
2
answers

Save the value of the Click event in a variable

I am programming for a practice a set of questions in windows forms, which I have a textbox with the question and 3 buttons with the options. The question is how could you save the value of the click of each button on a variable (any) since t...
asked by 28.09.2018 / 00:07
1
answer

Associate a set of tables using linq

Hello, I am trying to reference a set of tables to be able to use the data of some records. For this he used the following: void asociarcamposforms() { var idpedido = Convert.ToDecimal(Request.QueryString["idpedido"]);...
asked by 25.09.2018 / 22:02
3
answers

Modify a cell and save its modification from a DataGridView

I am developing an application for the control of labels for the company where I work. I am working with a DataGridView which stores the data entered from the first Textbox as shown in the following image: When the application starts, t...
asked by 10.08.2018 / 01:26
1
answer

How can I start my assembly in c #

Hello, I previously asked about an error that I returned when loading my assembly. But now my question is once loaded as I start it? The code of the function is. internal static Assembly AssemblyHome(byte[] data) { What I do is: v...
asked by 02.01.2018 / 12:01