A Developer WeBLOG RSS 2.0

Last week I decided to give Open Office a try. Open Office is a free and open source office productivity suite, sponsored by Sun Microsystem. Open office is one of the most popular alternative to Microsoft Office. You can find the following applications in the suite:

  • Open Office Writer: Document processing software, substitute to Microsoft Word.
  • Open Office Calc: Spreadsheet software, substitute to Microsoft Excel.
  • Open Office Impress: Multimedia presentation software, substitute to Microsoft PowerPoint.
  • Open Office Draw: Drawing utility software.
  • Open Office Base: Database software, substitute to Microsoft Access.
  • Open Office Math

I have not tried all the software in the suite, but I have used the Open Office Writer and Open Office Calc extensively. Overall my experience with Open Office has been great. My favorite feature of the Open Office is the “Export as PDF”, which is something that Microsoft Office does not offer. With a click of a button you can export your word document or spreadsheet document as a PDF document. Very handy! Having to be a satisfied user, I think Open Office has a very good potential in beating Microsoft Office. It is a solid office productivity suite, and it is free. 

There is just one concern that I found with Open Office. Have a look on what happen when I try saving a Microsoft Word document.

ss11

Does this mean Open Office is not able to create a compatible Microsoft Office document? or Is it just trying to push its format to the user?

So far I found that Open Office compatibility to Microsoft Office to be pretty good. It is able to open any types of Microsoft Office documents (2003 or 2007) with no problem whatsoever. Although I can see that in one or two document, it’s not able to display the document’s formatting correctly. For example, I found that in one document, there is a table that looks bigger in Open Office, that it exceeds the page margin. Other than this one issue, everything works perfectly fine.

So why is it giving us a compatibility warning? Why is it even asking the user to save the document in a different format? Was it really necessary to create a new format that is not compatible with the existing one? I think this will hurt Open Office a lot, as it might hinder people who want to use Open Office as a substitute of Microsoft Office. Those people who want to migrate to Open Office need a certainty that they can still work on any Microsoft Office document after migration. They want to be able to create document that is recognizable and natively supported by Microsoft Office.

I feel that this is a similar case as to Linux and Windows. Many people are not jumping ship to Linux because most of the software out there are incompatible with Linux. They are built for windows, and you can not install/use them natively in Linux. You have to use another tool/software to run them in Linux. Even so there is no guarantee that it will work. This reminds me the history of Microsoft Excel that I read from Joel Spolsky blog. Joel Spolsky stated that, the day that Excel gains significant market share from Lotus spreadsheet, was the day it was able to write Lotus spreadsheet transparently. Thus offering full compatibility and making it easier for people to switch to Excel. Quoting his blog post:

And this reminded me of Excel's tipping point, which happened around the time of Excel 4.0. And the biggest reason was that Excel 4.0 was the first version of Excel that could write Lotus spreadsheets transparently.  

Yep, you heard me. Write. Not read. It turns out that what was stopping people from switching to Excel was that everybody else they worked with was still using Lotus 123. They didn't want a product that would create spreadsheets that nobody else could read: a classic Chicken and Egg problem. When you're the lone Excel fan in a company where everyone else is using 123, even if you love Excel, you can't switch until you can participate in the 123 ecology.

It is very important for any new product, that entering a well established market, to provide full compatibility to the dominant product. Compatibility is an important feature that should not be neglected. By offering compatibility, you are indirectly increasing your target market to be the same as the dominant product. Or in other words, you are making every user of the dominant product to be your potential user. Compatibility allows user to migrate to the new software seamlessly, which is something that is very important. I know it is unjust to use a free open source software as an example, but its such a shame to see a solid software like Open Office has to suffer from this issue.

RWendi

Saturday, February 28, 2009 11:17:14 AM UTC |  Comments [0]
Software Development

Australian ALT .NET Virtual Meeting

When
Fortnightly, Monday @ 9:30pm Eastern

Where
Cyberspace (Live Meeting)

Web
http://tinyurl.com/virtualozaltnet

RWendi

Wednesday, February 25, 2009 9:29:15 AM UTC |  Comments [0]
ALT .NET

