How to tips and tricks for Microsoft Visual Studio .net

Tuesday, January 8, 2013

How to learn to write software

Learning how to write software is one of those things that you have to do in such a way that it suits you.

Some people enjoy an environment in which there is a structured approach, and they have someone who has some form of curriculum that is followed, teach them. They are given the history of software development, the theory behind software development and some syntax to work with. They are told how that syntax fits together with other syntax and the reasoning behind why it is like that. Then they are given tasks to do to demonstrate their understanding.

Others like to learn how to write software on their own. That’s how I did it, and I would like to think that I’m not bad at what I do.

I’m not going to say that one method of learning how to write software is better than any other method, simply because I only really know about the method I used. I don’t have any fancy degrees or anything like that. What I do have is the knowledge that I have been employed for a long time by many different companies to write software that did what they needed and wanted. I’m definitely not the world’s best programmer, but I’m also not the worst.

I learned to write software by having a need to do something on a computer, and at the time, not knowing how to make it happen. So, the first step for me was to decide to do it myself.

I could have called a programmer in to do the work, but that would have cost money I didn’t have. Besides, I love computers, so development was kind of a natural way to go for me to go.

I didn’t start out programming totally green. I played with a Sinclair ZX Spectrum computer as a kid. It was the latest and greatest computer that I could get my hands on at the time. It plugged into a TV, didn’t have any way to store the programs that were typed in, unless you plugged a tape recorder into it to store it on cassette tape. It did have 16k of ram and could display 16 colours on the TV it was plugged into.

I started out buying books with the code that once typed into the computer and executed, would provide me with hours of gaming pleasure, but it used to take hours to enter the code into the computer before I could play the game. I saved the games onto cassette tape, and if I was lucky enough to have the saved game work the next time I tried to load it, I was able to play them again and again.

That’s was my first introduction to coding. The language was Basic. I didn’t really learn to programme through this experience, but I did get to understand how the code fitted together and that was a decent base to start on.

Many years later, I had the opportunity to work in a software development company as their technical manager, and since I had a basic understanding of how software was put together, I began to learn. We were using VB3 and VB4 at the time, and those were light years ahead of the old Spectrum Basic I first encountered, but I seemed to pick it up pretty easily.

I never actually wrote much code for that company, but I did do some. I still didn’t really know what I was doing as a developer until I left that company and began looking after my own client’s hardware and software needs. I had a client that needed a very custom application written. I quoted them, and when they accepted my quote, I had to find out how to actually write an application that did what they wanted, or find someone who would charge me to write it for me. I chose to write it because I couldn’t afford to pay someone else to do it for me.

Their requirement was pretty simple:

They needed to record the volume of liquid cosmetics that were filled into their containers for quality control needs. They wanted to record the volume by weight, therefore needed to be able to enter the specific gravity of the liquid going into the containers. Fortunately they provided me with the formula to work that out. Scales were connected to the computer and values came in from them, through serial cables, that the application had to record in a database, linking a product, batch and the values to each other.

There were some rules:

  1. Must be password protected.
  2. Must have a scale calibration module.
  3. Must store products for linking to container sizes and batch numbers.
  4. Must have various reports for auditing purposes.

I really didn’t know enough about coding at the beginning of the project to get it done. I had been paid and spent a deposit so had no choice but to deliver an application.

That’s where my learning how to write software really began.

I knew come basic syntax and how to use it, but didn’t really know how to write software, so I just started at the beginning. I knew that I had to provide access to a database for storage and decided to use SQL Server. I was writing in VB6, so found out how to use ADO to connect to SQL Server.

The first thing I did was design the user table and wrote the user login module. Once I had that done, I knew how to access, insert records, update records and delete in a SQL database. From there it was just a case of deciding what to do next and do it. If I didn’t know how to do what I wanted to do, I found out.

That’s how I learned how to write software. It probably wasn’t the best way to go about it, but it worked for me.

My advice to anyone wanting to learn how to write software, who doesn’t want to go the formal route, is to get hold of a computer that can run Visual Studio Express and to decide on a project, then to find out how to write code. Hopefully you have some knowledge about computers, but the most important thing Is to actually dive in and get dirty.

If you are thinking about learning to write software, you aren’t learning, you are thinking about learning.

Don’t think. Do!

How did you learn?

No comments:

Post a Comment