Browsing 7239 questions and answers with Jon Skeet
I think you're looking for U+263A. The best way to represent this in source code is with a Unicode escape sequence: val smiley = "\u263a"; You then need to check that: Your database is able to store it (check the type of your field,... more 7/26/2014 7:32:20 AM
EDIT: Okay, through comments I think we've actually got to the bottom of the problem. The situation is: Compiling under Windows There are two classes in the same file, with the same name except for case The command-line compiler doesn't... more 7/25/2014 5:47:39 PM
All you need to do is move the initialization expression out of the field declaration and into a constructor: public class MainClass { public string Something; public SubClassA A; public SubClassB B; public MainClass() ... more 7/25/2014 2:45:09 PM
I have a small source file which print the exact value stored in a double. Code at the end of the answer, just in case the link goes away. Basically, it fetches the exact bits of the double, and goes from there. It's not pretty or... more 7/25/2014 12:21:22 PM
This is the problem: doc.Elements("Category") That's looking for root elements called Category (the root element is the only direct child element of the XDocument). You... more 7/25/2014 11:55:40 AM
I know that & operator returns bool That's only true when the operands are bool as well. The & operator is either logical or bitwise, depending on its operands. From the documentation: Binary & operators are predefined... more 7/25/2014 10:46:21 AM
Fundamentally, you're modifying a list in one thread while iterating over it in another, and the list implementation you're using does not support that. The ArrayList iterator implementation appears to only detect invalid modicifications... more 7/25/2014 8:00:39 AM
How about: boolean x = Boolean.TRUE.equals(value); ? That's a single expression, which will only evaluate to true if value is non-null and a true-representing Boolean reference. more 7/25/2014 7:40:02 AM
You're unconditionally writing out the whole of the buffer on each iteration. You should only write out as many bytes as you've just read: int bytesRead; while((bytesRead = inputStream.read(infoBytes)) != -1){ output.write(infoBytes,... more 7/25/2014 7:33:28 AM
Code (high-level: c#,vb.net - human understandable) is compiled in VS and dll/exe is generated This is called IL (this is also more or less human understandable). You need to differentiate between the binary form of IL, and the... more 7/25/2014 7:16:50 AM