The link contains some information on the upcoming Visual Studio 2010. Some of the notable new features in it:

  • New user interface built upon WPF technology of .NET framework 4.0
  • Floating documents for multiple monitor support.
  • New document outlining looks, now uses triangular shape.

A New Look For Visual Studio 2010: [Link]

RWendi

Tuesday, February 24, 2009 10:46:27 PM UTC |  Comments [0]
Link | VS2010

Very good representation of SOLID principles in motivational pictures. I hope they come up with better and higher resolution pictures. Im so gonna grab them. SOLID Development Principles – In Motivational Pictures

RWendi

Friday, February 20, 2009 10:00:58 PM UTC |  Comments [0]
Link | Programming

Many people say that building your own computer will give you the best bang of your buck. Is that really true? In this blog post I will be comparing a couple of intel based computer builds in comparison with Dell Australia’s current lineup. All the computer parts that I choose are based on my personal preferences and I will be using IJK online as a store choice. Please note that I’m not in any way affiliated with IJK or Dell.

Core i7 PC

 

IJK

Dell
Studio XPS

21.5” Widescreen LCD Monitor

$235

 

Computer Case with 420Watts PSU

$94

 

X58 Motherboard

$355

 

Intel Core i7 920

$475

 

3Gb DDR3 PC8500 (1066Mhz)

$94

 

500 GB HDD

$97

 

512MB ATI Radeon HD4850

$239

 

DVD with dual layer capabilities

$32

 

Internal Media Card Reader

$45

 

Generic keyboard and mouse

$22

 

Windows Vista Home Premium 64 bit

$175

 

Total Cost

$1,863

$1,999

 

Quad Core PC

 

IJK

Dell
XPS 430

21.5” Widescreen LCD Monitor

$235

 

Computer Case with 420Watts PSU

$94

 

X48 Motherboard

$290

 

Intel Core2Quad Q8200

$282

 

3Gb DDR3 PC8500 (1066Mhz)

$94

 

320 GB HDD

$79

 

512MB ATI Radeon HD4670

$129

 

DVD with dual layer capabilities

$32

 

Internal Media Card Reader

$45

 

Generic keyboard and mouse

$22

 

Windows Vista Home Premium 64 bit

$175

 

Total Cost

$1,477

$1,699

 

Dual Core PC

 

IJK

Dell
Studio Desktop

23” Widescreen LCD Monitor

$350

 

Computer Case with 420Watts PSU

$94

 

G45 Motherboard

$147

 

Intel Core2Duo E7400

$199

 

3Gb DDR2 PC6400 (800Mhz)

$90

 

320 GB HDD

$79

 

256MB ATI Radeon HD3450

$72

 

DVD with dual layer capabilities

$32

 

19 in 1 Media card reader with bluetooth

$45

 

Generic keyboard and mouse

$22

 

Windows Vista Home Premium 64 bit

$175

 

Total Cost

$1,305

$1,399

 

As you can see that building your computer is indeed cheaper, but the price difference is not really that much. The extra price that you pay for the Dell machine is for better warranty policy and customer service. With Dell offering free upgrades every week, I think that the price difference has become negligible. For example, sometimes you can get a free upgrade to 23” LCD monitor. The price difference between a 21.5” monitor and a 23” monitor is about $125, which is the difference between the Dell Studio XPS with the Core i7 build.

One problem with building a system is that, there is a chance of incompatibilities between components. Does this memory module work for this motherboard? Does this PSU has enough power for the whole system? When you are getting a premade system you do not have to worry with those kind of questions. Getting a premade system means that it is guaranteed to work. You also get the convenience of plugging a couple of cables and your system is ready to use. No hassle of assembling your system and no skin cuts too.

Building your own system has its benefit too. You can mix and match any components and choose components of best quality. Building your own system means you will get better quality components. I’m not saying that Dell has a subpar quality, but most likely that the components you get from dell would be generic value oriented components (probably not the case for XPS pcs). For example, in Dell machine, You will not get RAMs with heat spreader, You will not get high speed HDDs (not on default configuration), and most likely you will not get good efficient PSU. With better hardware you can push your system further by overclocking it, and that is a big plus for building your PC. You can still overclock a Dell (on certain models), but doing that will probably void your warranty.

I think when it comes to choosing whether to get a premade system or build your own, you should not really be worry about cost, as both option will virtually cost the same. It all comes down to your personal preference. The convenience of a premade system or the better quality of a ”build your own” system.

RWendi

Friday, February 20, 2009 11:08:06 AM UTC |  Comments [2]
Computer Hardware | General

Recently there was quite a bit of commotion in regards to code quality in the programming community. The commotion is between two of the most influential people in the programming community, Robert C Martin and Joel Spolsky. Just a brief recap of what happened.

It all started with a podcast by Scott Hanselman talking about SOLID principle with Robert C Martin (aka Uncle Bob). Founders of stackoverflow.com, Joel Spolsky and Jeff Atwood, heard the podcast and made a ad-homimem comment in stackoverflow podcast #38, stating that “Quality just does not matter that much”. Hearing this statement from a high profile developer with years of experience, made Robert Martin back flip. He wrote a blog to counter Atwood’s argument, and expresses his concerns. Joel Spolsky and Jeff Atwood decided to invite Robert Martin as a guest speaker in stackoverflow podcast #41. Before the podcast, Robert Martin posted another blog that acts as an open letter to Jeff and Joel that addresses all the issues he has with their comments.

After listening to all the podcasts and reading all the blog posts, it seems like to me that there’s actually a misunderstanding between the two party. When Jeff said “Quality just does not matter that much”, he did not mean it literally. What he meant was “Quality just does not matter that much when inexperience people try to apply programming principle religiously, that it slows down their productivity and produces no result.”. Joel and Jeff did not say that clearly enough in the podcast, that it sounded like a rather offensive comment towards Robert Martin.

I have to say that I’m 100% agree with Jeff statement. Inexperienced developer that overwhelmed by theories tend to forget that in the end the most important thing is the result. I remember when I first being exposed with design principles, it felt awesome to have learnt and understood something technical. I was so excited that when it came to solving a problem, I became more focused on how to apply the principle rather than actually solving the problem. Focusing more on applying a programming principle is a big problem, because you’re wasting time on something that does not necessarily solve the problem. In the end you did not get anything done and your work shows no result. It is very important to fully understand what programming problem does a principle solve, before we start using it.

So when is it appropriate to follow programming principles? After fully understanding the principle, we should always try to follow those principle whenever possible. Code that conform programming principles will be a lot easier to work with. For example, which one do you prefer, working on a class that is 20k lines long, or working with multiple classes with 2k lines each. I bet you prefer the multiple classes scenario. Even when time is a constraint, we can always try our best to follow good design principles. I think of it as an early investment. It may take a longer time to code a solution at first, but it will make it a lot easier to work with in the future.

Having said that, there are times that may not be appropriate to apply your programming principles. I find it very often that I have to refactor my code when applying programming principles to an old code base. Refactoring is always a risky thing to do, no matter how good your test code coverage is. Thus it is very important to asses how much risk involves to apply the principle. After we identify the magnitude of the risk, we need to asses how important is the build in which we need to patch. If it is a critical build, you might want to save your principle to be applied later on. For example, if you are making a build for deal that’s worth $500k+, introducing risk by refactoring a big chunk of your code, just to apply a programming principle, would be simply stupid. Apply your programming principles wherever and whenever it makes sense.

In this blog post, I’m taking a stand to neither sides. I agree completely with Uncle Bob in regards to code quality. Good programmer must have the craftsmanship passion to write the best code possible all the time. On the other hand, Jeff’s argument is also valid, because there are just times that might not be appropriate to apply programming principles.

Resources on the Uncle Bob vs Joel Spolsky:

  • Scott Hanselman podcast with Uncle Bob talking about SOLID principle [link]
  • Stackoverflow.com podcast #38 [link]
  • Uncle Bob open letter to Joel Spolsky & Jeff Atwood [link]
  • Stackoverflow.com podcast #41 [link]
  • Jeff Atwood’s “Ferengi Programmer” blog post [link]
  • Dhananjay Neneto reaction to Jeff’s “Ferengi Programmer” post [link]
  • InfoQ summary on the whole Uncle Bob vs Joel Spolsky [link]

RWendi

Wednesday, February 18, 2009 7:51:29 PM UTC |  Comments [2]
Programming
Saturday, February 14, 2009 3:29:35 AM UTC |  Comments [0]
Programming

Uncle Bob keynoting at Oredev in Malmo, Sweden.

Keynote: The Renaissance of Craftsmanship

What does it mean to be a professional software developer?  What rules do we follow?  What attitudes do we hold?  And how can we maintain our professionalism in the face of schedule pressure?  In this talk Robert C. Martin outlines the practices used by software craftsmen to maintain their professional ethics.  He resolves the dilemma of speed vs. quality, and mess vs schedule.  He provides a set of principles and simple Dos and Don’ts for teams who want to be counted as professional craftsmen. [Original Link]

Further resources: Post-event interview by .NetRocks Team. [link]

RWendi

Friday, February 13, 2009 12:02:48 AM UTC |  Comments [0]
Link | Programming

The past few weeks I’ve been assigned a background task to fix memory leaks issue in our Document Comparison engine. Our document comparison engine was written in Native C++ and ported to Microsoft Visual C++ (not sure if there’s any differences between the two). As a C++ application, our document comparison engine is not managed by .NET framework. It does not have the luxury of having a Garbage Collector to automatically cleaned up all the memory pointers you have created/allocated. In a non-managed code, these memory pointers need to be cleaned manually, or otherwise you’ll be faced by the classic C++ issue: Memory Leaks.

One of the tricky bit in solving memory leaks issue in C++ application is to detect the memory leaks. That is the very first problem that must be solved. I encountered many articles to detect memory leaks, and most of them don’t work. The first article that I tried was this. It was given by my Team Leader, so I assume that this one most probably will work. After few days, I got the constructor overriding of the delete operator working, but seems to stuck in getting the overriding of the new operator to work. I decided to ditch that article to find another one. After trying a couple of other articles, I found that C++ actually has a built in way to debug memory leaks issue.

This makes memory leak detection to be an easy thing to do. All you need to do is to call _CrtDumpMemoryLeaks() function of the crtdbg class. This function will output the list of memory allocations that was created by the application. Cool! But that solved only half of the problem, because now you need to know which object that has not been disposed, in which file and which line was the object created. To solve this problem, we need to override the new operator of DEBUG_NEW and then redefine the DEBUG_NEW. To override the new operator of the debug new, add the following code to your header file:

   1: #ifdef _DEBUG
   2: #include <crtdbg.h>
   3: #define DEBUG_NEW new (_NORMAL_BLOCK, __FILE__, __LINE__)
   4: #else
   5: #define DEBUG_NEW new
   6: #endif

Then you need to add the following line in your cpp file to redefine your DEBUG_NEW:

   1: #ifdef _DEBUG
   2: #define new DEBUG_NEW
   3: #endif

After you add the above two codes, when you call the _CrtDumpMemoryLeaks() function again, it will include the filename and the line in which the code was created. Awesome! Here is an example on how it looks like:

memoryleakdumpexample

Tips: If you’re using Microsoft Visual C++, you can place the codes in your stdafx.h and stdafx.cpp files. That way you do not need to do it in every single file.

RWendi

Tuesday, February 10, 2009 1:36:22 AM UTC |  Comments [3]
c++

Very good article on how to setup a web farm using network load balancing service in Windows Server 2003. http://www.west-wind.com/presentations/loadbalancing/networkloadbalancingwindows2003.asp

RWendi

Sunday, February 08, 2009 11:48:38 PM UTC |  Comments [0]
Link | Network | WinServer 2003

In my work place, we currently do not write unit tests. I think this is one of the thing that we are very lacking of. The importance of unit test seems to be neglected by the management people. In fact, I think most business people don’t care so much about unit testing. Even my development manager, who comes from a technical background, doesn’t think that writing test is all that important. I remember talking about unit test with him and he said that as long as it doesn’t add too much of the total development time, by all means do it. I guess its understandable why management people seem to neglect unit test, its because they have the pressure to release software on time.

But, there is one thing that they forget or unaware of, which is Unit test improves code quality. I would see it almost similar to having a quality assurance (testers) in your team, only cheaper. With quality assurance, you know your product is ready to ship with good quality if it has been approved by the quality assurance people. Its sort of the same with unit test, developers will have the confident that they have written a good quality code if it passes all the unit tests. It can not get any simpler than that. Unit tests give the ability for developers to jump in and make changes without having to worry of breaking anything.

Sure you can throw in the argument that writing unit test will add more time to the development, but note this, as your unit tests grow your code base will be easier to work with. Code base that’s easier to work with, will speeds up development time. Thus in the end, all the time invested to write unit tests initially, will eventually pay off. Depending on how good and comprehensive the unit test library, cases like bugs regression can be greatly minimized, which means less time will be wasted on reworks. Moreover, unit tests can be automated which saves a big amount of your developers time.

Another argument that’s usually brought up by people would be unit test is hard to maintain. This is a very big misconception of unit tests. The fact is: Maintaining unit tests is not any harder than maintaining your code base. Similar to software design, unit test should be written in a way that it is persistent to change. Badly design test needs to be changed whenever there is a change in your code base, on the other hand well designed test is more persistent to code base change.

I’m going to quote Uncle Bob’s statement that says:

“If you design your tests such that 10% of them fail due to a single point change, then you need a new career. Test design, like any other part of software design, is about decoupling.”

Its a very good and true statement, except for the needing a new career part (that’s a little bit too harsh). I think what uncle bob is trying to say here is that well designed unit test is hard to break, and in essence designing test is similar to software design. Unit test is not all about writing them, its about designing them too.

I hope that one day people would realize that unit test is not a waste of time. Its a very important aspect in software development, which will improve code quality and development time. It may not show the result right away, but in time it will.

RWendi

Thursday, February 05, 2009 5:02:00 PM UTC |  Comments [1]
Agile | TDD | Unit Test

As a .NET developer, I spend 80% of my time looking at codes in Visual Studio. I find that with Visual Studio’s default theme is too bright and restraints my eyes easily after prolonged used. Thus, I opted to find a custom theme that has soft contrast that easy to look at. You may think that this is not a very important issue, but the longer your eyes to get tired, the more time you get to work productively. Scott Hanselman has a good list of Visual Studio theme in his site, but unfortunately none of them works for me. Most of the Visual Studio themes in the list has dark background (which is a good thing), but I find that the contrast between the text with the background is too vibrant. Those themes are still a lot better than Visual Studio default theme, but I’m looking more on a softer theme, softer dark background with a not too bright text color.

I went on googling around to try to find a better Visual Studio Theme, then I found this Inkpot theme. I find that this theme has a very good color selection. It has grayish black background, instead of going all black. The font color has matte-like looks, and definitely not bright. Its not a perfect theme, but I think its the best to my preference.

Here is how to change your Visual Studio Selected Settings:

  • Download the InkPot theme and place it anywhere in your hard-drive.
  • On the Tools menu, choose Import and Export Settings.
  • On Welcome to the Import and Export Settings Wizard page, click Import selected environment settings and then click Next.
  • On the Save Current Settings page, select Yes, save my current settings, and then click Next.
  • Browse to the location of your Inkpot theme, select it, and click next.
  • Expand the All Settings, Options, Environment Category, and select the Fonts and Colors settings.
  • Click Finish.

If you’re working with Visual Studio on regular basis, I highly recommend you to change your theme. Its very important to have a less bright, dark background theme as it goes easy on your eyes. Try out the Inkpot theme, it works great for me. You can read more about how to modify Visual Studio Theme Settings here.

NOTE: this theme is for Visual Studio 2008. Credit to the original poster of the Inkpot theme (sorry I’ve lost the link to your website).

RWendi

Tuesday, February 03, 2009 5:00:00 AM UTC |  Comments [0]
VS2008

I found wikipedia database schema, which is very darn cool. Wikipedia Database Schema.

RWendi

Monday, February 02, 2009 8:20:00 AM UTC |  Comments [0]
Database | Link

