Monday, June 27, 2005

Keyboard Hacks

I came across a post where some bloke actually took off the physical key for CAPSLOCK, because he often hit it accidentally. But some posted this comment which is a registry hack to the CurrentControlSet to capture the keyscan.

My complaint on lots of laptops, is that the Windows key is off in some obscure, difficult to reach location. I know IBM, and presumably others have key re-mapping utilities, but I thought they ran continuously, which I don't like. If this can be specified in the registry that sounds good. I need to do some more research.

Pragmatic Programmer

These guys have written much thoughtful stuff about how to effectively get software written.

Here is a link to a notable post at Andy Hunt's blog about limiting work hours to a reasonable number each week: 40+ Hour Week Known to be Hazardous

Thursday, June 23, 2005

Updates - User Group meetings, NerdDinner, etc

I've been pretty busy and neglected to report on a number of meetings I attended in the past week or so.
The highlight for me was joining the Chicago NerdDinner on Tuesday evening at the Rock Bottom Cafe. In attendance were the organizer Ryan Rinaldi, two renowned utility developers Jeff Key and Brian Scott, plus Eric (?) and Dan Ankers(?) two contractors who have worked long term at Wm. Mercer, plus myself and John(?). There was a lot of stimulating discussion along with plenty of food and drink. Eric has been programming a long time and seems to have an architectural view of his work. He offered a number of good thoughts on O-O design. When I raised a question I have been working on he encouraged the use of interfaces versus abstract base classes, which led to a heated discussion. He apparently has a well written blog, but I don't have the address yet.

Last night I attended the VS2005 'codefest' that CNUG and Chris Mayo ran at the MS Office in Downers Grove. I ended up doing the code walkthrough as pair programming with Joe Alfano, which was fun, but the whole event was rather chaotic. I suspect spending three hours there might be more produce more learning if the workshop were conducted more formally with someone leading it and questions being shared to the whole group.

more to come...

Last week's CNUG meeting had two good presentations.
One, by Rob Steward of Data Direct on data access with ADO.NET, and
another on ORM frameworks by a man from Miller Brewing.

CWUG group was a mixed event, but I wanted to attend because Bill Zielger was talking about malware, and that is relevant.
I did pick up a few tips, but have to check my notes for them...

Thursday, June 09, 2005

Using External Drives in WinXP via USB2

I have posted a comment on this to an earlier post, but am going to do some linking to resources here.

I have some enclosures for external drives with USB connection. Trying to put in a totally new unpartitioned drive did not seem to work. I had to first install the drive in a box, then Initialize it, Partition it and format it. Is there any way to do from the USB port?
Once the drive was ready I was looking into how to use it. I think I will mount it as a volume instead of with a drive letter. Searching for information on the process of doing this I came upon a couple of command line utilities I had not seen or used before:
DiskPart.exe - for doing disk management
MountVol.exe - to Mount/Unmount volumes

This appealing titled KB article, How to create and use NTFS mounted drives in Windows XP, actually only discusses using the Management Console plugin. So I searched for info on the proper way to use the command line tools.

This site by Rick Lively has a good summary of MS OS commands.
Here are two relevant examples of his manual pages:
MountVol.exe
DiskPart.exe

I find searching on a command at Technet always brings up Server2003 versions, which can be different. I don't see a Technet analog to the advanced search at MSDN. Maybe I should try MS Support. OK. That gave me at least one good article that is on topic:
A Description of the Diskpart Command-Line Utility
And a couple of others of possible interest, slightly off topic:
How to move the temporary files location for Windows XP CD recording
How to Use the Backup Utility to Back Up Files and Folders in Windows XP Home Edition

PS - This google directory for Windows XP lists some WinXP help sites, but they weren't terribly helpful.

Wednesday, June 08, 2005

Listening to Aaron Margosis TechEd webcast

Well, I'm sitting here waiting for Aaron's webcast to start...
OK, here we go...

Apparently lot's of people in the audience have tried running LUA and given up.

He says on Windows XP Workstation that there really are only Administrators and Limited Users. That is obvious on XP Home, but also true on XP Pro. On XP Pro, Power User is essentially Admin. A power user can elevate privilege at will.


