Questions tagged as 'c#'

2
answers

How to make a line break to send an email to a user with HTML? [duplicate]

I send an email to the user who signs in to the application. I'd like to know how to do the line break so that it stays the way I want it to. Here is the code I use: private void newUserEmail(string email, string sexo, string usuario)...
asked by 29.05.2017 / 15:19
2
answers

In a TextBox, with the MultiLine property true, the character \ n does not change the line

In a TextBox the character \n does not change the text line, eg: textBox1.Multiline = true; textBox1.Text = "IMPRIMEEMCIMA\nIMPRIMEEMBAIXO"; However, the \t character works. I also noticed that on a label the same text prints...
asked by 28.06.2017 / 13:00
2
answers

Error: Not all code paths return a value

The following is the error:    "CustomerLogon (string, string)": Not all code paths   return a value class Conta { #region atributos public String nomeCliente { get; set; } public String numAgencia { get; se...
asked by 12.07.2017 / 01:20
2
answers

Filtering by dates - Verification of months 31 and February [closed]

I have the following code: Example code, you should debug and follow the "lstItem" variable to understand its operation using System; using System.Collections.Generic; using System.ComponentModel; namespace TesteRotina { class Progra...
asked by 18.11.2015 / 14:10
2
answers

How can I change the appearance of the form according to the operating system?

When I develop a project in C # (Windows Form Application) the appearance of the application window (borders) is according to the OS in which I'm running the application (Windows XP, Vista, 7, 8, 10)! WINDOWS XP WINDOWS7 How would I...
asked by 10.04.2018 / 02:30
2
answers

How to change button color using RGB or Hexadecimal code?

I have a WinForms application and would like to use colors that are not in the default settings of the Color object, how could I do that? For example: How the code is: this.btnLogout.BackColor = System.Drawing.Color.Red; Example o...
asked by 08.04.2018 / 23:43
3
answers

How to remove the first item from an array without for or foreach

How to remove the first item from a non-foreach array. I have tried this, but it says that there is no remove or removeAt method. int[] arr = {1,2,3,4,5}; var removeu = Array.Remove(arr,0);//Agora percebi que isso é javascript, rs This...
asked by 06.07.2015 / 22:57
2
answers

Sort files by name c #

I have several files like this: - C:\ByMe\SOLUTIONS\Dictation1\Database\Updates1717_04170405_TR_CREATE_TABLE_BMTApprovalGroupExam.sql - C:\ByMe\SOLUTIONS\Dictation1\Database\Updates1717_04170405_TR_CREATE_PROC_BMSPInsertNewApprovalRequest2.sql...
asked by 29.05.2017 / 14:00
2
answers

high school equation c #

I made this code to calculate bhaskara, but it is not responding to values a = 1, b = 8 and c = 16. I can not understand why it is not working specifically for these values. using System; using System.Collections.Generic; using System.Compo...
asked by 06.06.2017 / 15:08
2
answers

How to make the main form invisible C #

How to make the main form created by Visual Studio stay invisible after opening another? I tried using the "hide ();" command, but I did not succeed. code: using System; using System.Collections.Generic; using System.ComponentModel; using S...
asked by 02.08.2017 / 13:32