Fog Creek Software
Discussion Board




Delphi docs useless; how's VB docs?

I recently asked about easy Win9x development (http://discuss.fogcreek.com/joelonsoftware/default.asp?cmd=show&ixPost=1871&ixReplies=14). I got many helpful responses, including suggestions to try Delphi. I finally gave it a serious look last night. Though the interface and tools seem robust, the documentation is woefully out of date. I was trying to go through the tutorial, but I had to give up: the docs had deviated too far from how Delphi actually worked for me to figure things out.

So, since Delphi seems inappropriate for a beginner, any comments on the help and tutorials for VB6 (and specifically the edu version, with its "learning" extras)? Or is there a secret Delphi help file that is up to date?

David Fischer
Tuesday, January 08, 2002

Just check out delphi.about.com and you could get good tutorials. Its a fact that Borland docs are not as good as MS. But the help that you can get from the newsgroups and web will be more than enough.

Sunish
Tuesday, January 08, 2002

Huh?  How specifically are the Delphi docs "out of date"?

Having used Delphi since version 3, I can assure you that - although additional features have been added - even the Delphi 3 documentation is still valid for Delphi 6.

Could you elaborate on "the docs had deviated too far from how Delphi actually worked" with some specific examples?

John Elrick
Tuesday, January 08, 2002

Some examples:
The Text Editor tutorial tells me to:
- double click the "ActionManager" in the "Additional" tab of the components palette.
1) There is no ActionManager, anywhere, much less in the "Additional" palette.
2) The closest named thing is the "ActionList" in the "Standard" palette.
3) A few pages later, a picture of the ActionManager is shown and it doesn't match the appearance of the ActionList

- to make the app menu, it says to load a file from VCL/sources (or some such).
1) The file doesn't exist; there is something with a somewhat similar name, though.
2) Loading the file is supposed to bring up a graphical widget with an ImageListManager in it. The file I find is only a text file of source code
3) There is no "ImageListManager", but there is an "ImageList" and an "Image"
4) The ImageListManager is supposed to have in it icons for the New, Save, Open functions. However, the default ImageList is empty

- To make a menu, a menu item is to be clicked on the palette. It is supposed to place a menu bar in the app window.
1) The menu bar button has different name, and a different location, than described by the tutorial.
2) It doesn't create a menu bar initially (only after I start adding pieces to it in the editor)
3) Tutorial says to drag items (e.g. FileOpen) from the ActionList, and drop them in the MenuManager to associate them. This does not work at all. I can't drag ActionList elements to the menu bar, the menu editor window, or anything else, for that matter.

At the above point, I gave up.

Maybe I got the "joke's on you" edition, but the tutorial substantially disagrees with the actual program. Maybe fine if you already know Delphi, but I've never used it, and was very baffled after a while.

David Fischer
Tuesday, January 08, 2002

Sunish,

Thanks for the suggestions. Unfortunately, after an hour os searching both delphi.about.com and the web in general, I couldn't find any decent tutorials on Delphi 6. The closest was one from 1999 at about.com. I figured that was for Delphi 4, or 5 and would cause me the same grief that I currently have.

Thanks for the help and suggestions.

David Fischer
Tuesday, January 08, 2002

I hope someone at Borland reads this. It is painful to observe someone giving up on what many consider the superior development tool for Windows after just one day because the tutorials and documentation aren't good enough to get you started.

Johannes Bjerregaard
Tuesday, January 08, 2002

What version of Delphi were you using?  Personal, Pro, Enterprise?  Were you using the Trial version or a purchased version?

The Action Manager is right on the Additional tab of my copy of Delphi 6 Pro.

John Elrick
Tuesday, January 08, 2002

It seems like David downloaded the Personal edition, but the tutorial/help was from Professional or Enterprise edition, therefore the confusion.

David, don't let some issue with the documentation keep you away from an excellent development tool.

If you need some help, you can always count on Borland's newsgroups:

http://newsgroups.borland.com/

Michael

Michael
Tuesday, January 08, 2002

Only for newbies:

