Is Xojo the Right Development Tool

Quite often prospective clients, and developers thinking of learning Xojo, ask my opinion of Xojo.  They are about to embark on a journey spending tens of thousands of dollars on a cross-platform tool and they want to know if Xojo is a right for them.  It’s a good question and I’ll share some of what I share with them in no particular order.

Xojo is pronounced “Zo Jo”.  I can’t tell you how many times I’ve heard it pronounced “Ex Oh Jay Oh” or something else.  They just don’t know and I think it spooks a lot of people as it doesn’t exactly roll off the tongue.  Xojo has been around under various names (REALbasic and Real Studio) for twenty years – all with the same company.  At that point it’s easy to name a dozen languages/development environments that were popular twenty years ago that either don’t exist today or been sold so many times that they’re now obscure tools.

This isn’t your fathers BASIC.  Xojo uses the BASIC syntax but this isn’t like the venerable Visual Basic or even older GWBasic or QBasic.  Xojo apps are NOT interpreted at runtime – they compile down into native code for each of the platforms.  The language itself is a modern object-oriented language that happens to use the BASIC syntax.  Xojo is updated three to four times a year and has undergone a lot of upgrades in the past two decades.  It first supported 68000 code, then PowerPC and Fat applications, Carbon, and now finally Cocoa on the Mac side.  They’ve added Windows, Linux, Raspberry Pi (Linux ARM), desktop and console application targets.  In the mobile space they’ve added iOS, and by the end of the year Android.  They’re also in the middle of the transition from 32-bit only applications to 64-bit applications.  For the most part things ‘just work’ and developers don’t experience too many issues (bugs happen but think about how many targets they’re supporting!).

Xojo applications are self-contained.  Take a compiled Xojo application and (with very few exceptions) literally copy the files to another computer and the application will just work.  Even Windows applications don’t need an official installer, however, it is recommended since most Windows users are comfortable and familiar with using them.  Most Mac applications are installed via drag-and-drop from a disk image but an installer can be used on the Mac as well.  This ease-of-installation is huge and it’s rare to have “DLL Hell” issue since all required libraries and resources are bundled together.  This does make the resulting output larger than some other development tools that depend on system libraries but I’ve rarely seen this an issue.

Xojo provides nearly everything you need in one tool (with some caveats).  The Xojo IDE has Code, Form, Menubar, Database, and Report editors (to name some of the big ones) in one tool so you never have to use another tool.  We’ve found the database editor to not be powerful enough so we prefer external database editors.  The built-in reporting tool also isn’t very powerful so we created our own reporting tool (Shorts) which has served us well in our consulting projects.  The nice thing is that all of the built-in tools work seamlessly with each other so the tools that are powerful enough for you ‘just work’ with few hassles.  The editors try really hard to protect your from hurting yourself while other tools are just a big text file that must be in an exact format.

The Xojo community is incredibly helpful.  The Xojo Forums are filled with some of the most helpful people I’ve ever met.  Some of the Xojo engineers respond to questions, but usually the community answers before they get to it.  Many other support forums are rude and condescending to newcomers to their language/tool.  The Xojo forum has even been known to answer questions about other tools.

Xojo is a cross-platform tool and because of this it has some compromises.  Controls are often the lowest- common denominator.  Grids especially aren’t as powerful as some are used to in the Windows world.  This is mainly because complex grids are not common in Linux and Mac environments.  Other controls have similar issues.  Things like automatic spell checking in TextArea’s are platform specific as on the Mac.  At times it is disappointing that there aren’t more control options for Xojo right out of the box (think date and calendar controls) but thankfully there is a third-party market for controls and libraries for Xojo that can often help.  Even though much is provided for you, it’s possible for a developer to use OS API’s using Declares that can significantly modify the appearance and functionality for some applications.

Xojo is a Rapid Application Development (RAD) environment.  Between the all-in-one IDE and the language creating applications in Xojo is fast.  This means that an initial investment can get your app developed faster and cheaper than many other languages.  Obviously some of this depends on the developers doing the work but it can make a huge difference.  We’ve always told clients that if they’re not happy with Xojo performance after the initial release they can use our code as the proof of concept to the developer in whatever language they choose.  There have only been a handful of clients that have ever switched languages after release and that’s usually been switching from desktop apps to web app.

