Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
D

dybs

@dybs
About
Posts
267
Topics
50
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Teaching Real-World Programming
    D dybs

    Communications of the ACM[^]:

    Conceptually simple features take longer than expected to implement.

    This statement is so true...

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Insider News java python wpf graphics question

  • Emergency Coding Pack
    D dybs

    Like several of the others, I've never needed an "emergency coding pack". If I need to do any debugging in the field then I bring a laptop with my dev environment. However, one tool I use frequently is LINQPad[^]. Comes in handy for testing short pieces of code, or just making use of a public api for a quick script without needing to fire up VS. The Dump() method is useful for inspecting objects on the fly as well.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge csharp beta-testing tools code-review

  • Try catch finally
    D dybs

    This is fine, although the

    Claudiu Schiopu wrote:

    catch (Exception) { throw; }

    doesn't really do much. You can just have the

    try

    and

    finally

    blocks, and the code would effectively do the same thing.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# database help question

  • Source file with repetitive data
    D dybs

    Not quite an answer to your question, but expanding on Richard's suggestion[^] of a static class, I also recommend the getter methods generate the command, rather than hard-coding them all. Of course, this depends on how your commands are structured. For instance, if each command includes the length of the data, or ends with a checksum or CRC, it's typically best to calculate that value and add it to the command, rather than hard-coding it. If all of your commands are completely different and don't have any common fields like this, then ignore this post :)

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# question csharp visual-studio com

  • Additional themes
    D dybs

    Overall the new design is good, but as others have mentioned, the sea of white can be a bit harsh on the eyes. It'd be nice to have the option to select different themes (maybe a gray for instance). Of course, it may be difficult to find other colors that go well with orange ;P.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    Site Bugs / Suggestions design learning

  • Login from top
    D dybs

    I'll admit I'm not familiar with Metro design standards, so maybe my suggestion should just be ignored, but here's my $0.02. Since the login fields are only visible while the mouse is hovering over the Sign In icon, it makes it difficult to use something like KeePass to auto-type the login. Granted, if I click the Login button, I can still get to a different screen with the login fields and it works, but it would be nice if this still worked from the other pages as well. Or even if the login fields stay visible after moving the mouse, and maybe the user to click outside the fields to dismiss the dialog? Dybs

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    Site Bugs / Suggestions design question

  • Circular list as vector, lock needed?
    D dybs

    OriginalGriff wrote:

    IIRC none of the .NET Collections are intrinsically thread safe

    Actually, .NET 4 introduced the System.Collections.Concurrent namespace[^], which includes a ConcurrentQueue. However, IIRC there's the potential for a delayed garbage collection - the queue keeps a reference to the object even after it's dequeued until it's been overwritten in the queue's buffer. This becomes more of an issue with a large-capacity queue. Our workaround was to use the Mono implementation of the ConcurrentQueue instead (it doesn't have this problem).

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# question csharp graphics help

  • Why Panasonic, Why?
    D dybs

    There's no "F-lock" key? I've seen some Microsoft keyboards that default F-lock on to enable all the secondary functions. Very annoying.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge tutorial help question

  • Access to the path is denied
    D dybs

    Also make sure that file doesn't already exist on your system and is not open by another program (or even your own).

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# help

  • Console App - Scheduled Task - Text File
    D dybs

    Also make sure nothing else has the text file open when the scheduled task runs.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# question

  • Console App - Scheduled Task - Text File
    D dybs

    Does the task scheduler display an error code next to the task when it runs? Also, check the Application event log around that time and see if there are any errors (although as Eddy mentioned, it's a very good idea to catch any exceptions and log them for later debugging - but the Event Viewer might display the exception as well).

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# question

  • .NET profiler
    D dybs

    The CLR Profiler is definitely great tool for finding memory issues, but not so much for performance bottlenecks. ANTS comes in handy for those issues (although ANTS does have a memory profiler as well, but I like CLR better).

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge csharp question

  • .NET profiler
    D dybs

    AspDotNetDev wrote:

    The bottom right of the ANTS page shows awards, including "The Code Project Members Choice Winner 2011". :-D

    So it does :)

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge csharp question

  • .NET profiler
    D dybs

    I've been using ANTS from RedGate[^]. If you're on Windows 7, it also lets you attach to a running .NET 4 process and just profile what you want, rather than profiling from startup. One of my colleagues uses DotTrace from JetBrains (same guys who make ReSharper)[^]. I think it also lets you attach to a running process. They've both been great tools for us, sometimes one will show us something the other doesn't, so sometimes it's nice to have both.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge csharp question

  • Guitar Hero? No, FIRE HERO!
    D dybs

    Amazing, I wish I had time for cool projects like that.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge com question

  • How well do you know your TryParse()?
    D dybs

    I think foo would be zero, but that's just a guess. I think Int32.TryParse and Double.TryParse set the out parameter to zero if the parse fails, but I don't recall. If TryParse fails, I usually set the value to some known default that I can handle - I don't care what TryParse sets it to, especially is MS decides to change it down the road.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# csharp com tools question

  • Learning C# through exercises
    D dybs

    LINQPad is great. I use it all the time for testing small snippets, one-time mini-programs, and just playing around to figure out how to use a .NET feature. The Dump() method is particularly useful for getting a feel for the structure of an object you're not familiar with.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# learning help tutorial question csharp

  • My computer died
    D dybs

    Assuming they're visible on the pcb, you could follow the traces from the power button to the ribbon cable connector, determine which wires in the cable are for that button, then find the corresponding pins on the mobo. But that sounds like more effort than I'd like to go through :) . Times like this make it nice to have a Asus P8Z68-V Pro/Gen3[^] that has power and reset buttons directly on the mobo.

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge adobe hardware question discussion

  • My computer died
    D dybs

    Colin Rae wrote:

    I'm not entirely sure how you could test that though

    If you unplug the power button from the motherboard, you can short the two pins briefly to power it on (I typically use a flathead screwdriver ;P).

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    The Lounge adobe hardware question discussion

  • Read from Byte Array
    D dybs

    Be careful when using BitConverter. It uses the endianness of your CPU, so if you're byte array is coming from a hardware device with a different endianness, your BitConverter results will be messed up. See BitConverter.IsLittleEndian[^] Dybs

    The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen

    C# question data-structures
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups