Colin Bendell

Sofware and Business Technology Evangelist

28 December 2014

Saving Money by Investing in Performance: A Financial Model

We know that improving performance can affect revenue in many situations. Performance can also save the business money and reduce costs. Simple financial modeling can show why investing in performance makes business and financial sense! For Example:

A copy of my financial model can be found on google docs

Read more
30 September 2014

Responsive & Fast: Iterating Live

Read more
24 September 2011

Mechanical-Mechanical Turk (for the Enterprise)

Amazon's Mechanical Turk is a crowd surfing tool to help maximize the liquidity in the work force. If task X will take 1000 hours to complete, using the power of the crowd, you could break this task up and get 100 people working on it, thus completing the task in 10hrs. (Aside: Amazon's service is affectionately named after Wolfgang von Kempelen's 1770 chess-playing machine pictured above

Unfortunately, most enterprises have become even more guarded about intellectual property leakage that Amazon's service mostly inaccessible to large organizations. Yet, it is in large enterprises that could most benefit from a local Mechanical Turk service:

  • To varying degrees all employees have spare cycles that go unused
  • In large organizations, department boundaries prevent collaboration and utilizing
  • Route tasks are often solved with spending money on consultants or third party services
  • New ideas are often stifled because of lack of time/energy to initiate and build momentum

The larger an organization becomes, the more in-efficient it becomes. This is a function of increased bureaucracy, department silos and political relationships. A private Mechanical Turk service would help break down these barriers and leverage the spare brain power and time in the organization without having to worry about intellectual property leakage. A private Mechanical Turk service would befit the enterprise by:

  • increasing net productivity
  • decrease departmental silos
  • foster innovation and skunk-works projects
  • increase collaboration and idea sharing

What other ways could the enterprise benefit from having a private mechanical turk?

Read more
15 May 2010

Don't buy a lawn mower - share one

Isn't it funny that each home owner in north america has somehow been convinced that we need to buy our own lawn mower? I bought mine right after I bought my first house. I checked out all the models. Shopped around for the best price and weighted the choice of gas v. electric v. push mower. In the end, I bought my one. After all, the lawn needed cutting!

But then, as all dutiful home owners do, I stored it in the shed, and pulled it out once a week for 45 minutes. It's kind of silly that I would spend that much money on something but only use it for so little time.

Here's my proposition - buy only one community lawn mower for all the houses on your street. One mower to share. Each person chips in a few dollars for maintenance and (gasp!) gas. When you add it up, that's a lot of money saved and one less thing to clutter your garage.

There are other benefits from sharing a lawn mower too:

  • the number of lawn mowing gas engines leaking oil into the ground is reduced
  • save space in the shed / garage
  • you meet your neighbours

Think of all the other power tools that we could probably share amongst neighbours instead of each person buying their own!

Read more
15 March 2009

Fixing the Usability of the Pause Button

The Pause button is broken. It's broken because you resume exactly where you left off. As more audio and video becomes available via on-demand, the usability of the pause/resume button will become more important and will become a distinguishing feature among players.

For music, where you resume the song is not very critical. However, for longer content, such as video or podcasts, the pause/resume functionality is much more important. When you resume, you often lose key plot points and generally lose time rewinding the content.

Typically, you Pause a video or audio because you are interrupted - you are switching tasks. When you return to your movie, tv show, or podcast, it takes you a few moments to get back into the frame of mind when you left off. This is called the cost of task switching. As a result you often end up having to rewinding the stream a few seconds into the past and then restarting.

Here are 5 ways to enhance the usability of the Play/Pause button:

  • Paused Video and Audio content should automatically resume a few moments in the past - not at the pause position.
  • The amount of automatic time shifting should be proportional to the length of the content. For example, A short podcast, should backtrack a second or two while a TV show should resume 3-5 seconds in the past. Feature length films might rewind even up to 30 seconds to a minute.
  • Time-shifting should consider the nearest scene change or audio lull.
  • If the content is played on a computer, *the *Pause ** point should be set to when the mouse starts moving before the paused button is pressed.
  • If available, the reflex time should factor into the Pause point. (eg: the time between moving the mouse over the pause button and actually clicking the pause button)
Read more
01 March 2009

Timezones & DST Version 2.0

Timezones and Daylight Savings Time are antiquated ideas that need to be replaced. I propose that they be replaced with a new Universal Time that would synchronize the globe