Since i'm also a huge Delphi fan and would hate it of someone gives up because of documentation issues, here is something i always do learning a new language (currently VB,  it is nightmare, just what i expected):

take the Google search engine (or even better the Google toolbar), type in some words and 'Search Groups'. Most of the times you will encounter threads dealing with the subject. What also works fine is pasting in the (literal) error message/exception.

Especially the latter can save enormous amounts of time.

Stephan Westen
Tuesday, January 08, 2002

Yes, I'm trying the "Personal Edition" (or whatever it's called).

"David, don't let some issue with the documentation keep you away from an excellent development tool."

Fundamentally, if a company can't be bothered to provide usable documentation with their demo program, then that tells me they don't want my business, and doesn't inspire me to look at paying for their product. Even more unexcusable when they're the underdog, trying to gain market share against the MS behemoth.

I'd like to not give up on it -- it looks like a good program -- but I don't want to spend any more time on a potentially futile effort to find super-basic "how to use this program" information. Windows development is unknown territory to me, and I need a program that will hold my hand, and walk me through it. VB may not do that, but hopefully it won't give me bad directions, like Borland does.

Still, I'll check on the academic pricing of the basic Delphi6 program. If its docs are accurate, as they seem to be for the Pro edition, and is priced comparably to VB (< $100), then I may take a chance with it.

The only thing worse than having no trial program, is having one aggravates and causes you to lose potential customers. :(

David Fischer
Tuesday, January 08, 2002

This really is foolishness on Borland's part.

When you consider how much thought has gone into Delphi its amazing that they can do something so stupid in the evaluation edition.

The first thing people are going to do with the evaluation edition is run through the tutorial.  This type of experience is going to put anybody off.

Ged Byrne
Tuesday, January 08, 2002

The delphi dolphin provides good tutorials.

http://www.delphi-dolphin.com/

Unfortunately, I think you'll have the same problem with the standard edition.  For example, none of the database components.

Ged Byrne
Tuesday, January 08, 2002

I'd suggest for evaluating the full product that you use the Delphi 6 Enterprise trial. This is the full product!

The free personnal edition is just too limited to evaluate the power of this great tool

Robert Chevallier
Tuesday, January 08, 2002

My suggestion is that you get a copy of the Delphi evaluation CD, which will give you a 60 day trial of Delphi Enterprise. Using the Personal verson with the doucmentation is not going to be a good expereince. Personal leaves out many of the usual components found in the Professional and Enterprise versions.

As one who has been programming for 18 years, I can personally attest that for Windows development and now Linux development (with Kylix), it is hard to beat Delphi, especially for a beginner.

With Delphi, unlike Visual Basic, just because you start as a beginner, does not mean you have to continue to develop applications like one. Delphi is extremely easy to use for simple tasks, yet powerful enough to handle  practically any task. With Delphi, I have the power of C++ without the complexity.

P Nichols
Tuesday, January 08, 2002

A bit of good news!

I looked around the Borland website again, and found their documentation download section. I dl'ed the Personal Edition docs, and behold, they're fixed! They've got extra links for the Personal Edition and for the Pro/Ent editions.

And these are new; they aren't in the docs that I got when I installed Delphi6 Pers Ed.

Hopefully this will be sufficient to get me going again.

Thanks again for all the ideas and suggestions!

David Fischer
Tuesday, January 08, 2002

And one more thing, from a new users point of view you need not differentiate much with delphi 4,5 or 6. So most of the old tutorials should work with delphi6. Though personally I still have not evaluated D6. I feel until the first 2 updates of any product comes out there will still be lots of bugs to be fixed, be it Microsoft or Borland

Sunish
Wednesday, January 09, 2002

Thanks again, Sunish, for the info. I didn't know that D6 would likely be similar to D4, D5.

I successfully completed the tutorial with the updated documentation! My first Win9x app ever! I'm a Delphi 6 expert!!! ;)

Well, maybe not. But there's hope once again.

Thanks to all for the ideas and general recommendations for Delphi. This may work for me, after all.

David Fischer
Wednesday, January 09, 2002

David,

Don't forget to take a look at C++ Builder.

It shares Delphi's IDE and Component Library, but will save you having to learn Object Pascal.

If you do decide to go with Delphi, I recommend Delphi in a Nutshell as a good reference for the language (too many books seem to focus on the IDE)

Ged Byrne
Wednesday, January 09, 2002

Ged - I don't know if you have personal experience learning Delphi with Delphi in a Nutshell, but someone I know (who was already a C programmer) tried that, and at several occasions wished that the book would burn in hell. I think it was mainly due to typos in the sample code, which may not matter to someone who already knows the language, and they may even be corrected in the current edition, who knows.

I would recommend looking at Marco Cantu's Mastering Delphi.

Johannes Bjerregaard
Wednesday, January 09, 2002

Ah, yes.  In a nutshell is great for reference, but avoid typing in the samples at all costs.

I've never tried Mastering.  I originally learnt from the Delphi 2 in 21 days that came with the Learning Edition several years back.  It was quite good.

Ged Byrne
Wednesday, January 09, 2002

"Don't forget to take a look at C++ Builder"

I dl'ed it, but it's a large app with registration hoops to jump through, which make it too much hassle to get it home and try out, where I work on this little project.

Now, I need to see how hard it is to get Delphi6 to talk with C code.

David Fischer
Wednesday, January 09, 2002

You'll need to...

1) make sure the C functions you want to call from Delphi are using the stdcall calling convention.