The cost of Xojo isn’t very high compared to some tools.  For $699 per year per developer you can create web, console, and desktop apps for Mac, Windows, Linux, and Linux ARM plus iOS apps.  That’s all in the same environment and same language and with the exception of iOS applications (which requires a Mac) you can use Mac, Windows, or Linux to create everything.  Many developers use third party controls and libraries and even those are relatively inexpensive.  Plus, there are no royalty fees for your Xojo made applications.  All-in-All it can be a relatively inexpensive tool.

What considerations have I missed?

Recharging the Battery

One of the ‘joys’ of having my own business is that I’m always on-call and there are times I’m answering emails on a Saturday night.  Most of the time, it’s no big deal but it can become exhausting without a break.  This is why I need to take time off and recharge my batteries.  So should you.

Carol and I did that last week with a vacation in the Caribbean.  We had a lot of fun and got a chance to recharge our batteries and get away from work (and US politics).  And even though we weren’t technically working (I consider coding to be the real work), we did talk about our business and those things we are grateful for.

One thing we are extremely grateful for is the fact that we can take off for a week without feeling guilty.  That got us thinking on why is it so hard for consultants to take time off.  It’s not too hard to figure out but here are a few items from our list (sadly the list got a Bahama Breeze spilled on it and thus couldn’t be saved for posterity, but here’s what we remember).

If you’re not working you’re not making money.  So true for consultants, but my advice is to try to develop multiple income streams so you can make money without doing consulting.  We have our developer products (ARGen and Shorts are our big ones) and without any work on my part we sold some last week.  We also have our Xojo Training videos that are income.

Having that one big all consuming project.  A lot of Xojo consultants I’ve known over the years have that one big client that consumes nearly 100% of their time.  We have multiple Xojo developers and while we can do big projects that involve all team members, it’s pretty rare.  This means that our income (and risk of losing it) are spread across multiple projects/clients.  For us, projects come and go, and that means there are times when one or two of us get to work on internal projects but our income levels stay consistent.

It’s all on you.  Solo consulting stinks because it’s all on you.  I can’t tell you how many solo Xojo consultants I’ve seen come and go in my fifteen years.  Doing it all by yourself is tough and sort of ties into the one, big, all consuming project from above.  You only have so many hours in the week to code and if you don’t have help you still have to take time out for marketing, sales, and developing multiple income streams.  It’s just not possible for solo developers to be spread that thin.

Do you have a job, or do you have a business?  Over the years I’ve had multiple solo consultants chastise me and tell me that I’m just ‘training my competitors’ with my multiple employees.  Sure, that’s always a possibility, but is it probable?  So far, they haven’t and my thinking is that if they really wanted to have their own business they’d probably already be doing it without my training anyway.  Having and running a business is not the same thing as having a job.  Plus, that type of thinking comes from fear and I’m confident enough in my own abilities and experience that it simply isn’t a concern.

Consulting rates are too low.  I’ve talked about this multiple times but too often someone new to consulting will take their last real-world salary and figure out their rate from that.  This is absolutely the worst thing to do because as a consultant you don’t have a job you have a business.  You need to have a rate high enough to pay for health insurance, retirement plans, and to pay yourself during your vacation escapes each year.  It is your responsibility, as a business owner, to calculate what rate that is for you.  If you want to know my rate send me an email and I’ll gladly tell you but I will also say that if I was still a solo developer it would be higher because I can only code so many hours in the week.

You must recharge your batteries every now and then.  Without that you become inefficient and run the risk of burning out and you’ll be sending an unhappy client to me to take care of their project.  Don’t laugh because some of my best long-term clients came from a solo Xojo developer that had to leave consulting for one reason or another.  Some left because they were charging too little to pay for health insurance, retirement, and to recharge their batteries on a consistent basis.

So what do you do to recharge your battery?  And why do you think many people fail as solo developers?

Consulting Red Flags

The one absolute truth about consulting is that if you’re not working you’re not making any money.  The corollary to this truth is that you are either 100% busy or 100% not busy.  This is especially true if you are a solo developer.  It is very hard to turn down projects when they come your way but I’ve found that there are times when you should.

I get it.  Really, I do.  If you’ve been idle for longer than you’d like and money is starting to get tight ALL projects start to look good.  Don’t take the project because you need the money.  Take the project because it’s a good fit, it’s interesting work, and you think the client will be a good partner.

In the world of make-believe this is the way it should be.  In the real-world you don’t always have those options.  Plus, it’s really hard to figure out if a project is going to be a good one or not.  Here are some of the red flags I’ve come to recognize in fifteen years of being a Xojo consultant.

