Questions tagged as 'c#'

2
answers

Error Backing Up Windows Forms Database

I have problems with this problem! My application is in Windows Forms. I need to back up the data through the application itself, but when I run to perform it it informs me of this error. https://i.stack.imgur.com/e5cq8.jpg "> Note: My backu...
asked by 21.06.2018 / 18:04
1
answer

How to declare and pass a decimal variable from XAML to C #?

<StackLayout> <Label Text="Digite um Valor:" Margin="10" HorizontalOptions="Start" VerticalOptions="Start"/> <Entry Keyboard="Numeric"/> <Button Text="Calcul...
asked by 11.06.2018 / 15:41
1
answer

How can I get drive information from C #?

Good afternoon, I was asked to carry out a project that can fetch information from the drives ( C: , D: , such as how many drives there are, the name of each one, the total space and the space used. But I do not know how I'll get this info...
asked by 26.06.2018 / 15:51
2
answers

Error trying to use class / method of a library.

I'm trying to connect a WPF with external hardware through the usb. I installed NuGet HIDSharp and declared USB Devices as below: HidDevice _device; HidStream _deviceStream; IEnumerable<HidDevice> _deviceList; That's within public...
asked by 20.03.2018 / 22:26
2
answers

Error at the time of summing inside the foreach

I have this method CadastroDespesas , only it is doing the wrong sum in the foreach that runs through my list. I do not know what it is, if someone can help me ... A totdesp is a global variable declared in my class)...
asked by 14.03.2018 / 20:04
2
answers

Error inserting a "SELECT" item in the Combobox

How do I add an item in the Combobox? The item has to be first in the list with the text "SELECT": I'm doing this: private void PreencherCmbIndicacao() { try { this.cmbIndicacao.Items.Cl...
asked by 04.03.2018 / 23:36
1
answer

Is it necessary to pay anything to use asp.net?

I've heard that .NEt is not free and that I have to pay for Microsoft if I publish a .NET application. Is this true? If I want to install the technology on a web page server will I have to pay something?     
asked by 05.03.2018 / 13:26
1
answer

Integer to String Conversion [duplicate]

I'm creating a cafeteria system. I created the login system and it is working, when I was creating a page to create the logins, I am having difficulty converting the level from int to string - the txtNivel.Text does not...
asked by 27.02.2018 / 17:56
2
answers

Can you simplify this amount of conditions?

I have the following code: foreach (var lote in collection.ToList()) { count++; ushort[] dadosBalanca = new ushort[9]; if (lote.AlvoPasso > ushort.MaxValue) {...
asked by 19.02.2018 / 16:27
1
answer

Save time to register in the database

I have a form and whenever someone registers, I need to save the time of the registration in my table Historico2 within the property DateTime? Quando . public partial class Historico2 { public int ID { get; set; } [Required]...
asked by 25.02.2018 / 21:50