Solved

Why won't this work?  (cards.dll)

Posted on 1998-05-24
10
194 Views
Last Modified: 2008-03-03
i downloaded some source code today for cards.dll so I can learn about it and make something.  The source doesn't work properly though.  It says it can't find cards.dll!!  The zip is at http://www.huron.net/~jlewis/cards.zip  If anyone could help me out it would be appreciated :)
0
Comment
Question by:treyjeff
  • 3
  • 3
  • 2
  • +2
10 Comments
 
LVL 2

Expert Comment

by:rene100
ID: 1461485
hi treyjeff

first, i'm sorry but i can't find the zip, but remember to
copy the dll in the windows\system dir to use it
0
 
LVL 1

Expert Comment

by:tstrob
ID: 1461486
The dll is not shipped with the Zip-File, thats why you cannot find it.
Ask the programmer of the Sources.
0
 
LVL 5

Expert Comment

by:dirtdart
ID: 1461487
The dll is part of Windows, so the program should be able to find it.  I can't figure out why that particular project returned that error.  It did the same thing on my machine.  However, I found the almost exact same demo at http://www.pcworld.com/fileworld/file_description/frameset/0,1458,3718,00.html and it worked perfectly.  Give it a shot.
0
 
LVL 1

Expert Comment

by:tstrob
ID: 1461488
Try to register the dll

Open a Dosbox and enter:
  regsvr32 cards.dll

You have to be in the directory where the dll is located.

It is possibly that the regsvr32 has a different name on win95 (regserver or so... ??)
I am using NT4 (try to find regsvr in the system directory if the command does not work)
0
 
LVL 1

Author Comment

by:treyjeff
ID: 1461489
I get an error in the download file as well.  I tried regsvr32 as well and got an error when trying to register the dll.
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 4

Expert Comment

by:zsi
ID: 1461490
The file that you should be using is Cards32.dll

zsi
0
 
LVL 1

Author Comment

by:treyjeff
ID: 1461491
I have cards.dll and I tried to register it on my system but I got some eror message.
0
 
LVL 4

Accepted Solution

by:
zsi earned 30 total points
ID: 1461492
Great.  You should still use Cards32.dll in Windows95.  In WinNT, the 32bit library is named Cards.dll, but in Windows 95, it is 16bit.  This will lead to compatibility problems in your code if you run in both environments.

But, if you insist on using Cards.dll (a 16-bit file), you should know that the DLL is not an OLE server.  Therefore, it cannot be used with RegSvr.  Furthermore, the DLL exports only five functions.

You should use the following declarations in your code:

Private Declare Function cdtInit Lib "Cards.dll" (dx As Long, dy As Long) As Long
Private Declare Function cdtDrawExt Lib "Cards.dll" (ByVal hdc As Long, _
   ByVal X As Long, ByVal Y As Long, ByVal dx As Long, ByVal dy As Long, _
   ByVal ordCard As Long, ByVal iDraw As Long, ByVal cls As Long) As Long
Private Declare Function cdtDraw Lib "Cards.dll" (ByVal hdc As Long, ByVal X As Long, _
   ByVal Y As Long, ByVal iCard As Long, ByVal iDraw As Long, ByVal clr As Long) As Long
Private Declare Function cdtAnimate Lib "Cards.dll" (ByVal hdc As Long, ByVal iCardBack As Long, _
   ByVal X As Long, ByVal Y As Long, ByVal iState As Long) As Long
Private Declare Function cdtTerm Lib "Cards.dll" () As Long

0
 
LVL 1

Author Comment

by:treyjeff
ID: 1461493
I don't have cards32.dll on my system, why is that?  When I bought the computer it had W95 installed on it.  The only cards.dll file is exactly that one.
0
 
LVL 4

Expert Comment

by:zsi
ID: 1461494
Then use the Cards.dll, which is the library that the declarations that I provided refer to.  Just remember that if you get a "Bad DLL Calling Convention" or some other simliar error when you call to one of the functions, to change the long data types to integers.


0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

746 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now