Other Peoples Code (OPC).  Code written by someone else is always a red flag.  We write code a certain way and if any of our team work on it we can rest assured that certain things will be done (naming conventions, comments, etc.).  No such guaranty with OPC.  It’s way easier to start from scratch but with most OPC projects you don’t have that option.  So you start with a level of uncertainty and having to decipher not only the coding style but often times the intent of another developer.  Learning someone elses code stinks.

Project complexity.  When I’m asked to join an existing project I try to look at how complex it is.  If it’s really complex I hesitate because I know it will never get less complex.  In many cases the original developer tried to be clever to solve some (real or imaginary) problem and while solving it completely overlooked a much simpler way of doing things.  Plus, if it’s not one of your core competencies it might not be a good fit anyway.

Another item under the project complexity red flag is excessive amounts of documentation.  From experience, most projects can be summed up with a page or two of high level description and then a dozen pages of important detail.  When the client sends you a very long document with high levels of detail you might be getting yourself in other your head.

Of course the flip side of that is clients that send you a paragraph or two of their idea.  In those cases we have to draw more information out of them, and depending upon the size of the project, we might actually charge them to write their specifications for them and let them get some competitive bids from other developers.  I think the lack of detail says they haven’t done enough homework on what they want and need.

Toxic teams.  Another issue with joining an existing project is trying to figure out if the team is toxic or not.  The existing developers will always have their own habits and you, as the consultant, need to try and match theirs.  What if those habits are silly?  I’ve seen teams that require a comment for every line of code.  I’ve seen some teams that disdain any comments under the guise that code should be ‘self commenting’.  Is there a team member who’s the ‘smartest person in the room’ and everyone else has to put up with it?

Project savior.  I can’t tell you how many times I’ve been asked to look at a project started by other developers and the project owner is desperate for it to get done.  In these cases they’ve spent a LOT of money with a developer and gotten poor, or no, results.  You have to ask yourself a few questions.  Was it the developer being incompetent, the owner being unreasonable, or both?  If you take one of these projects you can either be the hero by completing the project, or you can be the goat for being just as incompetent as the original developer.

Project owner/developers.  I’ve found that working with project owners who are also part-time developers also can be a pain to work with, but not always.  The ones that come to me realizing that creating an application isn’t easy and requires time they don’t have and knowledge they don’t have time to acquire tend to be okay.  Those that say it should be ‘fast’ and ‘easy’ for someone with your skills have their expectations set too high.  Software development, in many respects, is more art than science.

Always complains about cost.  Every client wants their custom software done cheap, quick, and on time.  The industry joke is to pick two of those qualities.  Software development of custom software isn’t cheap, nor is it quick in most cases.  If they balk at the initial estimate it probably won’t get any better.  They certainly won’t like any change orders.  We had one prospective client ask us three times, over the course of a year and a half, what the price was going to be to complete their project.  I don’t know if they expected our price to go down, or what, but eventually they found a developer to do their project at the price they wanted.  And then had the audacity to come back six months later then that developer couldn’t deliver.

Been through many developers.  Perhaps my biggest red flag of them all is when someone comes to us after going through several other developers.  Listen to their complaints about the other developers.  Were they too slow, did they charge too much?  I’ve even asked for permission to contact the previous developer to get the news from the developer perspective.  The community is small so there’s a good chance I know them and I know I’ll get the developers perspective.  Use those connections if you can because you might discover some useful information about the client and the project.

Just because you need the work doesn’t mean you should take every project that comes your way.  Be selective because you’ll avoid some heartache and probably enjoy your work more.  What red flags have you developed over the years?

A Short Video is Worth a Hundred Emails

One of the ‘joys’ of consulting is the language difference between developers and the customer.  Developers have a ‘language’ and clients have a completely different ‘language’.  A perfect example is when a customer says ‘the application crashed’ and trying to interpret that.  I usually end of asking, did this crash mean a dialog appeared saying something happened (an exception was caught), or that the app just went ‘poof’ and disappeared (something way more serious).  For Xojo developers those two definitions of ‘crash’ mean totally different things.  Those nuances mean nothing to the customer.

Email is a notoriously bad way to communicate.  It’s easy miss details, or worse yet, misconstrue intention.  It’s easy to read anger, annoyance, or <insert feeling here>, that the sender did not imply.

