CARDS32.DLL needs to be modified for VB 4.0 32 Bit 
Author Message
 CARDS32.DLL needs to be modified for VB 4.0 32 Bit

Dear All,
                When applying this code of CARDS.DLL in VB 4.0  16 Bit it
works 'cause it's CARDS.DLL  16 Bit
so may anybody help me how to modify it to work with VB 4.0  32 Bit

* MODULE1.BAS (global module) *
  'Delarations and utilities for using CARDS.DLL

  'Actions for CdtDraw/Ext
  ' use in the nDraw field
  Global Const C_FACES = 0
  Global Const C_BACKS = 1
  Global Const C_INVERT = 2

  'Card Numbers
  ' use in the nCard field
  'from 0 to 51 [Ace (club,diamond,heart,spade), Deuce, ... , King]

  'Card Backs
  ' use in the nCard field
  ' CAUTION: when nCard > 53 then nDraw must be = 1 (C_BACKS)
  Global Const crosshatch = 53
  Global Const weave1 = 54
  Global Const weave2 = 55
  Global Const robot = 56
  Global Const flowers = 57
  Global Const vine1 = 58
  Global Const vine2 = 59
  Global Const fish1 = 60
  Global Const fish2 = 61
  Global Const shells = 62
  Global Const castle = 63
  Global Const island = 64
  Global Const cardhand = 65
  Global Const UNUSED = 66
  Global Const THE_X = 67
  Global Const THE_O = 68

  'Initialization
  ' call before anything else. Returns the default
  ' width and height for the cards, in pixels.
  Declare Function CdtInit Lib "CARDS.DLL" (nWidth As Integer, nHeight As
Integer) As Integer

  'CdtDraw used to draw a card with the default size
  'at a specified location in a form, picture box or whatever.
  'It can draw any of the 52 faces an 13 different Back designs,
  'as well as pile markers such as the X and O. Cards can also
  'be drawn in the negative image, eg to show selection.
  'xOrg = x origin in pixels
  'yOrg = y origin in pixels
  'nCard = one of the Card Back constants or a card number 0 to 51
  'nDraw = one of the Action constants
  'nColor = The highlight color
  Declare Function CdtDraw Lib "CARDS.DLL" (ByVal hDC As Integer, ByVal xOrg
As Integer,
  ByVal yOrg As Integer, ByVal nCard As Integer, ByVal nDraw As Integer,
ByVal nColor&)
  As Integer

  'CdtDrawExt used to draw a card in any size
  'Much the same as CdtDraw, but you can specify the height & width
  'of the card, as well as location.
  'nWidth = Width of card in pixels
  'nHeight = Height of card in pixels.
  Declare Function CdtDrawExt Lib "CARDS.DLL" (ByVal hDC As Integer, ByVal
xOrg As Integer,
  ByVal yOrg As Integer, ByVal nWidth As Integer, ByVal nHeight As Integer,
ByVal nCard
  As Integer, ByVal nDraw As Integer, ByVal nColor&) As Integer

  'CdtTerm should be called when the program terminates.
  ' Primarily it releases memory back to Windows.
  Declare Function CdtTerm Lib "CARDS.DLL" () As Integer * MODULE1.BAS
(global module) *
  'Delarations and utilities for using CARDS.DLL

  'Actions for CdtDraw/Ext
  ' use in the nDraw field
  Global Const C_FACES = 0
  Global Const C_BACKS = 1
  Global Const C_INVERT = 2

  'Card Numbers
  ' use in the nCard field
  'from 0 to 51 [Ace (club,diamond,heart,spade), Deuce, ... , King]

  'Card Backs
  ' use in the nCard field
  ' CAUTION: when nCard > 53 then nDraw must be = 1 (C_BACKS)
  Global Const crosshatch = 53
  Global Const weave1 = 54
  Global Const weave2 = 55
  Global Const robot = 56
  Global Const flowers = 57
  Global Const vine1 = 58
  Global Const vine2 = 59
  Global Const fish1 = 60
  Global Const fish2 = 61
  Global Const shells = 62
  Global Const castle = 63
  Global Const island = 64
  Global Const cardhand = 65
  Global Const UNUSED = 66
  Global Const THE_X = 67
  Global Const THE_O = 68

  'Initialization
  ' call before anything else. Returns the default
  ' width and height for the cards, in pixels.
  Declare Function CdtInit Lib "CARDS.DLL" (nWidth As Integer, nHeight As
Integer) As Integer

  'CdtDraw used to draw a card with the default size
  'at a specified location in a form, picture box or whatever.
  'It can draw any of the 52 faces an 13 different Back designs,
  'as well as pile markers such as the X and O. Cards can also
  'be drawn in the negative image, eg to show selection.
  'xOrg = x origin in pixels
  'yOrg = y origin in pixels
  'nCard = one of the Card Back constants or a card number 0 to 51
  'nDraw = one of the Action constants
  'nColor = The highlight color
  Declare Function CdtDraw Lib "CARDS.DLL" (ByVal hDC As Integer, ByVal xOrg
As Integer,
  ByVal yOrg As Integer, ByVal nCard As Integer, ByVal nDraw As Integer,
ByVal nColor&)
  As Integer

  'CdtDrawExt used to draw a card in any size
  'Much the same as CdtDraw, but you can specify the height & width
  'of the card, as well as location.
  'nWidth = Width of card in pixels
  'nHeight = Height of card in pixels.
  Declare Function CdtDrawExt Lib "CARDS.DLL" (ByVal hDC As Integer, ByVal
xOrg As Integer,
  ByVal yOrg As Integer, ByVal nWidth As Integer, ByVal nHeight As Integer,
ByVal nCard
  As Integer, ByVal nDraw As Integer, ByVal nColor&) As Integer

  'CdtTerm should be called when the program terminates.
  ' Primarily it releases memory back to Windows.
  Declare Function CdtTerm Lib "CARDS.DLL" () As Integer



Sun, 08 Apr 2001 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. CARDS32.DLL needs to be modified for VB 4.0 32 Bit

2. CARDS32.DLL needs to be modified for VB 4.0 32 Bit

3. CARDS32.DLL needs to be modified for VB 4.0 32 Bit

4. TIME TO WIN 32-Bit DLL for VB 4.0 32-Bit or Higher (VB5)

5. Calling a user-written 32-bit dll from 32-bit vb 4.0

6. VB 4.0 32 Bit Version.dll example needed - use functions in version dll.htm (1/1)

7. VB 4.0 32 Bit Version.dll example needed - use functions in version dll.htm (0/1)

8. Will VB 3.0 DLLs Overwrite VB 4.0 (32 bit) DLLs

9. CARDS.DLL 16 Bit doesn't work on VB 4.0 32 Bit

10. CARDS.DLL 16 Bit doesn't work on VB 4.0 32 Bit

11. CARDS.DLL 16 Bit doesn't work on VB 4.0 32 Bit

12. CARDS.DLL 16 Bit doesn't work on VB 4.0 32 Bit

 

 
Powered by phpBB® Forum Software