Standard Time was an invention for the emerging global economy. A version 1.0 if you will. Of course it was never implemented with the order that Sr. Sanford Flemming originally envisioned. Standard Time solved these problems:

  • each city had a different noon and midnight based on the local view of the sun
  • communication and train schedules were complicated and convoluted

Standard Time introduced:

  • 24 zones representing 15 degrees of latitude that would use a consistent time
  • each zone would be exactly 1 hour different from the next
  • colloquialisms such as 'noon' and 'midnight' remained with minor changes

Unfortunately, Standard Time had its own set of problems:

  • confusing when a political region is divided into multiple time zones
  • scheduling meetings and coordinating events are problematic since Noon is different depending on your local timezone
  • Therefore timezones became organized using political boundaries instead of latitude zones causing broad inefficiencies of the use of solar time

Daylight Savings Time was finally enforced after WW2 as an attempt to reduce the use of incandescent light bulbs at night (the primary use of electricity) and ultimately maximize the sunlight for working hours.

However, DST has its own serious drawbacks:

  • DST doesn't reduce electricity use but increases electricity consumption
  • psychologically, people are more likely to go out in the evening if it is light after work - thus more automotive & gas consumption
  • Schools and office buildings use more gas/energy to warm up in the morning because the ambient temperature is lower due to the darkness.
  • DST is least efficient for central US states and Canadian provinces and benefit the East and West costs the most.
  • In these central states and provinces DST is not observed causing switching costs and potential loss of productivity during the adjustment.
  • Each country has its own DST rules

Ultimately DST is an inefficient attempt to recreate the solar efficiencies that local-time once had.

As we move to a more and more globally dependent economy, timezones still introduce complexity and communication hurdles when dealing with different organizational units spanning the globe. Often businesses will adopt a single timezone to communicate companywide (often choosing the timezone of the company headquarters) More importantly, we are looking for ways to optimize our daily routine to minimize utility costs. Heating big office buildings in the dark hours of the morning is less efficient than letting the sun heat them up and

To solve these problems, I propose a new Universal time. We'll call this Version 2.0 for timekeeping in a global environment. Here is what I propose for the New-Universal-Time:

  • Globally adopt a single timezone for timekeeping. Ideally this would be UTC, but I'm fine with arbitrarily choosing NST too.
  • Each region locally defines how to maximize solar time. For example, in Boston, the local hours of business could be 13:00 to 21:00 while in San Francisco it could be 16:30 to 00:30

Aside from the transition period, this will solve the two major problems: 1) communication consistency and 2) maximize daylight to minimize electricity/gas consumption (and minimize SAD). While each city/state/region will define their own business hours there will be a universal language to communicate the difference.

Now, when someone on the west coast proposes a meeting at 22:00 (middle of the local solar day) the person on the East will say, "sorry I can't make it, I'm putting my kids to bed then."

Of course, I realise that while the benefits might be many, getting wide spread adoption will be next to impossible. It'll likely happen right after the US adopts the metric system.

Read more
16 February 2009

Next Generation Neilson Box - Using iSight to Track Advertising Reach

Let's be honest. The real reason that Neilson Boxes track TV watching patterns is to ultimately report Advertising reach to they people paying for the TV programs - the advertisers. Neilson reports to the stations what shows were watched and when. This data is correlated with the commercials and fancy charts are produced when the station is wooing a new advertising client.

The problem with the internet is, while we know a lot more about advertising impressions, we also know a lot less. When a commercial comes on the TV, consumers watch only the commercial. It's eyeball monopoly. When an ad is placed on a webpage, the ad is competing with the content on the page for attention. Eyes bounce over advertising with great ease.

But what if you could track a person's eye on the webpage? This would be valuable information. It would not only give feedback to the effectiveness of the placement and layout, it would also provide another valuable metric - eyeball attention.

There are two ways to track eyeball movement: * indirect using the movement of the mouse. People read with their mouse, so just track the movements of the mouse * Use the computer's built in iSight to track the person's eye movements on the page.

All Mac computers bought over the last few years come pre-equipped with a webcam facing the user. iSight is the colloquial name for this webcam. The webcam is present not just on Macs these days, but also on Dells, Lenovo's and most other home computers.

Why not pay users a small fee to watch them as they surf the net?

Sure it's more intrusive than a Neilson Box, but the information would be immensely valuable. Even today we don't know if the person was actually in the room when the ad played on TV. Tracking eye movement on a webpage (and correlating it to the window position and the contents of the viewport) is a relatively simple computational task. The big challenge will be getting user adoption.