We’ve had instances where we go round and round with a client via email on some detail when a simple phone call would have solved the issue within five minutes.  I know it’s not ‘modern’ but sometimes a simple phone call solves a lot of issues.

More recently I’ve had a client say that a sequence was wrong and described it with some detail.  I took a stab at the fix and then gave them another build for testing.  Still had issues.  The problem was that they’re not describing what’s really happening – they’re using customer language when I needed developer language.  The solution was a simple video.

Most people have a smart phone that can take video.  In my case, once I knew what the customer was really doing it was a simple fix because I could see what they were really doing.

Voice calls are important, videos are important, and doing screen sharing is becoming another important factor.  Think about using any of these tools before sending yet another email.

Estimating is an Art, Not a Science

A question that comes up quite a bit is how to do proper estimating.  It’s not an easy thing to quantify as much of involves gut feeling at times.  It’s why I feel that estimating is an art, not a science.  The hard thing about estimating is that it takes experience to know if you’re doing it right or not.

My first bit of advice is start using a tool to track your time.  If you can’t do it by specific task, as least do it by overall project.  Once the project is done you can then see if your estimate matches reality.  It won’t at first but that’s why you track your time so you can make adjustments on the next project.  After looking at several projects I came up with the idea of the times three for estimates.

When you look at part of a project, say a form, your estimate tends to be something like this:  if I know everything up front and there are no major surprises this is what is how many hours it will take to complete the programming and testing of this form.  However, we rarely know what those major surprises are up front so at best this is my guess and multiply it times three to come up with a more realistic estimate.

After a while I started to realize that some forms just aren’t going to take that long.  An About Window just won’t take more than fifteen, twenty minutes – ever – so why do the multiplier on that?  It makes no sense.

What makes one form harder to develop and test than an other?  Complexity.  A simple List form and an Add/Edit form might take an hour each (if that) to complete but busier versions of both might take three to four hours each.

What brings in the complexity?  Well, that depends on a number of factors.  Number of controls on the forms is a good start.  The business logic is another.  If how things work depend on what the user is doing in the controls you can rest assured that programming and testing of it is going to take longer than you expect.

Another part of complexity is the number of unknowns.  If you have to do a complex calculation that involves a bunch of math (especially if you’ve never done said math before) it should up the complexity.  Doing some programming concept in Xojo that you’ve never done before should up the complexity as well.  In both cases you should expect some research time, maybe even time to do a small example project, and a restart or two since you’re learning as you go.

In my initial guess I still do the ‘if I know everything up front and there are no surprises’ estimate.  And then my multiplier is my feeling of the complexity of that part of the project.  The complexity factor is now my multiplier.  So an About Window has a complexity of one.  A simple list form has a complexity of one and half, but a form with several page panels or containers that do different things based on user input might be a complexity factor of three or four (or more).

I tend to break projects down to several parts.  The first is overall project design.  There are certain number of hours just to set up the project and create the classes I need.  There’s usually some database design and implementation.  Do I need to make any special classes or subclasses for functionality that I already know about?

When it comes to the UI I often take the database design as the guide.  Each database table is (probably) going to need a List form and a way to edit it.  Figure that a list table is only going to need a few of the fields for listing but the Add/Edit form is going to use all of them.  Are they all text fields or is it a mix of lookup fields with foreign keys?  Each of these adds to the complexity of the forms in question.

Coming up with an estimate is sometimes an art.  It takes experience (and failing a few times) to get the hang of it which is why you need to track your time.  Using the complexity as a multiplier might be a good way for you to start getting more accurate estimates.

Let me know if you do something different for estimating.  How do you track your time?

Happy coding!

Tools of the Trade

We are currently getting our kitchen remodeled.  We’ve used the contractor before because we know he does quality work and gets it done when he says it will be done.  Plus, when he gives us a bid, we know that he’s already calculated into the bid stuff that we don’t even know about yet.  There’s not really much difference with doing software consulting.

Most times when clients come to us they have only a vague idea of what they want and need.  Usually we can count the number of paragraphs of specifications on one hand.  So when we start our estimating process we just add stuff in ‘just because’ we know that a typical desktop or web app will require certain types of things.

For example, we know that nearly all applications are database driven.  Thus, we include ActiveRecord unless there is a good reason not to use it.  ActiveRecord gives us some other advantages like speed of development time, fewer bugs, and in an update to ARGen (coming soon) the ability to create initial List and Edit forms (for both web and desktop) with controls already laid out.  It’s far from perfect but using ActiveRecord and ARGen saves us a lot of time.

