|
Browse by Tags
All Tags » c# (RSS)
-
[quote user="CDarklock"]Not entirely true - they can only be value types because of that. [/quote] Still not entirely true: System.String is a reference type, but you can declare a constant of it. System.TimeSpan is a value type, but you can't declare a constant of it. I don't have...
-
[quote user="campkev"] [quote user="Spectre"][quote user="BlueKnot"]If the try block fails, but doesn't actually throw any kind of exception whatsoever, it goes 'BOOM'? [/quote] AFAIK, a parameterless catch block handles exceptions that are not derived from System...
-
Hello folks. First, let me introduce myself (quickly): I've been a developer for 5 years. I coded some winforms/webapps/console apps in VB6, then a lot web applications in Java and now I'm just using .NET (mostly C#). I'm NOT a "powercoder".I'm... let's say, probably slightly...
-
[quote user="Sitten Spynne"] That said, the thought of using recursive code from properties is a horrible WTF. Property access should never throw a property or incur a delay; recursion can cause stack overflows or take some time to run. This is a situation that calls for Get/Set methods, rather...
-
I don't think so... If he couldn't assign them at all, then he couldn't assign them to null in the first place. VB.Net does allow people to dim and initialize on the same line, whereas vb6 and vbscript do not. I would have set the object to what I needed it for, unless you have a reason not...
-
I work at a small (4-5 people) web/software company. We're involved on this ASP website (backend in C#), where we're doing the front end and there's this programmer on the end of Skype who's writing the code behind it. From my perspective it's been one WTF after another, but with...
-
I just came across this gem in a "DataHelper" class that is used to hold static data related methods for an entire application. When I confronted the apparent owner of the code of it's intended purpose, I eventually got the "I didn't write it, I just moved it because I thought it might be used elsewhere...
-
Hi all. Please excuse my english, as we speak spanish here. I have a problem with FileSystemWatcher. I had to monitor some directories, check for file changes... not big deal to figure out. I was about to build something using windows APIs, but my boss keeps on telling me to use NET and its controls...
-
That's a very interesting way of simulating the On Error Resume Next-statement in VB. Nice!
-
(I submitted this as a Code SOD but I post it here in case it isn't published) An ex-coworker of ours took the simplest of tasks and gave them a whole new level of abstraction. Some would call him a terrible programmer, I call him an artistic genius: private Decimal GetNumStatsPerPage() { int factor...
|
|
|