Would you allow a third-party computer program to watch you as you surfed the net?

Read more
15 February 2009

How to Save the Zune (by Conceding Defeat to the iPod)

The truth is that the Zune is not the success Microsoft hoped for. Even now there are rumors that Microsoft will look to shut down the Zune as the company tries to cut costs.

Instead of trying to beat Apple using Apple's trategy, Microsoft could beat Apply by conceding defeat. Instead of trying to build an eco system of proprietary adaptors and peripherals, Microsoft should make the Zune compatible with the ecosystem that Apple has already created. The Zune should be able to plug in and use every iPod enabled product already available.

Even if they have to pay a licensing fee to Apple, Microsoft needs to adopt Apple's adapter standard. This will lower the cost of switching and consumers will be more willing to 'try' the Zune. Microsoft's greatest strength is embracing the existing ecosystem. This is how Microsoft won the first round of the OS wars.

Microsoft's strenth is compatibility, while Apple's strength is usability. Microsoft should bat to their strengths instead of trying to emulate the competition. As I see it, this is the only way that they can win the music player wars.

Read more
04 February 2009

Preparing to Live Longer: Living to Eleventy-One

Over the last 50 years, the average life expectancy of a person has been increasing at a rate of 5hours per day. Tomorrow you are expected to live 5 hours longer than you were expected to live today.

Today, my life expectancy is supposed to be around 80 years of age. Once you adjust it, my average life expectancy is around 100 years. If I'm above average by even one standard of deviation I could easily expect to live to 111.

The problem with projecting life expectancy is that we don't have very many data points. The people that are dying now, are people that lived through the depression, used asbestos for their table clothes, and smoked like a chimney.

However, I'm willing to bet that the average increase in life is not a regular average, but an increasing average. Meaning, that I might very well expect to live until well past 120 years.

So what? If I can reasonably expect to live to well past 100, or 120 years old, then:

  • I can't retire at age 50 or even at age 65 and have enough money to hold me out
  • I should plan to work well into my late 70s
  • I have another 45 years of my career ahead of me
  • Retirement is not an option. I should be plan mini-retirements throughout my life now.
  • While I might live longer, my risk of neurological degeneration dramatically increases! (near 100% chance)
  • I should be "investing" my donations into research into Parkansans, alzheimer's, etc.
  • The rate of global population growth is underestimated.
  • A significant boom in the health care industry (especially palliative care) is set to boom.

Some interesting Ted Talks on the subject:

Read more
01 February 2009

Public Transit Part 2 - Starting Fresh

I've asked before: can we fund public transit without Tickets, Tariffs, or Taxes? The obvious follow up question is: how can we reduce the cost for public transit?

The challenge for many of the old subway systems is that the technology has changed, and they are left with an infrastructure that must be maintained. For example:

  • Boston, London and Toronto (to name a few) used to use coal engines. This meant that the tracks could not be enclosed in glass because the space was needed for ventilation.
  • Without enclosed tracks, you can't automate the trains with robotics for safety reasons
  • The ventilation system is based on the movement of the cars. Enclose the tracks and each subway stop needs to be redesigned and equipped with new HVAC systems. Very Pricey.

Unfortunately, public transit is typically built after the need is causing pain. Municipalities start with buses until they get overloaded, then they move to trolly cars, and then finally to rapid transit.

But if you were to build a new rapid transit or public transit system in a budding city, how would you build it? Here are my suggestions:

  • Developers should band together and build corridors through new developments. In the short term it could be used for public parks. When the city grows, it can be resold to the city - at a premium - to make easy access to the suburbs.
  • Focus on skytrains instead of underground subways. This makes it more subject to the elements, but substantially decreases in the implementation cost
  • Use smaller cars of various sizes (2 person, 4, and 6 person) that are queued at each station and can be introduced into the transit system on-demand. This requires robotics and queue planning (so that empty cars are available at source stations at all times). The result is higher variable cost, and lower fixed cost.

Any other suggestions?

Read more
28 January 2009

Virtualized Microsoft Office for Mac

Microsoft should stop developing Office for Mac and instead ship Office for Windows running on a Virtualized Windows environment on OSX.

Microsoft Office for mac is a paradox for Microsoft:

  • Microsoft can't risk losing the income from Office for Mac - It's 10% of Office sales.
  • Office for mac makes it easier for PC owners to switch to Mac.
  • Microsoft makes money from office, regardless of whether the person is using OSX or Windows.
  • Its cross platform support means 2X the cost of development
  • Making sure it works consistently between OSX and Windows increases the cost substantially
  • Features in Office Mac lag that of Office Windows.
  • Feature adoption slows because of the lack of cross platform support - especially in enterprises.