Many business applications require reporting.  BKeeney Shorts has been around a number of years and has allowed us to create code driven reports.  Now, with the integrated report designer we can give users the ability to create their own reports.  It’s still a young product, and there are things it can’t do yet, but for a vast majority of business reports it works great.  Now, instead of taking a couple of hours to code a report it now takes minutes to design the report and see it right in the designer.

We’ve used the same preference class for many years because it works natively on Mac OS X, Windows and is good enough in Linux.  We’ve developed our Window Menu class that works well too.  For web apps we have our own paging control as well as a customized sorting listbox.  These are all things that we assume we’re going to use in most projects.

Do we factor these things into our estimates?  Of course, we do. We spent time and effort to develop them in the first place.  These tools are part of our standard toolkit and using them saves us, and the client, money.  To put it in terms that our kitchen remodeler might use, he knew going in that he would use a tile saw.  He could go rent one just for our project but he’s purchased one years ago because he knows that he typically has to use one.  Renting makes no sense for him when he uses it for practically every project.

I’m not saying that you need Shorts and ARGen to get your projects out the door (not that I wouldn’t mind the sales), but if you struggle with the tedium of database programming, or you dread doing reports because the built-in tool isn’t what you need, then these tools might be good solutions for you.

Regardless, if you use our tools, or something elses, you need to establish your toolset.  Having a variety of tools to get your projects done is crucial for a consultant.  Whether you use plugins or third party code these have the possibility of saving you hundreds of hours of coding time.  At the end of the day, time equals money.

Happy coding!

Imposter Syndrome

Today I’m going to talk about the Imposter Syndrome.  That feeling that says everyone knows you’re faking it and they’re going to find out, at any minute, that you’re a fraud.  You’ll be cast down into the depths of despair in humiliation because EVERYONE WILL KNOW YOU SUCK!

I’ve experienced this feeling and I’ve had conversations with developers I greatly admire that struggle with this too.  This is both heartening because it means we’re not alone in this despair, but it’s also sad since that means there’s really not a point where you’ve ‘made it.’
Feeling like an imposter doesn’t go away as you gain experience but it’s not as big a deal.  With more experience you know the things you know and have hopefully gained enough knowledge and wisdom to know where to start looking for the things you don’t know.  Still, sometimes, you have to fake it.

Wait, fake it?  Yes.  Sometimes you have to be an imposter.  Let me use a poor analogy to explain it a bit more.

When you start a new video game you just start playing, right?  You know a few rules and as you progress you make mistakes.  You learn from them and at some point you level up.  This comes with a fancy cut scene showing your character victorious over the foe, gaining an object of some value, and gaining experience.  Your character is more wise and capable of doing more things.  You were up for the challenge and overcame the barriers to the next level.LevelUp

Being a consultant and software developer is no different than a video game.  You have to play the game to learn the rules.  The consequences of not learning the rules can be disastrous but hopefully you’ve done your research so those rules don’t kill you (metaphorically speaking, of course).

At some point you level up from time and experience doing consulting and programming projects.  Sadly, there is no amazing cut scene with dramatic music since we rarely, if ever, see the level up process.  It’s shame really because I’d really like to have dramatic music just play from nowhere and obtain some cool device from my endeavors.  But I digress.

For a Xojo consultant, like myself, it’s knowing parts of the framework really well and realizing that I don’t know some parts as well.  I do a ton of small example projects to learn those bits better.  It means creating my own tools to make my daily life easier.  Those tools involve ActiveRecord, and Shorts to name a few.  These were not developed overnight but over the period of a decade.

So the next time you feel the Imposter Syndrome hitting, recognize that it’s a natural part of the process.  You leveled up without noticing and that’s okay.  You can handle it.  It means you’re winning.

VB6 and Windows 10

It looks like the Visual Basic 6 holdouts can breathe yet another sigh of relief.  Visual Basic 6 seems to work with Windows 10 as do VB6 apps, though not without some caveats.

I’ve been reading a few threads in various forums where most people have had few to no problems developing VB6 apps or running them in Windows 10.  I’ve seen at least one VB6 developer that claims they’re OCX laden application has issues when loading.  They say that some of the controls simply fail to load at runtime.  Funny enough, it happens only on 32 bit Windows and 64 bit Windows 10 works fine.  They gave no information if these were new installs or legacy upgrades.

