Questions tagged as 'c#'

2
answers

Method equivalent to BigInteger.and () in C #

I need to convert the java code below to C #: public static boolean verificaPermissao(BigInteger perm1, BigInteger perm) { if (perm1 == null || perm == null || (perm1.equals(BigInteger.ZERO) || (perm.equals(BigInteger.ZERO)))) ret...
asked by 04.05.2017 / 19:15
2
answers

Close connection to database C #

I am making a login system and I get the exception sql message when I try to create a new account in the database: MySqlCommand usuaExiste = new MySqlCommand( "SELECT * FROM contas WHERE nome = '"+textBox1.Text+"'", bdConn); bool resultado...
asked by 21.02.2014 / 20:45
3
answers

What are the consequences of programming in 32-bit or 64-bit?

Would it be only the memory capacity that is limited to 4 GB in 32 bits? Do I need to have specific concerns? I know what's different about C, I want to know about C #.     
asked by 26.04.2017 / 16:01
2
answers

Unity 3D and Android, how to manipulate txt file?

How to do in Unity 3D read a arquivo txt line by line and store in a vector using C #. Well, I was able to manipulate arquivo .txt , however in Android it does not work. Follow the code I used. int counter; str...
asked by 03.01.2016 / 00:15
2
answers

Is there any way to run C # from the command line in interactive mode?

I'm used to using PHP and Python, languages that allow you to run in the command line in interactive mode, so it's easier to test or learn something new, since I do not have to compile all the time (as it is in case of C #). Is there any way...
asked by 17.05.2016 / 21:44
2
answers

Foreach C # vs ForEach () EF6

Follow the code below: % of EF6%: var result = ctx.Table.Where(x => x.User == "João").ToList(); result.ForEach(x => x.Read = true); ctx.SaveChanges(); ForEach() of C #: var result = ctx.Table.Where(x => x.User == "João...
asked by 07.06.2017 / 20:45
3
answers

What are these attributes in the properties?

What are the names of these "Attributes" and what are they used for? Examples: in a class declaration: [ComVisibleAttribute(true)] public sealed class SerializableAttribute : Attribute in a property declaration: [XmlElement] public...
asked by 23.12.2014 / 10:55
1
answer

Extensive number for number

I would like to convert an extended number to normal int; example: FunçãoParaConverter("trinta e dois") // retorna 32 FunçãoParaConverter("mil vinte e quatro") // retorna 1024 FunçãoParaConverter("mil t...
asked by 15.12.2017 / 20:16
1
answer

The parachute descends head down. How do you reverse it?

I made a Unity rocket that I can take off and land after five seconds. However, it lands like this: Iwanttogethimtogettothegroundwiththeparachuteup.HowcanIdothisforthecode?CodethatIhavesofar:doublet=5.0;voidUpdate(){GameObjectParaquedas;GameO...
asked by 24.02.2014 / 00:22
5
answers

Create objects within a List without for / foreach C #

private List<Compra> CriarCompras(int numComprasParaGerar) { List<Compra> lstCompras = new List<Compra>(); for (int i = 0; i < numComprasParaGerar; i++) lstCompras.Add(new Compra()); return lstCompras; }...
asked by 29.09.2015 / 14:43