So what should Microsoft do? Microsoft needs to get back into Virtualization.

At the same time that the Mac has risen in popularity, so has Virtualization technology. Virtualization allows you to run a different Operating System inside your primary Operating System. This way you can run Windows in OSX with very little performance loss. VMWare and Parallels are just two of many companies competing in this space. Unfortunately, Microsoft pulled its Virtual PC product for Mac several years ago.

Instead of developing a separate product called Office: Mac, Microsoft should develop one version of Office. The Mac version would simply be Office for Windows running in a virtualized environment of windows.

The benefits?

  • single development cycle
  • consistent user experience
  • additional revenue - from selling the virtualization environment as a standalone product
  • Office for Mac would mysteriously runs a little slower than the Windows counterpart
  • The best side-effect? How do you speed up Office for mac - Use Windows.
Read more
25 January 2009

Paying for Public Transit Without Tickets, Tariffs, and Taxes

!()[/uploads/2009/01/90920427_cde3d93d29.jpg]

Is there another way to pay for public transit? Could we even make it free?

There are three ways that most municipalities pay for public transit:

  • Tickets - where each rider pays per trip
  • Tariffs - where the people who don't use public transit pay a fee (see London, UK)
  • Taxes - where everyone pays a portion whether you use the system or not

Unfortunately, public transit has a very inflexible cost structure:

  • huge setup cost (sometimes >$20 million per km)
  • large fixed cost - the buses and subways run on a schedule, regardless of ridership
  • very low variable cost - a very small incremental cost for fuel per rider

This means that whether people use the system or not, the municipality has to pay the bills -including labour, fuel, and maintenance. Therefore, the public transit system needs to be efficient and valuable to attract the maximum number of riders.

This leads me to wonder: *Are there other ways to pay for public transit other than Tickets, Tariffs and Taxes? *

For example. While people pay for tickets to go to the movies, the revenue hardly flows to the movie theater - it goes straight to the producers. Instead movie theaters make their money on the value-ad, on the popcorn and soda sales.