Another developer claims to have problems installing VB6 Service Pack 6 on Windows 10.  They tracked it down to two Registry keys not being written.  This website gives a process to install VB6 in Windows 10.  The fact there is now a procedure to install an old app on a new operating system should be pause for concern.

The only way to get hold of VB6 is to have a MSDN subscription.  The subscription is $500 so that doesn’t seem like a huge burden.  But then again, remember that Microsoft is not supporting VB6 though the VB6 runtime is shipped with Windows 10.

There are a boatload of VB6 applications still out there so I think support for VB6 will be around for a long time.  In April, 2014 an InfoQ article  stated there were hundreds of VB6 developer positions listed on Dice and Monster.  VB6 officially went out of support in 2008 so good luck finding entry level and even junior developers to fill those spots – no one is learning VB6 any more.  One of my old clients has had a revolving door of VB6 developers for several years now and it’s getting harder and harder to find competent VB6 developers, and developers that wish to work with it.

As a Xojo consultant we’ve converted quite a few VB6 apps.  Well, convert is a strong word, really it’s a rewrite.  Despite both using a BASIC-like language, the two languages are diverging rapidly (not that they were ever really all that close to begin with).  Many issues that we spent a lot of time working around in VB6 just don’t happen in Xojo.  In our experience entire modules and classes just disappear because we don’t need them in Xojo.

Xojo is updated several times a year while VB6 isn’t.  Xojo is about ready to release a new version that creates 64 bit versions of Mac OS X, Windows, Linux for desktop, console, and web apps.  iOS will also be 32 bit and 64 bit.  VB6 is stuck building only 32 bit Windows apps.

Is Xojo a perfect alternative for VB6?  No.  It is not perfect for every application.  Because its strength is really cross platform applications there are compromises all over the place.  If you look at Mac and Linux applications they just don’t have the complex controls that Windows does.  For some this is a deal breaker because their application demands it.  However, if you want a Mac OS X or Linux version of your application you’ll want to redesign the UI anyway.

Ten years ago our clients came to us for Windows apps first and if we could do a Mac version for the graphics geek that was great.  Now, they come to us for Mac apps first and if we can do a Windows version for the accountant in the corner that’s great.  Xojo does web apps now and that’s become an increasingly larger portion of our business and VB6 just doesn’t compete in that area.

The Xojo universe is full of VB6 developers and the Xojo forums are full of them.  The developers that have found and started using Xojo usually go through a short learning curve and a few WTF moments.  And then, after they stop trying to make Xojo work just like VB6, they embrace the tool and enjoy life again.

Windows 10 is yet another bullet dodged for VB6 hold outs.  At what point do you start to panic and find an alternative?  I guess if you’ve waited this long you’re hoping that Microsoft keeps supporting the VB6 runtime forever.

I am biased, naturally, but Xojo really is a good product and a good solution for many applications.  If you would like to find out some rough costs of moving your application to Xojo we have a utility that will give us some metrics on your VB6 project.  It can be found at http://www.bkeeney.com/vb2rbconversion/

Happy coding!

Licensing Systems for Xojo Applications

For years we’ve been using eSellerate for purchasing and licensing and registration of our apps.  We’ve recommended it to clients too and, for the most part, it’s worked quietly, steadily, and hassle-free for many years.  Their plugin is still using the old Real Studio format and they’ve said in several emails that they will not support Xojo going forward.  With Xojo moving to 64 bit in the R3 release it’s time for us to look at alternatives.

We liked eSellerate for a number of reasons.  For one, it was pretty simple.  Once you learned the intricacies of their web portal it was easy to add products.  Their sample app sucked but we figured out a better sample and offered it as an example for others on our website.  After years of using them I could set a new product up in as little as five minutes.  Then, they handled all of the various sales taxes and VAT for the states and countries that need it.

After the purchase, eSellerate would send an email to the user with purchase details.  This included license code, download instructions, and any other messages that we wanted to give them.  And all of this without any intervention on our part.  It just worked.

eSellerate also has an in-application purchase which we found to be pretty useful.  Users could purchase the application without ever having to leave the application.  For some people this was a nice feature but I’m not sure how necessary this is any more.  Lot’s of people purchase things over the internet with no qualms.

When it came to the registration part of things they had a number of nice features.  I could control how many machines could be activated with a single license.  This led to some instances where users didn’t deactivate a license on an old machine and couldn’t activate it on a new one.  However, a 30 second trip to the eSellerate web portal usually solved this.

