General information
Title:
Visual Design vs. Coding
Hi,
I've been playing around with VFP now for about 8 months and am working on
my first app, a conversion of a FP/DOS app. In the process I've created a
couple of my own classes, nothing special, using the visual design tools
that come with VFP. I also noticed that a lot of people seem to be
hand-coding their classes and then instantiating them with the
CREATEOBJECT() function.
I can see that, when someone is looking for help in a forum such as this,
you can't give them an example in a VCX file without attaching it and
generally annoying everyone else. This makes at least one obvious advantage
to coding classes by hand, the ability to spread them around by email. I
have to admit that coding seems more like real programming than using the
visual tools and, as silly as that reasoning is, I have to admit that's one
of the reasons I never used the Screen Builder in FP/DOS.
However, I have to think that, if you're going to hand code there must be
some advantages other than that. Perhaps a hand-coded subclasses are less
resource-intensive or whatever. What exactly are the advantages to writing
the code rather than using the visual design tools? (Obviously I'm not
talking about non-visual classes here.) I gave some thought to this this
morning and the list below is what I came up with.
Visual Tools
Advantages
Objects can be created more quickly with the visual tools. Placement of
objects in a form is done by clicking with a mouse rather than writing
multiple lines of code.
Disadvantages
The visual tools tend to hide the workings of the language from you. You
don't really see what's going on when you're clicking away with a mouse.
This is not a disadvantage if you don't care what's going on.
It is more difficult to send an object via email if it was designed by a
visual tool. If you do it, you are more likely to annoy a lot of people.
Hand Coding
Advantages
Hand coding gives you a better understanding of what is going on in the
language.
You can send code via email which you can't do with a VCX or SCX unless you
attach them. In a mail list or Usenet newsgroup situation, this is most
certain to annoy a lot of people.
It is much easier to change the class on which the object is based if the
object is hand coded. It is possible to do this with a visually designed
object but it is much harder and may require an additional tool (class
browser). On the other hand, how often do you do this?
Disadvantages
Hand coding results in slower development than using the visual tools.
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only