Photo credits: Matt Steen

To see more recent blog posts please visit http://www.sanative.net/blog


Why Aren't More CF Developers Using OO Methodologies and Frameworks?

I have just finished reading Bob Silverberg's blog posts on Transfer ORM. It's a five part (thus far) series on how Bob has been using Transfer over the last year. Bob is a great writer and has done an excellent job of describing what he has been doing, which left me wondering why "I still don't get it".

My overall impression is that Bob's posts were not designed as an introduction to using Transfer, but more of a way to validate how he has been using it. So, if you are wanting to learn how to use Transfer its probably not the post for you. If you've been using Transfer and want to hear someone else's experience then it's probably going to be an excellent read. As someone who has a basic knowledge of Transfer (and ORMs in general) and how it works,but being fairly new to OO development in general, I found it to be significantly enough over my head that it was not applicable to my current needs. That being said, I wanted to express my opinions on why I believe the vast majority of CF developers are still writing procedural code and not using frameworks.

To be clear, I am relatively new to OO development. I started writing "OO" CFML about a year ago and have a fair feel for what I am doing. I have written a few CFML applications using OO methodologies. Unfortunately in the last year I've written very little CFML so I've not been able to practice this as much as I would like. I learned the basic principles of OO CFML development via CFOOP. Nicholas Tunney, Phil Nacelli and Chris Turner did an excellent job of creating tutorials for procedural coders that made sense and made you feel like you actually grasped the topic. However, the the site hasn't been updated in ages.

In reality, I have learned far more about OO development from writing ActionScript applications (Flex and Flash) and the Flex community than I ever have from the ColdFusion community. This is definitely because Flex will force you into doing OO development, but there's also a larger community of developers who are proficient with OO methodologies,and to a certain degree, are better at explaining these concepts to the procedural coder.

 Here's the primary problem I have found with the blog posts and tutorials on frameworks and OO CFML development methodologies to date: There's an assumption that the reader has knowledge of many of the concepts and principles being discussed. Given that the community is ColdFusion, I feel this is often far from the truth. Talking with fellow CF developers who are not utilizing frameworks, OO principles and/or additional methodologies such as ORMs, dependency injectors and the like, I find that they have been discouraged by these facts.

While folks such as Brian Rinaldi, Dan Wilson, Matt Quackenbush and (many) others have been extremely generous in giving their time in writing articles and tutorials on advanced CF topics designed to help others learn these methods, I am certain that the intended audience has has been left with the impression that this is far more difficult than it really is. In the end, it ends up alienating the intended audience more and more because they are left to believe that they may just never get it. It is only the stubborn few who truly want to force themselves to learn these concepts and methods that actually do make it to the point of putting it into practice on a daily basis.

To be clear, OO is not easy. I realize this. It does require more effort than procedural code and is significantly more complex. However, I feel that often times terminology is the primary stumbling block. By the way, Doug Boude has a great resource for learning and memorizing OO terminology.

I would like to hear from developers who are not writing OO code. What do you think are the primary reasons for this?

ColdFusion Debugger in Eclipse

I have been working for a bit on getting ColdFusion Debugger running for CF 8. It's really nice, beats the heck out of cfdump. Being able to set a breakpoint is nice, and works more fluidly with the way I debug my Flex apps.

The biggest obstacle I had in setting this up was getting the debugger to actually show me anything. Since I am also learning ANT, and work with subversion, I have my working copy of code outside the webroot and am using an ANT script to build the project to the directory in the web. I setup the debugger and RDS and everything seemed to test fine, but I couldn't get it to debug for the life of me!

The thought occurred to me that maybe I actually had to use the file in the web to set breakpoints and debug with. I setup a new project which pointed to the web, opened the file I was trying to debug, set my breakpoints and browsed to the page. CF Debugger worked the first try!

So, if you've tried to use CF Debugger and had similar issues, or plan on using it in the future, just remember that you actually have to be debugging the file from the web directories and not a working copy outside of the web

Flex 3 Launch party in Northern California

NorCalFlex will have a Flex 3 and AIR launch party on February 28th. If you live in the area be sure to come and check out our special presentations, possibly win some cool prizes, record your own 30OnAir video and have some good clean RIA Fun! Check out NorCalFlex.com for details

SpreadsheetML and ColdFusion

It's been a while since I've posted anything to my blog so I figured I would share something I've been working on over the last month. A client hired us to refactor some applications for them, but as part of our requirements we asked that they upgrade to CF8 since they are running on CF 5. Naturally, since this application was built on CF 5, some things just are not worth hacking through to make work on CF 8, such as specific COM objects that create Excel worksheets.

I saw numerous postings on using POI to create spreadsheets with CF, but it just seemed like a very tedious and bulky process.  After a bit of research I found Ben Nadel's post on SpreadsheetML. After a bit of testing, it seemed that SpreadsheetML fit the bill. It generates Excel files many times faster than the current COM-based solution and was easy to write . Thanks for the info Ben!

Now, let me say that I wish MS would have used OpenXML, but one can't hold your breath for stuff like this. Overall, though, I will say I am impressed with SpreadsheetML. It allows me to add formulas, format data, add styles, multiple worksheets and workbooks.

One of the big quirks with building Excel with SpreadsheetML is the horrible debugging process. It wasn't until a few days ago that I figured out that the log file it tells you the errors are located in actually do exist.

As you can see from the image, it says the log is located in C:\Users\username\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.MSO. I am using Vista, so naturally this would be different on XP or Windows 2000/2003 (usually in the Documents and Settings structure). However, if you browse to the Temporary Internet Files folder you will not see a folder named Content.MSO, even though hidden files and folders are turned off in my settings. What I discovered is that the folder stays hidden, and you can only view the contents if you type the path into Windows Explorer. Silly Windows! I don't recall this ever being an issue on XP, so maybe it's Vista specific.
Now that I've found my error logs, let's take a look at what it tells me is wrong:

XML ERROR in Style
REASON: Illegal Tag
FILE: C:\Users\TJ2B84~1.SAN\AppData\Local\Temp\value_tech_summary_table_08-28.xls
GROUP: Borders
TAG: Font
OK, so that's pretty generic! There's the major downside to developing with SpreadsheetML, debugging is a serious PITA. However, once you get used it (it isjust XML afterall), you can readily spot issues and resolve them.

Probably the coolest thing about working with SpreadsheetML was how easy it was to convert an existing document from Excel format to Excel XML (SpreadsheetML) format . I simply opened the Excel file, chose File>>Save As and then set the "Save as type" to "XML Spreadhseet 2003". Then I used eclipse to open the resulting XML file and edited it, plugging in my CF code to generate dynamic values. Of course, MS code is a bit sloppy so it took some time to clean up the files and minimize the number of styles used, and other unnecessary code, but it sure beat having to create these complex workbooks from scratch. It was also very helpful in educating me how SpreadsheetML uses styles, formatters and formulas.

Now that I am nearing the end of the project I would definitely say I would use SpreadsheetML again, and probably recommend it to anyone who needs to create or recreate MS Excel spreadsheets. If you've used the CFComet stuff in the past and it's holding you back from upgrading to a newer version of CF, don't be afraid to jump in and give SpreadsheetML a try!

Mark the Date: January 23rd. Northern California Flex 3/AIR Pre-Release Tour with Ryan Stewart

This is just a reminder that Ryan Stewart will be speaking with us in Sacramento on January 23rd. I've just received a large box of swag (including an iPod nano!), so there will be a lot of give-aways!

Event Link: http://www.norcalflex.com

Adobe Hosting RIA Developer Camp, a Free Event!

Another great Adobe event, I'm sure! The camp will cover topics including Flex, AIR, AJAX and Flash. PayPal and Yahoo will also present. The event is in SF, CA on Nov 5, so sign up now!


http://www.eventsadobe.com/devcamp

Kalendar Winning Designs Posted

So, I finally got a small breather and was able to get the images online. I'll worry about cleaning it up a bit later, but for now at least you can view them.

The entries are posted on the demo site. You can access the gallery here.

Thanks again to Jason Durham and Mark Aplet!

Kalendar Design Contest Winners

The Kalendar team has spent the day debating over entries to decide the winner of the Kalendar Design Contest. It has not been an easy decision, a lot of work went into the entries and we realize this. That being said, we ended up with a split decision!

Jason Durham's was chosen due to some unique concepts for the UI design, which we will certainly incorporate in all future versions of Kalendar as they "just make sense".

Mark Aplet's design was chosen due to it's clean and functional design. A very simplistic design, it offers a more Web 2.0 feel.

We would like to thank the entrants for the time and hard work they have put into the designs!

So, you might be thinking, how do we award one license to both winners? Well, it turns out that I have a new copy of ColdFusion 8 Standard that I am not utilizing, so I have donated this to the project for the second winner. We will contact the winners directly tomorrow to award their prizes. In the coming weeks you will see the new skins implemented and available. In the meantime I will make a gallery available on the demo site in the next couple of days.

Kalendar Design Contest Ends Tonight!

Entries for the design contest are due by 11:59PM tonight, so be sure to get yours in!

Sys-Con Media Reeling After Loss of Major Sponsor

Sys-Con Media has lost Adobe as a sponsor, the community seeing this as a side effect of bad advertising practices and outright poor business management. A primary reason Sys-Con has lost the ability to continue publishing the ColdFusion Developer's Journal is because, without Adobe's backing, their advertising team is ineffective in placing ads in CFDJ. Calls for ad placement  had gone unanswered for weeks and when requests were fulfilled the wrong information was often given.

It is also believed that the majority of persons subscribed to CFDJ actually never requested or paid for a subscription. In order for Sys-Con to increase their "subscriber base" they simply spammed the community with free subscriptions. This is common with all of the Sys-Con Media family of publications.

Obviously this was not enough. Potential advertisers, tired of dealing with poor response and customer service from the advertising department at Sys-Con, failed to purchase enough advertising to keep the journal in circulation. As a result Sys-Con was forced to seek out Microsoft as a sponsor.

Sys-Con's major fear at the moment is the loss of other major sponsors. These sponsors, potentially wary about Adobe's decision to pull out of Sys-Con, may in turn decide to remove their sponsorship as well. In turn, Sys-Con has decided to attack Adobe's ColdFusion product as well as the ColdFusion community, trying to downgrade the obvious discontent among the ColdFusion community as a whole over Sys-Con's underhanded practices.

The previous editorial team from the ColdFusion Developer's Journal has also shed light on the subject, explaining how poorly Sys-Con handled the publication as a whole. Matt Woodward stated "The editorial board--such as it was--didn't serve as an advisory board at all, but rather was seen as a standing pool of free labor for writing articles.". Brian Rinaldi also writes "I was a part of the unfortunate CFDJ Editorial Board, which was kept both uninformed and ignored (so much so that none of the members I am in contact with had any idea this was happening). Therefore, I feel that I know firsthand that Sys-Con as a company could care less about improving CFDJ for quite some time now."

Sys-Con is a failing media company. They know it and are using dirty tactics in a last ditch effort to keep themselves afloat.

note: this story is a parody on the recent Sys-Con "news" that states that "ColdFusion is dead as a doornail". As a media outlet, Sys-Con holds the responsibility to ensure factual and unbiased reporting, which they have not done. As such, they have become the target of this parody, which in actuality, is probably not very far from truth anyway.

More Entries

BlogCFC 5.8.001 © Ray Camden