2) compile the C units with a C compiler - I'd try the free Borland C++ compiler.

3) import the C functions in a Delphi unit. See one of the entries for the "external" keyword in the help index for an example (declare with stdcall here as well.)

4) link your Delphi app with the compiled .obj file using the {$L filename.obj} directive

See - this is the kind of support you get for trying Delphi. :)

Johannes Bjerregaard
Wednesday, January 09, 2002

Use VB.

Patrick Breitenbach
Wednesday, January 09, 2002

The jedi project have made it their goal in life to convert C APIs for Delphi use.

I'm sure you could get good help there:

http://www.delphi-jedi.org/

Ged Byrne
Thursday, January 10, 2002

Johannes Bjerregaard - Thanks for the outline.

Ignoring the 4 hours wasted late last night, learning that Delphi won't read MSVC-generated .OBJ files, I was able to get the Delphi tutorial app to access a trivial C-function in about an hour. (I dl'ed the Borland C-Compiler.) This is good.

I'm a bit peeved that 1) Delphi can't deal with MSVC object files and 2) This is not documented anywhere (I found the info in three year old USENET postings via Google).

Oh well. It's working now, and that's the important thing. Whew. This may be not so hard.

Thanks again to all the suggestions and helpful pointers (and tolerating a few of my rants :)

David Fischer
Thursday, January 10, 2002

A easy way to access C code in MSVC from Delphi is not trying to directly use the .obj, but use it thru a DLL (or thru a COM object).

It's very simple in Delphi and works perfectly (beware of Exception thru, don't let it propagate thru the DLL or COM object).

Con's: you may be back to DLL hell (or COM registry hell), but that doesn't seem to apply much to your case.

Robert Chevallier
Thursday, January 10, 2002

"A easy way to access C code in MSVC from Delphi is not trying to directly use the .obj, but use it thru a DLL (or thru a COM object). "

I saw that using a DLL should work, but I know less about making DLLs than I do about writing apps in Delphi :) I'll try that out later. I just was looking to do a quick proof-of-concept app. Now, I'm working on a simple calculator app, with the math inside C-functions, as a stepping stone to my ultimate goal.

David Fischer
Thursday, January 10, 2002

A, perhaps final, follow-up comment.

I figured out how to make a DLL with MSVC, and plug that into a Delphi6 project. It was not too difficult, and so I've tossed the command line BCC.

After about 20 hours of effort, I've got the immediate, hard problems figured out. I can now create a windows gui for my DOS app at my convenience.

Thanks for all the suggestions, help, encouragement, and random ideas!

- davef

David Fischer
Monday, January 14, 2002

Be careful, you may become addict to Delphi for Windows programming ;-)

Best of luck!

Robert Chevallier
Monday, January 14, 2002

*  Recent Topics

*  Fog Creek Home