Further, could you give away public transit for free and make money via another revenue stream? (Much like advertising to Google's free search).

These are just questions for now with no real answers. Some possible answers could include:

  • targeted or focused advertising (such as forcing people to watch tv commercials)
  • up-selling for cellphone or wifi coverage during the trip
  • selling comfort or convenience on longer trips (such as padded chairs, etc)
  • integrated restaurant ordering systems so your table is ready for you when you get to the restaurant or your pizza is waiting at your door by the time you get home

This is just the tip of the iceburg. What other ways can public transit be funded - without asking riders to pay more for each trip?

Read more
14 January 2009

Reboot 2 - More to come.

Ideas.
Lots of them.
They're locked away in my head.

Soon, these Ideas about life, business, technology and society will find a home here.

No filler. No Bull. Just Ideas.

Take 'em. Use 'em. Make them you're own. These Ideas are for everyone. Open to the public domain.

Read more
30 March 2007

Arrays in Sql 2005

Have you ever wanted to do something like:

SET @InventoryArray = "1,2,3";
SELECT * FROM Invetory WHERE InventoryID in (@InventoryArray);

or what about:

SET @BarList = "1, 2, 3";
INSERT INTO Foo (Bar) SELECT * FROM @BarList;

I know I have. It always seems to come up in power searches and migration tools. Unforunately, Sql Server 2005 doesn't have anything close to arrays. Oracle does, but not SQLServer.

Erland Sommarskog, SQL Server MVP has written a great paper titled Arrays and Lists in Sql Server 2005.

This paper explores the various techiniques that can be used to coerce sql server into using arrays and the effective performance of each strategy. It is a lengthy article, so if you just want to skip to the results check out the Data from Performance Tests Appendix

Read more
19 December 2006

Fix: install problems with Visual Studio 2005 SP1

There is a quick fix if your install of VS 2005 SP1 fails with a message to the effect that the digital certificate cannot be verified. Please follow the instructions in kb925336. Unfortunately you'll have to restart a couple of times in order to complete the install.

Yay.

Read more
20 November 2006

IE standalone (6.0, 5.5, 5.01, 4.01, 3.0)

While IE7 has been released there are still many users who have IE6 (and even 5.5) running on their desktops. With Multiple-IE you can install stand alone versions of IE6 through IE3 on your desktop without the bulk of a Virtual Server image. This will let you easily test IE7 and IE6 simultaneously.

(While you are at it, you should also install Firefox to test the usability for the other 13-18% of users)

Read more
14 November 2006

A lesson from Zune on World Usability Day!

Today is World Usability Day! From their website:

"Why doesn't this work right? What am I supposed to do with this now?"

World Usability Day, November 14, 2006, is for everyone who's ever asked these questions. This Earth Day style event, focused on raising awareness and visibility of usability engineering and user centered design, is currently being organized by volunteers and local event coordinators from around the world. Whether a usability professional or just an enthusiastic (or frustrated) user, each participant is making a contribution to "making life easy".

To commemorate this day, MS has a few lessons to teach us with their recent product, Zune. We will title this lesson "Why Usability, and QA testing are important (aka Installing the Zune sucked)."

Read more
11 May 2006

A one year expirment on bot traffic

Drunk Men Work Here performed an experiment over the last year to observe how different search bots walk and index a site. The results are very interesting.

Read more
10 May 2006

Firefox, Safari, and other great web development tools

Moleskin has, yet another, list of very useful webdevelopment extensions for firefox. I don't know how I lived without some of these extensions!

And, on the topic of web development, SafariTest is a great tool which lets you see how your web page would look in Safari (OSX). They've even got a public test server that you can login and use (via VNC) to test Safari.

Read more
28 April 2006

press F1 to continue.

Two decades ago, the XT introduced a novelty to their keyboard - 10 function keys. Then a few years later with the AT (circa IBM's failed 186) the 102 keyboard came out sporting not 10, but 12 function keys. This was kind of cool back then when dos applications had extended functionality that forced users to wrap their hands in inhuman ways (I'm looking at you borland ... and you wordperfect). But even then the function keys were hacks and therefore hard to write a program that used these keys - function keys did not have a unique scan code but instead had a double byte scan code (0 + value) which made it difficult to use efficiently.

Fast forward to the current day: keyboard use has mostly been relegated to typing and those extra features are now the domain of the mouse. However, Windows has maintained use of function keys in order to support backward compatibility to Windows 2.0 (remember that glorified file manager?). But for the average user, unless they are using Autocad or the unusable TextEdit, the function keys are left to collect dust.

Unfortunately function keys are here to stay. In fact if you have a modern keyboard you get all 12 function keys and a host of "media" keys to confuse you with. So in order to help you use these keys more efficiently, I've compiled a list of the most common uses in windows. Can anyone help me fill in the gaps?

  • F1 - help
  • F2 - rename
  • F3 - find next
  • F4 - close a window (^-F4) or close an application (@-F4)
  • F5 - refresh
  • F6 - cycle through open MDI windows (^-F6)
  • F7 - ??
  • F8 - ??
  • F9 - ??
  • F10 - activate the file menu
  • F11 - ??
  • F12 - ??
Read more
23 March 2006

Visual Studio 2005 Web Application Projects

Microsoft has updated the addin: VS2005 Web Application Projects. This will allow you to create web applications that behave more like they did in VS2003 (so you don't have to use the VS2005 'Website' project).

Features include: * compilation to single assembly in the \bin folder * project file that contains all files related to the project (allows you to hide files) * allows direct migration from vs2003 web applications

Update: Here's an alternate download. I'm not sure what the difference is though.

Read more
19 February 2006

MSBuild: A disappointment

The number one thing going for NAnt was that it learned from Java Ant but was not bound to the ideology and religious conviction of the Java Ant developers. The Java Ant architects assumed that you would only use Ant for compiling/building your product. They failed to realise and/or ignored the possibility that Ant could be used for much more than just building, include things like deployment and automation. Unfortunately, because of the conviction of several of the key architects, Java Ant still does not have an "if" task. (Oh sure you could mangle the "condition" task and leverage the "depends" attributes to do what you need, but the resulting code is very ugly and un-maintainable!).

NAnt was, therefore, in a position to grow from the stable library code of the Jakarta project and address the needs of the userbase. When NAnt entered the scene they had a lot of extra features that are lacking from Ant such as an If task and a much more extensible expression language.

Microsoft had a prime opportunity to learn from Ant and NAnt and deliver a rock solid, highly useable, strongly typed, xml scripting language backed by a legion of developers. Instead, Microsoft decided to ignore the experience of the community and re-invent the wheel. MSBuild assumes that it would be used to build your solution(s) - nothing more. Heaven forbid if you should want to deploy or automate with a 'build' script. Not to mention the severe lack of pre-bundled tasks and flexibility that any developer would need for standard build scenarios. I find it appalling that a non-Microsoft group would have to contribute an 'add' task. This should have been baked into their expression language.

I have been attempting to write a collection of useful MSBuild tasks for my current project. Unfortunately at every corner I turned I realised that there was more library code and supporting tasks that I would also have to create - functionality that should have been present at ship time. For example, MSBuild has no support for an expression language, Build containers, or enum properties.

Therefore, I have concluded that developing MSBuild tasks is a waste of our development time and resources. Although I believe that MSBuild may be here to stay, it has a lot of maturing to do before it can replace what NAnt already has out of the box. If I can develop a NAnt task in 1/5th the time of a MSBuild task then I am obligated to use the more effective and cost efficient tool.

Please Microsoft, do your homework before you release another developer tool that directly competes with a well embraced community tool.

Read more
18 February 2006

SVN + UTF16 + SQL Management Studio = No SVN Merge

The problem:

By default SQL Management studio saves all files as "Unicode" which is Microsoft speak for UTF-16. This causes problems with SVN when you want to leverage merges and diffs. SVN treats UTF-16 as a binary file and therefore can't do textual diffs leaving no way for you to deal with conflicts other than to revert and manually integrate your changes from another saved copy.

The Solution:

Open a sql file in the Management Studio and then select "Save As" from the File menu. Then select the drop down beside the "Save" button and select Save with encoding. From the encoding drop down select Western Europe which is Microsoft speak for Latin1 (ISO8859-1) or select UTF-8. Once you have saved one file, all new files will be saved with this encoding. Old files will need to be converted using another editor such as Notepad2.

You might need to svn remove and then svn add the file in order to change the associated mime type. This will need to be tested though.

Read more
31 January 2006

"Access is Denied" in SVN: An unadvised work-around

Problem:

SVN update or SVN checkout results in "access is denied" messages

Solution:

Temporarily disable Norton Anti-Virus in the system tray. NAV is locking the .svn files and is slow at releasing the lock which causes SVN to abort because it can't access the file it just created.

Read more
06 December 2005

MSBuild + MSBuild Community = Lots more MSBuild tasks

MSBuild now has a zip task addon where you can compress and uncompress files.

Wow.

-- Java Ant team

Read more
01 December 2005

Regular Expression Visualizers for VS 2005

Roy Osherove, author of the Regulator, has released Regular Expression Visualizers for VS 2005. This is a great tool for writing, testing and debuging regular expressions within VS 2005.

Read more
31 October 2005

Oracle 10g Express Edition

Oracle is getting ready to compete with SQL Server Express with Oracle Database 10g Express Edition. I wonder, what kind of resources will this db require?

Read more
18 October 2005

.NET ssh client

SharpSSH is a SSH library written in C#. This is good news since the deployment process to Netstorage requires both FTP and SSH access. This will allow our connection via SSH to be controlled in an NAnt task

Read more
09 September 2005

Factors in Google Page Ranking

Read more
20 August 2005

CSS Property Index

Here is an exhaustive index of css properties

Read more
28 July 2005

Adobe HQ

Adobe Photoshop has a very stylish office headquarters

Read more
21 July 2005

EventLog XP

Are you tired of the small window in the eventlog viewer? Try using EventLog XP.

Read more
21 July 2005

TortoiseSVN: converting from _svn to .svn

After you have migrated all your VS 2003 solutions away from web applications, you will be able to use the standard svn tools. Unfortunately, once you install the standard TortoiseSVN, your old projects will be unusable until they are re-checked out.

Don't worry! There is a better way.

Below are two scripts that allow you to quickly and easily convert from a project using _svn (hacked TortoiseSVN) to .svn (standard TortoiseSVN).

@rem dotNetSVN.cmd 
@echo off

rem convert .svn folders to _svn

setlocal
for /f "delims=" %%a in ('dir /AH /b /s .svn*') do attrib -h "%%a"
for /f "delims=" %%a in ('dir /AD /b /s .svn*') do move "%%a" "%%a\..\_svn"
for /f "delims=" %%a in ('dir /AD /b /s _svn*') do attrib +h "%%a"
endlocal
@rem normalSVN.cmd 
@echo off

rem convert _svn folders to .svn

setlocal
for /f "delims=" %%a in ('dir /AH /b /s _svn*') do attrib -h "%%a"
for /f "delims=" %%a in ('dir /AD /b /s _svn*') do move "%%a" "%%a\..\.svn"
for /f "delims=" %%a in ('dir /AD /b /s .svn*') do attrib +h "%%a"
endlocal
Read more
19 July 2005

ASP.NET Applications without Web Projects

Fritz Onion tells you all you need to know to create a ASP.NET Application without Web Projects. He even talks about how to convert an existing web project to a c# library. This will benefit us because:

  1. Svn will work out of the box (no _svn hack required). Any SVN tool will work
  2. Project load time will be faster, especially if you are using Resharper
  3. You can check-out the application to any directory and load the solution without IIS configuration<
  4. You can recompile the solution without IIS configuration
  5. You don't have to configure IIS to use the solution
  6. You don't have to configure IIS to use the solution

Here is the article:

ASP.NET Applications without Web Projects

Reference prepared by Fritz Onion

The Web Project wizard in Visual Studio .NET is convenient for creating quick ASP.NET applications on your local machine, but in an effort to simplify your life, it also makes many decisions for you that are difficult to change if you need more flexibility. My biggest pet peeve with Web Projects is that you cannot even open a .sln file if the virtual directory mapping in IIS is not set up correctly. I also dislike the way it places .sln and .csproj | .vbproj files in a separate location from the actual source files (I understand that this is necessary to allow application creation directly on a server, but I never deploy that way).

As a result, most of my web projects are created as standard class library projects. Unfortunately this means that you don't get the nice Web component wizards (like WebForms and UserControls). However, with a little tweaking, you can have it all. I have prepared this document describing how to enable these wizards in class library projects (thanks to Dan Sullivan for pointing out how to do this), as well as how to convert existing Web Projects to class library projects and still keep the nice integrated debugging.

To enable Web wizards in a class library project:

In a directory called C:\Program Files\Microsoft Visual Studio .NET 2003\VC#\CSharpProjectItems\LocalProjectItems is a file callled localprojectitems.vsdir. Likewise in a directory C:\Program Files\Microsoft Visual Studio .NET 2003\VC#\CSharpProjectItems\WebProjectItems is a file called webprojectitems.vsdir. If open the second file with notepad you can figure out the lines to copy to the first file to be able to add the usual files you need to create an aspx page or web service to a class lib project.

Once you have copied these thing open VS, open a class lib and go to add new item and you will see these additional file types available.

To set the output of a class library project to go to a /bin directory of your choosing:

  1. Right-click on the project and select properties
  2. Set Configuration to 'All Configurations' to affect both debug and release builds
  3. Under configuration properties/build set the OutputPath to the /bin directory

To convert an existing web project into a class library project:

  1. Open the .sln file in a text editor, and change the reference to the project from an http://... reference to a simple reference to the .csproj (or .vbproj) filename. For example:
change:
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebApplication133", "http://localhost/WebApplication133/WebApplication133.csproj", "{39CB37A5-F735-4684-B5DA-DD355B683090}"

to:
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebApplication133", "WebApplication133.csproj", "{39CB37A5-F735-4684-B5DA-DD355B683090}"
  1. If there is one, delete the .webinfo file
  2. Open the .csproj (or .vbproj) file and change the ProjectType attribute from "Web" to "Local"

To set up a class library project to run a browser when you debug it:

  1. Right-click on the project in the solution explorer and select properties
  2. Under Configuration Properties/Debugging, change Debug Mode from 'Project' to 'URL'
  3. Hit Apply
  4. In the Start URL field, enter the complete url to the page you want to hit to debug, like: http://localhost/testproj/webform1.aspx
Read more
06 July 2005

User Interface research - stop clicking

May this link be the last link you click http://www.dontclick.it/

Read more
29 June 2005

Milestone release and code commits

The Whidbey project has just entered the first of four stages as they near completion of the RTM milestone. From the Whidbey release team's blog:

Stage 1: DevDiv Tell Mode:

  • At the division level we will run a daily DevDiv shiproom.
  • Tell mode is going to be 4-6 weeks.
  • The focus of tell mode will be in establishing the triage/bug bar, understanding team's bug trajectory, and moving teams towards a single branch.
  • During shiproom we will be using the triage/bug bar as a guide, which we will continue to refine as we progress through Tell/Ask mode.
  • Some of the data we will discuss at DevDiv shiproom:
    • Examples of approved/rejected (including tough calls and/or border line bugs) bugs. The focus here centers on the customer scenario and the fix in order to help level set the triage bar for teams across the division.
    • Have there been any major regressions from previous milestone or from Everett?
  • Team's trajectory :
    • RTM Active bugs
    • Bug fix rate (how many bugs were approved for checkin today)
    • Incoming/resolved bug rates
    • Weekly step down goals
    • Bugs resolved but not yet closed

Stage 2: DevDiv Ask Mode:

  • DevDiv shiproom will continue to meet daily.
  • During Ask mode we will further define and apply an even higher bar for the bug fixes we take into Whidbey RTM. All checkins to Whidbey RTM must be approved by DevDiv shiproom.

Stage 3: DevDiv Endgame:

  • This is where the bar is raised to recall class bugs only.

Stage 4: DevDiv Escrow:

  • This is a period of bake time, there should not be any Whidbey work or QA planned during this period of time.
  • To be exact, "we are done with the product" and QA has signed off on the release
Read more
05 May 2005

SVN: How do I change the log message for a revision after it’s been committed?

From the SVN FAQ:

Log messages are kept in the repository as properties attached to each revision. By default, the log message property (svn:log) cannot be edited once it is committed. That is because changes to revision properties (of which svn:log is one) cause the property's previous value to be permanently discarded, and Subversion tries to prevent you from doing this accidentally. However, there are a couple of ways to get Subversion to change a revision property.


The first way is for the repository administrator to enable revision property modifications. This is done by creating a hook called "pre-revprop-change" (see this section in the Subversion book for more details about how to do this). The "pre-revprop-change" hook has access to the old log message before it is changed, so it can preserve it in some way (for example, by sending an email). Once revision property modifications are enabled, you can change a revision's log message by passing the --revprop switch to svn propedit or svn propset, like either one of these:

#!/bin/sh
svn propedit -r N --revprop svn:log URL
svn propset -r N --revprop svn:log "new log message" URL

where N is the revision number whose log message you wish to change, and URL is the location of the repository. If you run this command from within a working copy, you can leave off the URL.

Read more
03 May 2005

Google Images & Picasa

Google openly admits that it reads metadata information from image files to help contextualize the image for better searching. However, it is not known what fields and what formats google actually supports. The general feeling is that it supports many of the EXIF and IPTC headers. Again, it is unclear which headers it uses and what kind of weighting it applies to these values. One thing that we do know is that images manipulated with picassa and assigned a caption rank well in google images.

As it turns out, Picasa does not use either the Exif or IPTC formats for its keywords and caption fields. Picasa uses the Photoshop 3.0 8BIM annotations. The first segment after the jpeg magic bytes is called the jfif header. The header can contain many segments including exif and iptc data. Photoshop, since version 3.0 also adds a segment (usually the first segment) to add extra annotations such as keywords and captions.

Here are some good resources in understanding the jpeg headers can be found here:

Read more
01 April 2005

The [real] reason behind the slip of VS 2005 and Yukon

The code for [Visual Studio 2005 and SQL Server 2005] has been ready for manufacturing since late October of 2004, we've just been sitting on it waiting for the Unix teams to catch up

--Anonymous Microsoft Official

Read: Microsoft to Release Visual Studio 2005 for Unix & Linux

Read more
30 March 2005

CSS Maze

Sure, you could always write a maze game for the web by brute forcing javascript or server side post-backs, but can you do it with only CSS?

Read more
14 February 2005

Alternative Job Titles

Check out these cool job titles from my friends office...

  • TangibleStuffInducerJob, for hardware
  • HumanCannonballJob, for coding
  • WebAppsJob, for web coding
  • GuiVigilanteJob, for complaining about bad coding
  • EvilMinionJob, for coding things that complain about bad coding
  • EvilDeathRayJob, for isolating examples of bad coding
  • EvilVisionaryJob, for defining exactly what is bad coding
Read more
08 February 2005

Fiddler for HTTP Debugging

One of the Program Mangagers of the IE team has written a very handy tool called Fiddler.

One of the significant differences between Fiddler and TracePlus WebDetective is that it does not require you to respawn your browser in order to investigate http traffic. Once the tool is open all subsequent activity in IE will automatically be captured. To trace the activity of other non-IE clients/browsers you will need to configure the proxy settings to localhost:8888.

You can also attach scripts to be invoked during a request or response events. More details about the event model can be found on this recent MSDN article.

Oh yea, and the other cool thing about this tool - its written in c#!

Read more
sl