As I posted in this blog entry that I will be trialing three offline blogging tools, which are Windows Live Writer, Zoundry Raven, and wBloggar. After couple of days of testing, I’m most impress with Windows Live Writer and Zoundry Raven. They both are solid and very easy to use offline blogging tools. Windows Live Writer gives a richer user experience, on the other hand Zoundry Raven gives a better manageability for those who have multiple blogs. Since I only have one blog, I decided that Windows Live Writer is more suitable for me. So here is a review of Windows Live Writer.

Installation

The installation uses web installation and offers you if you want to install other Windows live components, such as Windows Live Messenger, Photo Gallery, Movie Maker, etc. I chose to install just the writer.

Setup

The setup wizard starts by asking you what blog services you use. It has option to use Windows Live Space, SharePoint Blog, Other Blog Services, and if you don’t have a blog, it has an option to create a blog using Windows Live Space. I chose the other blog services option, and the next step that I had to do is to provide the details of my blog such as: the URL of my blog, Username, and Password. After providing my Blog details, It then try to detect all the settings that you have in your blog and apply it automatically. At the end of the detection phase, it asks for your permission to make a dummy post to detect your theme settings. After it detects your theme settings, you’re set to use Live Writer.

Windows Live Writer automaticaly detects your blog settings

First Impression

The software looks really good. It has that Microsoft Office feeling to it, without the ribbon control of course. The software works sort of similar to a text editor software. Once you open the Live Writer, it will automatically create a new blog entry, you can start writing your blog right away. It has the standard text editor with toolbars that allows you to format the style of the text, and insert other elements such as: hyperlinks, picture, photo album, table, map, tags, and video. The text editor comes with 3 views: normal view, source view, and web preview.

Windows Live Writer allows you to save a local copy of your blog, or post it online as a draft (can be done multiple times, it will just update your existing draft post). It keeps track of all the drafts you saved locally, thus you won’t be losing any post. You can open any post that saved locally or ones in your web. There is a delete menu which deletes the local copy only, to delete both local and web copy, you have to use the open dialog and delete it from the dialog. I think this is very impractical and wrong. Think about it, to delete your post you have to go through the open dialog. To me that’s a UI and Workflow FAIL.

Windows Live Writer has Microsoft Office feeling to it, and it works sort of similar to a text editor software.

Features

As I mention before, Windows Live Writer features element embedding. I decided to give them a try. I thought those would just insert the elements, but i was wrong, it gives you more. For example, when you insert a picture it gives you the following options:

  • Layout Options: text wrapping, picture margins, and picture borders (Drop shadow, photo paper, rounded corner, etc).
  • Picture edit options: resize, rotate, crop, contrast, tilt, and watermark.
  • Picture effects: black and white, sepia, gaussian blur, adjust temperature, emboss, sharpen, and color pop.     

Other than inserting basic elements (links, pictures, and tables), it also has photo album, map, and video insert feature. Photo album basically allows you to insert multiple photos to your blog as a Windows Live album. Wait, did I say Windows Live Album? Yes I did, and this means you have to have a Windows Live ID (you can just use your hotmail account). When you insert a photo album, it will create a picture link to your windows live album, which can be customized. Inserting a map will also use Windows Live services.

Windows Live Writer comes with a built in Spell Checker. It works the same way as one you found in Microsoft Office. If you make a wrong spelling, it will red underlined the word. When you right click on the word it will give you suggestion of the possible right words. It also comes with a word count. Not sure how useful it is, but hey, its a plus.

One of the coolest thing with Windows Live Writer is that its extensible, that is you can add plug-ins to the software. Clicking the “Add a plug-in…” button will open up a page in your browser that lists all the available plug-ins for the Writer. Some of the noteworthy plug-ins are: Flickr4writer, Picasa Image, FacebookPhotos, Twitter Notify, and Insert Code Snippet plug-in. I instantly downloaded the Insert Code Snippet plug-in and love it. It works like a charm. I’m going to use this from now on, instead of screen capture images.

Conclusion

I found that blog writing is a lot easier and much more fun with Windows Live Writer. I didn’t find any major problems or defects when I used it. I highly recommend this offline blogging tool to anyone who blogs.

RWendi

Sunday, February 01, 2009 12:19:00 PM UTC |  Comments [0]
Blogging
All Content © 2012, RWendi