compling the 'Sunlight' tutorial under Borland 4.5

This is a discussion on compling the 'Sunlight' tutorial under Borland 4.5 within the Windows Programming forums, part of the Platform Specific Boards category; Is it possible to get the Sunlight Windows API tutorial to compile under Borland C++ 4.5? I can get the ...

  1. #1
    Registered User
    Join Date
    Aug 2001
    Posts
    380

    compling the 'Sunlight' tutorial under Borland 4.5

    Is it possible to get the Sunlight Windows API tutorial to compile under Borland C++ 4.5? I can get the Introduction section to compile OK, but then the rest I am unable to. Should I be looking elsewhere for tutorials compilable under Borland? If, so maybe you could suggest some.

  2. #2
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    I would have thought you could compile it, but from memory, you need to be sure you have done everything he says. A number of people who have had problems thought they new what they were doing a passed over something that they shouldn't have done.

    If you are confident you have not done that, tell me where you are, and what error you are getting and I'll try to see if I can see anything, (I don't use Borland, but I don't think that should matter).
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

  3. #3
    Registered User
    Join Date
    Aug 2001
    Posts
    380
    On the Quadratic Solver example I get a linking error that says "Unresolved external '_tcstod' referenced from module PRO1.C"

    To be sure it wasn't a typing error I copied and pasted it in to the editor and then tried to compile only to get the above error. Also, I get a bunch of prototype warnings, but I think these are caused by the order I have the functions in.

    Thank you for your attempt in helping me.

  4. #4
    the hat of redundancy hat nvoigt's Avatar
    Join Date
    Aug 2001
    Location
    Hannover, Germany
    Posts
    3,139
    As you cannot use UNICODE properly with Borland, you probably don't have the _T macros there. Look up the functions you have trouble with in the MSDN and replace them with the ANSI parts.
    That means you can't use UNICODE, but you can't use it in the GUI anyway with Borland.


    Example: replace the _tcstod with strtod:

    double strtod( const char *nptr, char **endptr );
    hth
    -nv

    She was so Blonde, she spent 20 minutes looking at the orange juice can because it said "Concentrate."

    When in doubt, read the FAQ.
    Then ask a smart question.

  5. #5
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    >>> you cannot use UNICODE properly with Borland

    I didn't know that. Is that still the case with Builder 5 and the like?
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

  6. #6
    Registered User
    Join Date
    Aug 2001
    Posts
    380
    As you cannot use UNICODE properly with Borland, you probably don't have the _T macros there.
    On the Sunlight tutorial it states that the TEXT macro is the equivalent of the _T macros.

  7. #7
    the hat of redundancy hat nvoigt's Avatar
    Join Date
    Aug 2001
    Location
    Hannover, Germany
    Posts
    3,139
    >>> you cannot use UNICODE properly with Borland

    >I didn't know that. Is that still the case with Builder 5 and the like?


    Yes. We are doing a GUI intensive project just now and I was to reevaluate all options. We use VC and will continue to do so, because all others doesn't fit our requirements. Borland C Builder and VB both have a wierd philosophy. Intern, strings are UNICODE. So you could argue that they support UNICODE. But: The class libraries for windows elements do not support UNICODE, so while you can hold strings with wide characters or utf-8, you can neither receive input via the GUI, nor have you any chance to show them to your user. Fat support. Who thought of this ? And on top, Borland support flat out lied to me about this phenomenon and when I asked how I would do it with the trial version, presales sent me to their paid support, because that's a coding matter. Sure. It's not presales, I'll just buy the stuff and trash it when I notice they lied. I guess you need a maximum IQ of 50 to work at Borland.

    I heard that Builder 6 and Delphi 6 will share one GUI library, so then it will be UNICODE. Delphi already has full support.

    Conclusion: Don't believe written mails from corporations support. If they want to sell a product, they will promise world peace, end of hunger and unlimited sex-slaves of your choice...
    hth
    -nv

    She was so Blonde, she spent 20 minutes looking at the orange juice can because it said "Concentrate."

    When in doubt, read the FAQ.
    Then ask a smart question.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. My new website
    By joeprogrammer in forum A Brief History of Cprogramming.com
    Replies: 19
    Last Post: 03-17-2006, 06:38 PM
  2. Cprog tutorial: Design Patterns
    By maes in forum C++ Programming
    Replies: 7
    Last Post: 10-11-2004, 01:41 AM
  3. Tutorial review
    By Prelude in forum A Brief History of Cprogramming.com
    Replies: 11
    Last Post: 03-22-2004, 08:40 PM
  4. Problem with tutorial (Vector class)
    By OdyTHeBear in forum C++ Programming
    Replies: 4
    Last Post: 12-18-2002, 01:49 PM
  5. My DirectInput tutorial....
    By jdinger in forum A Brief History of Cprogramming.com
    Replies: 1
    Last Post: 06-18-2002, 11:32 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21