On very rare occasions we’d get a user that couldn’t activate an app because of security restrictions on their network.  To solve this eSellerate had a manual activation process that would bypass all of that.  It was kind of tedious but then that’s why it’s called a ‘manual’ activation.

Bundling products together was pretty simple and even setting up payments to a third party was easy.  It was flexible and I know it was used in a number of bundle offerings over the years because of its simplicity.

So now we are on the hunt for the next purchasing/licensing/registration system.  We could write our own but I really don’t want to do that for a lot of reasons I won’t go into here.  Ideally, we’d find an existing system that integrates into our website that takes a variety of payment types and also handles sales taxes.  The last thing I want is to get hounded by a government entity – I just want that to happen automatically.

I’d also like to keep the per machine registration with restrictions on how many activations a single license can do.  It must work on Mac OS X, Windows, and the most popular Linux distributions.  Not that we have a lot of Linux applications but we have some and I don’t want two different systems if I can help it.

The in-application purchase and registration was nice but that’s not necessary any more.  I think most people are comfortable now buying over the internet.  However, offline activation is still something that is a requirement.  There’s no telling where customers are and what security restrictions are in place.

I guess the other part of the equation is that I, nor or customers, need something them an arm and a leg.  I’ve see a few licensing schemes that want $300 per product per month.  While they seem really nice, that’s above and beyond what we want and need.

A few names that have come up recently are LimeLM, Paddle, FastSpring, and I suppose even the venerable Kagi is in play.  FastSpring is more of an eCommerce front end so what are you using for application licensing?

What I’d like, Dear Readers, is for you to share your experiences, both positive and negative for any of the services listed.  Have any missed any that should be on the list?

Having the Same Object Handle Multiple Tasks

It’s often tempting to write some code to do a task and make it generic enough to handle similar but different tasks.  A great example that we dealt this this week was a picker dialog that was used generically for people, organizations, and skill sets in a Xojo web app.

It made sense.  The dialog is called from multiple places and it does the exact same thing in each place (displays a list and the user can filter on the list).  What’s different is what data we pass into it for initialization and what data it loads for display.  We wanted the exact same UI in all three cases.

We all want to write as little code as possible.  That’s what’s great about being a lazy programmer.  Do more with less.  That works until it doesn’t and, to be honest, we’ve learned, the hard way, that sometimes the best approach is to make your objects do one thing and one thing only.  Why?  Because inevitably the client will say, this is great, but we want to filter for ‘x’ on people, and ‘y’ on organizations, and neither of those things are interchangeable UI-wise and neither x nor y make zero sense for skill sets.

The first approach is to put lots of if-then-else blocks into what was once a very generic picker dialog.  Now it’s a complex UI that has three distinct code paths.  This complicates testing since every time you make a change it now has to be tested in all three areas.  What worse is the code becomes complex and if you’re in a hurry (and who isn’t?) it’s easy to change the WRONG bit of code.

Our solution was to write the first dialog, get the UI working properly, and then duplicate the entire object and customize it for its new task.  <Gasp>  I know, bad OO programming, right?  We disagree and that’s coming from the school of hard knocks.

The end result is that we have specific pickers for people, organizations, and skill sets.  It’s now simple for a developer to make a change for the picker in question.  No longer do they have to think, “gee, which datatype am I fixing this time,” and possibly get it wrong.  Keeping it simple reduces accidental coding bugs and it reduces unintended bugs due to code changes.

Testing also becomes easier because if we’ve done something to the employee picker, we don’t have to test organizations or skill sets.  Likewise for the other two areas.  Simple is good.

The one area that it does become a bit messier is if we have to do general user interface overhaul.  Now you potentially have three places to do it.  However, since we have WebStyles with web apps this becomes trivial unless you’re rearranging UI elements.  Xojo Desktop apps are a little harder since there are no styles but in those cases it’s actually fairly easy to copy/paste UI from one form to another (assuming that’s possible).

Call me cynical, but I would gladly work on UI for an hour to ensure they’re identical to futzing around with code in three separate code branches that are nearly identical.  I am a lazy developer after all.

Our experience says that generic, reusable objects, often lead us into trouble, so we tend simply not to do them.  But how do you teach that to a new developer and one that’s trying to do their best to use good OO conventions?  And when do you reach that breaking point where the generic way makes it harder than its worth?  Good questions that I don’t have good answers for.

Happy coding!