He uses some analogies:
Would you always leave the house with 50 grand in your pocket, when only need dollars.
Would you always carry sharp scissors/a knife, just because you need them sometimes.

He has a slide titled "User Exposure" which lists categories of dangerous apps - really all Internet-facing apps.

He made surprising observations on allowing accounts with a blank password on XPHome. He thinks it is a good thing, since internally Windows restricts privileges of an account without a password. It can only be used to logon at the machine console and cannot access network resources, along with some other restrictions. So he feels it is ideal for some home accounts.

He also talked a bit about Rootkits. They are only an issue if your system has already been compromized and then they try to hide their presence. Very interesting and sort of scary. He explained the ongoing arms race between writers of the rootkits and those trying to detect them.

Lot's more, but for that I will post a link to the webcast when it is up.
Overall that was a very worthwhile session. Particularly the way he emphasized that while running non-admin is the right thing to do, it is not a magic bullet.

Tuesday, June 07, 2005

BBC Radio 3 doing a Week of Beethoven Extravaganza

Starting Sunday morning BBC radio3 has been doing a continuous presentation of ALL the music of Ludwig van Beethoven. While mostly they are just broadcasting familiar recordings it also includes interesting commentary by Alfred Brendel and others and some live concerts each day. Really quite a treat, though perhaps over top.

Mark Russinovich speaks on Malware at TechEd

This afternoon the remarkable Mark Russinovich, of SysInternals, gave an illuminating presentation on Malware and how to prevent or clean up from it on Windows. It was quite instructive, especially on the 'RootKit' threat, which I had not properly understood. One theme was again to run LUA! I will add a link when the on-demand webcast is posted.

Sunday, June 05, 2005

Thoughtful Critique of VB.NET

I came upon this insightful article by Richard Grimes on the origins and value of VB.NET, when reading blogs about the controversy over MS support for VB6. (His site at www.richardgrimes.com has several educational articles on issues of .NET security and deployment.)

Some Microsofties wrote rebuttals to Grimes. Dan Fernandez has a detailed response on his Blog. He focuses on issues Grimes raises about the .NET platform and the CLR. I was not entirely convinced by his refutation in one area where Grimes raised questions - the degree to which .NET is or will be integrated into the Windows platform.
Regarding VB.NET, Duncan MacKenzie has a short post on his blog, and links to
Scott Swigart who has a long post that has many comments, including one from Grimes. Some are juvenile, but many are worth reading.

Saturday, June 04, 2005

Software Design Patterns

I need to return to the study of patterns. I've never gone through the Gang Of Four book, only worked on a few of the basic patterns that are widely discussed such as 'singleton', 'facade', 'factory' and 'abstract factory'. But none of those seems revelant for what I am trying to do.

For the presentation layer I want to expose collections of widgets and a limited view of certain widget properties. But the internal structure of the widgets I want to keep private. There are old dumb widgets that a current implementation uses. Those I need to read, and also still export to. But my current app will use smarter widgets, so I don't want to publicly expose the old dumb widgets at all. I thought I might make the old widgets internal structure a private class inside the collection class but I can't make that work - no way to make the individual widget properties available outside. Well, I'll keep working...

[update] Some browsing (see links below) led me to this good article posted at MSDN from August 2000: Engine-Collection-Class, a Design Pattern for Building Reusable Enterprise Components. It is long rather complete article, describing the details and benefits of using the ECC pattern, with components in C++ and a VB6 client app.

(Aside) It is very irritating that in VB currently properties must have the same scope for getters and setters. Seems obvious that one would like them to be different. And I don't see any good workaround to that.


What about Patterns references...

Let's see what Google gives us...

General
Portland Pattern Repository (wiki)

for "facade pattern":

Asynchronous Web services operations using JMS

Friday, June 03, 2005

IPC Protocols, issues

When I look at NET SHARE on my boxes I generally see one for "Remote IPC".
I figured it stands for Interprocess Communication but that doesn't tell me much.
Googling hasn't been too helpful either, but I did find a couple of general articles on IPC, not really on the Microsoft protocol or usage:

One by Eric Hopper Why I think CORBA and other forms of RPC are often a bad idea

And he linked somehow to this interesting aside...
http://www.mathpages.com/home/kmath302/kmath302.htm