Meeting the needs of your business from a distance

Debugging Exceptions in .NET

by Mark Shiffer 31. December 2007 23:41
If you are in a catch block that has not specified a catch type variable; therefore you do not have an exception variable, you can use $exception in the watch window to obtain the reference to the exception.

Tags: ,

Research | Programming

Missing Collection Classes in .NET

by Mark Shiffer 31. December 2007 17:26

The Power Collections library, original developed by Wintellect at Microsoft's request is freely available on codeplex. The library includes many generic list classes that I wish were available directly in .NET. Here is a sampling:

Bag<T> - Collection of unordered T objects; hashed; duplicates allowed

OrderedBag<T> - Collection of ordered T objects; duplicates allowed

Set<T> - Collection of unordered T objects; duplicates not allowed

OrderedSet<T> - Collection of ordered T objects; duplicates not allowed

Deque<T> - Double-ended queue

OrderedDictionary<TKey, TValue> - Dictionary with ordered keys; one value per key

MutliDictionary<TKey, TValue> - Dictioniary where key can have multiple values; keys are hashed; duplicates allowed; items unordered

OrderedMultiDictionary<TKey, TValue> - Dictionary where key can have multiple values; keys ordered; duplicates allowed

Tags: ,

Research | Programming

C# Properties

by Mark Shiffer 27. December 2007 23:19

Ran across this today and did not realize that it could be done. In C# you can apply a different accessibility modifier to the get or set method of a property than that of the overall property. The least restrictive modifier is placed at the property level and the more restrictive modifier is placed in front of the get or set. This would come in handy when you want the property to be public available for read, but restricted for write access.

public string Name

{

get { return name;}

protected set {name = value;}

}

Tags:

Research | Programming

Dell XPS One

by Mark Shiffer 26. December 2007 04:26
Okay, so I bought 3 computers last year alone; two of them were Dell computers! So I cannot really talk the wife into yet another computer at this stage, but if I could it would be the Dell XPS One for the living room or kitchen. The price is right (starting at $1400) and it looks awesome. Standard model comes with HDTV tuner, 20" widescreen, 2GB memory, Adobe Elements Studio, 250GB HD. Looks like an excellent deal. Anyone want to buy me one?

Tags:

Songza - Music on demand

by Mark Shiffer 26. December 2007 04:20
Ran across this website and I must say that I love it. You can type in practically any song you want and up it comes and will play on your pc via their browser embedded music player. I typed in 1234 looking for Feist and received about 20 hits including live versions, etc... Not sure of the legality, but it was published in PC Magazine not too long ago and provides the opportunity to purcahse the song, but that is done via a simple google search. The quality is very good. A simple loop back recorder on your PC and you could easily fill your hard drive. Merely an observation, not a suggestion.

Tags:

Websites

AppDomain and Static Members

by Mark Shiffer 13. December 2007 00:41

According to some text I am reading you should avoid having any static members on your MarshallByRef object as they will always execute in the context of the calling AppDomain and not your secondary AppDomain. I would think that could cause some interesting and complicated bugs within your code if you didn't know about that. I am documenting this here for future reference.

Tags: , ,

Research | Issues

AppDomains and Threads

by Mark Shiffer 13. December 2007 00:30
Ran across some interesting information in my research. This should be apparent to anyone who has created secondary AppDomains in .NET before, but for me my current work is the first time that I have had a need to implement this very cool feature of the CLR. Once you create an application domain and call a method in it, the method call is occurring on the current thread in a synchronous manner. The thread simply switches context between the default appdomain and your secondary appdomain. In my case, I have a scheduling application where I wanted to isolate the effects of the process, but also needed it to be multi-threaded. Thus the use of AppDomain, and also the auxillary use of threads to increase throughput for the scheduler.

Tags: , ,

Research

ConnectionString Format

by Mark Shiffer 11. December 2007 00:19

I ran across a website that gives you the formats for all of the various connection strings that you may need to make when hooking up a data source within VS. Every time that I have to type in one of these I have to look up the format for it, so this site should help consolidate all of my searching: ConnectionStrings.com

Tags:

Websites | Tools | Database

Crowdsourcing

by Mark Shiffer 7. December 2007 17:38
I ran across an interesting article on crowdsourcing at computerworld. The concept is interesting, and nothing new. I see the up and downsides to it, but from a professional perspective the risks involved out weight the advantages gained in my opinion. The possibility of intellectual property rights comes to mind as one of the largest down sides. What happens when you accept code from a crowdsourcing initiative and do not realize that it contains copyright infringing material? Sure, your own employees could do the same thing, but you have more control over them and the process. Which brings in another down side, without close monitoring and management, crowdsourcing would easily get out of control. The potential cost and time savings could easily be wiped out by the need for increased oversight. That being said, as the need for innovation and speed increase, crowdsourcing could be worth the tradeoff in some scenarios. I'll stop the diatribe now.

Tags: , ,

Research

Top Coder

by Mark Shiffer 7. December 2007 17:28

Interesting website that contains paid programming contests: Top Coder

Tags:

Websites

Copyright © 2001-2012 MS Consulting, Inc. All Rights Reserved.