Questions tagged as 'c#'

1
answer

Download Async + Copy = Copying image 0 bytes

I'm downloading simultaneously multiple photos, and also need to copy to a certain folder. What happens is that it does the copy before finishing the download. public static async Task DownloadData(IEnumerable<FotosProdutos> urls, int...
asked by 14.10.2016 / 16:28
1
answer

Foreach without repeating the name

I have a Foreach in View, and it contains Description, qtd and dta, how do I make a foreach without repeating the description? Ex: I have a product X whose 10 units were removed on 10/1/2016, 3 units on 04/10/2016, 8 units on 10/15/2016, how do...
asked by 18.10.2016 / 07:07
2
answers

You can save multiple values in a single bank field

I declare the field in the database like this: descricao VARCHAR2(5)not null, You can, for example, save 1 , 2 , 3 , 4 a single record) in the descricao field, where each of these values refers to a specific thing.     
asked by 16.10.2016 / 03:13
2
answers

How to check if the query did not return data?

I have a query is would like to know if it returned data. //classe aplicação- private List<tb_cabecalho> TransformaReaderEmListaObjetos(SqlDataReader reader) { var retornando = new List<tb_cabecalho>(); while (reader.Read()...
asked by 07.10.2016 / 16:38
1
answer

Fast and continuous exchange of the background color of a Panel

I'm trying to make a panel constantly change color with the following code while (true) { panelColor.BackColor = Color.Blue; Thread.Sleep(500); panelColor.BackColor = Color.Red; Thread.Sleep(500); } The problem is that the appli...
asked by 04.10.2016 / 15:46
1
answer

Why does not my DataGrid add anything? [closed]

public partial class TelaQuadroAdm : Form { public TelaQuadroAdm() { InitializeComponent(); } private void TelaQuadroAdm_Load(object sender, EventArgs e) { Quadro q = new Quadro();...
asked by 23.09.2016 / 04:57
1
answer

Repeat StackLayouts according to Xamarin Forms list

I created a StackLayout with a labels inside that I need to display some information in them. With this, I need to load StackLayouts and fill the labels according to the amount of records in the list. Example : Th...
asked by 22.12.2016 / 16:25
1
answer

What is the equivalent for the Handler clause in C #?

I'm following this tutorial to try to make Skype automatically accept lost friendships. The tutorial is in VB and I have to translate code for C # the problem is when I got the part of handler , I tried to translate the following code: Priv...
asked by 25.09.2016 / 14:44
1
answer

Fit the columns header into a DGV, C #

Is there any way to embed the columns into a DGV so that it does not overlap (Follow the img as an example). Or Resize the DGV so that it shrinks to the required size of columns ? at runtime. I'm using direct connection to...
asked by 24.09.2016 / 18:33
1
answer

Import data via SSIS or C #?

Hello I would like to know a more professional way to perform data import (TXT, CSV, XLSX and etc.) since today we do this via C # or by executing the SQL "Bulk Insert" command. If I should use SSIS or some other more efficient way of impo...
asked by 16.09.2016 / 16:34