Stupid Question 61: Coding at the click of a button, go or no go?
Coding at the click of a button, go or no go?
A couple of weeks ago I had a discussion with a senior developer about newbies/n00bs, since I started programming this has been my favorite subject and I love to hear advice, opinions and stories related to that. The programmer told me that he was annoyed that Microsoft made it so easy for programmers now a days, one could only drag and drop, and generate code at the click of a button.
This is very interesting. Complexity of systems has increased, and user expectations are bigger than ever, which demands more from the programmer. I can understand that a user interface for developers to work with, and wizards, is less frightening and for many more appealing. And it could, and probably does, attract more people to begin with programming. Awesome!
At the same time it worries me. Sometimes this abstraction adds ‘coincidental code’ / ‘accidental code’. And it removes an important learning process,- some of the time. An example would be App Inventor. This software lets you create Android applications without writing a single line of code. What’s great here is that it gets more people interested in programming, I love that! What worries me is the use of this for production apps, even LOB apps.
The code by clicking abstraction can be an even bigger problem when working with data and services, the problem being when the developer doesn’t understand what is happening in the background, where the code is generated, what it does and what the implications are. This probably also goes for frameworks and certain API’s. It will only save you time if you ‘get it’.
As for the ‘Microsoft making it too easy’-statement, I don’t agree, as with every good intent there will be misuse, but I think what is important is to make developers aware, and encourage them to go beyond the wizards.
My answer:
It’s a go to get started, but make sure you understand what is happening. Have a good look at the code generated, and look for surprises. Sometimes it’s really a no-go, ask experienced/senior developers when in doubt, or maybe ask nonetheless. And make sure you ask more than one person.
What do you think? Please share if you have some good/bad examples
Comments
I agree! I'ts a really good way of getting you started, especially when you're introduced to new functionality in frameworks. However we will continue to stumble upon people that will always take the shortest route to completion. I'm thinking of all the "Copy-Pasters" out there. I used to work with a guy that whenever he came across a challenge scouted forums and simply copied the code he found straight into our production code without changes. We spent many hours fixing **** he implemented...
If you had programmed in c, c++ you will know how much pain it is to include each header files and start from the scratch! By "code on click of a button", I guess you mean auto generated code ? But what needs to be understood is .NET lets you code even on a Notepad. You can write everything from scratch on a notepad. No one is stopping anyone! But! Visual Studio is RAD Tool (Rapid Application Development) So yeah it makes sense to auto generate lots of code and Visual Studio does a good job at it! Regarding App Inventor maximum apps developed using such tools end up being a fart sound app anyways! Debugging in Visual Studio is beautiful <3 try working with other software you will know the pain :)
It was drag and drop tools that got me started, hooking up MS access databases to datasets using Dreamweaver's drag-and-drop tools. Seemed like magic for the first few sites I built, then I hit the "there-isn't-a-button-for-that" wall and actually had to switch to code view and learn what was going on. That led to hacking the generated code and ultimately onto writing my own Classic ASP data access code from scratch. Some drag-and-crop tools make it easy to transition onto a more DIY approach however many don't. ASP.NET WebForms was one of the big offenders here, in my opinion, because there was such a conceptual leap between dragging a datasource/datagrid onto a page to writing your own code to modifying the default behaviours. Compared to the old dreamweaver code-gen, WebForms was more of a black box, more "magic". If you came from more procedural languages (Classic ASP, PHP etc.) then it was harder to see what was going on without understanding the full abstraction and often felt like doing simple things it was more complex than it needed to be.
It's a good point, indeed it is. But if we think about it, code generation, at least in the .NET world (not only, look at JS with all its dialects), surrounds us. Who doesn't add a web/service reference, who doesn't create an entity framework edmx, even other cases..who looks at code generated by this? Very few people...
Last modified on 2012-10-17