Solved

Borland 5.02,  Win95, BWCC with "C" code problem

Posted on 1997-05-30
2
345 Views
Last Modified: 2013-12-03


I have Borland 5.02 running on a Win95 pc.

Can anyone tell me what I need to do to get a Borland Windows Control (like a "borbutton") to work with 32-bit "C" code, such as the comdlg32 example (\bc5\examples\win95\comdlg32)

When I add a simple Borland button or Borland shade to the About Box in the comdlg32 example, the about box dialog window refuses to open.

I've tried clicking the BWCC library option in the TargetExpert.
That didn't work.

I've tried using 'LoadLibrary("BWCC32.DLL")'
That didn't work.

I've tried using 'BWCCRegister'
That didn't work.

'BWCCGetVersion' returns 0x10200, as it should

Did Borland just screw something up?

Ultimately, I'm trying to convert a very large project originally programmed for Win32s with Borland 4.52 to run in Windows95.

0
Comment
Question by:RED6
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 15

Accepted Solution

by:
NickRepin earned 50 total points
ID: 1397773
Insert following code in WinMain function:

#include <bwcc.h>
int APIENTRY WinMain(HINSTANCE hInst,...)
{
     // Local declarations...

     BWCCRegister(hInst);

    // Your code...

}

Make sure 1) you are linking BWCC32.LIB
                  2) there are path to BWCC32.DLL

My \bc5\examples\win95\comdlg32 works fine with borland's button and shade.



0
 

Author Comment

by:RED6
ID: 1397774
Thanks.  I realized that when I used BWCCRegister before, I passed in the instance returned by the LoadLibrary("BWCC32.DLL") function which I had also tried, not the WinMain hInstance; and who knows what that did.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article shows how to make a Windows 7 gadget that accepts files dropped from the Windows Explorer.  It also illustrates how to give your gadget a non-rectangular shape and how to add some nifty visual effects to text displayed in a your gadget.…
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question