Questions tagged as 'c#'

1
answer

Fill a treeview with a datatable c #

I have this datatable defined: DataTable datos = new DataTable("Coordenadas"); datos.Columns.Add("ID", typeof(int)); datos.Columns.Add("Ciudad", typeof(string)); datos.Columns.Add("Latitud", typeof(double)); dat...
asked by 31.08.2017 / 00:00
0
answers

Validate a List with Data Annotations

Good I have a list of objects, each object has a checkbox, if the checkbox is true I want to validate that the Name field and the Last name field have a value. My model: [ListHasElements(ErrorMessage : "Debe escribir en los casilleros")] pu...
asked by 25.09.2017 / 19:10
1
answer

Call ConsoleApp from python

Good morning. My problem is that I am trying to call a console application (made in c #) from python, and call the process in the same terminal. So I do not return the termianl to continue typing and in turn the exe of c # is only to listen to a...
asked by 05.09.2017 / 01:10
0
answers

does not let me create in the entitty framework

I have a problem creating a new headquarters = building. Pressing the save button in the create view gives me the following error:    Entities in 'Entities.RRHH_SEDE' participate in the   'FK_RRHH_MUNICIPIO' relationship. 0 related 'RRHH_M...
asked by 05.09.2017 / 15:49
1
answer

How can I resize the images before they are uploaded to the server? RAZOR - C # - WebMatrix [duplicated]

What I need is that the images before being uploaded to the server are compressed as much as possible in size in kb or mb, I do not know if this is achieved by changing its size in px before being uploaded, and at the same time Print a pre-def...
asked by 05.09.2017 / 16:12
1
answer

Same name of Column in different datagridview

Good afternoon, I have 2 datagridview, but when I add a column in the second datagrid that is already in the first datagrid I get the following: It is possible that you can not have 2 columns with the same name in different datagrid,...
asked by 29.08.2017 / 22:48
1
answer

Show Property of a second level entity in datagridview c #

Good afternoon, I'm filling a datagriview with a list whose entity is: public class ECliente { public int CLI_CODIGO { get; set; } public string CLI_NOMBRE { get; set; } public string CLI_RUC { get; set; } public string CLI_DIR...
asked by 25.08.2017 / 23:33
0
answers

How to print a document without saving it in advance. In C #?

I currently use the following function to print: private void SendToPrinter(string filePath) { ProcessStartInfo info = new ProcessStartInfo(); info.Verb = "print"; info.FileName = filePath; info.CreateNoWin...
asked by 25.08.2017 / 16:20
1
answer

Communication between opencv c ++ and Unity3D

I have a problem that I hope you can help me solve: I have to try to pass a cv :: Mat from c ++ to C # to convert it into a Texture2D. That is, I from c ++ capture the image of my Webcam using opencv. Once I have obtained the frame in cv :: M...
asked by 25.08.2017 / 08:50
2
answers

Get data from a DataGridView

How can I get data from a DataGridView? I have an object called dgvPersonas of type DataGridView, I charge data, they are shown correctly in the table and now I want to recover that data. Specifically select a row, to then obtain a column from t...
asked by 07.09.2017 / 23:42