Need help/calling external DLLs from VB6 
Author Message
 Need help/calling external DLLs from VB6

 hi to everybody,

I'm sort of new to the VB6.
I'm trying to call the DLL wriiten and compiled with the delphi 4.0

Every time I'm trying to call a procedure from that DLL
Visual Basic returns "Run time Error 453,  Can't find enty point ...."

How can I  fight it?

Thanks ,
 Dmitrii



Wed, 29 Oct 2003 09:25:37 GMT  
 Need help/calling external DLLs from VB6
It sounds like you could have a capitalization difference between the
exported DLL sub/function and what you have used in the DECLARE
statement in VB.   It may pay to recheck the names to ensure they
match (Win32 is sensitive to the case of exported & imported
sub/function names).

If all else fails, post the Delphi prototype and the VB declare
statement you are using, and maybe we can spot the problem.

Quote:

> hi to everybody,

>I'm sort of new to the VB6.
>I'm trying to call the DLL wriiten and compiled with the delphi 4.0

>Every time I'm trying to call a procedure from that DLL
>Visual basic returns "Run time Error 453,  Can't find enty point ...."

>How can I  fight it?

>Thanks ,
> Dmitrii

Lance
powerbasic Support

-------------------------------------------------------------------------
PowerBASIC, Inc.      | 800-780-7707 Sales | "We put the Power in Basic!"
316 Mid Valley Center | 831-659-8000 Voice | http://www.powerbasic.com



Wed, 29 Oct 2003 20:55:47 GMT  
 Need help/calling external DLLs from VB6
1) make sure that the Procedure in the DLL is StdCall

2) make sure that it is in the DLL's Exporst list

Here is a D4 DLL that exposes :-

       N& = Crc32( ByRef S$, ByVal Seed& )

============================================

library CRC32Util;

{uses SysUtils, Classes, Dialogs;}


                   Developed from VB code published by (TBA?)
                   Returns same value as DOS PKWARE Crc32
   24/6/00       - Checked use of Delphi String - seems OK
                   as no string manipulation takes place
*)

Var
Crc32Table : Array[0 ..255] of Integer ;

Procedure InitCrc32 ;
  Var
  Seed : LongWord ;
  L9 : LongWord ;
  L8 : LongWord ;
  CRC : LongWord ;
  TempCRC : LongWord ;
  Begin

  Seed := $EDB88320 ;

  For L9 := 0 To 255 Do
      Begin
      CRC := L9 ;          {Initiate CRC to counter variable }

      For L8 := 0 To 7 Do  {Now iterate through each bit in counter
byte}
          Begin
          { Right shift unsigned long 1 bit }
          TempCrc := Crc shr 1 ;

          { Now check if last CRC lost a set bit and then
            mix Crc32 checksum with Seed Value }
          If (Crc And 1) <> 0 Then
             Crc := TempCrc Xor Seed
          Else
             Crc := TempCrc ;
      End; {For L8}

      {Put Crc checksum value in the holding array }
      Crc32Table[ L9 ] := Crc ;
   End; {For L9}

End; {InitCrc32}

Function Crc32(Const S:String {!!}; Const Seed:Integer ):Integer
;StdCall;
  Var
  L9 : Integer ;
  ByteVal : Integer ;
  CRC : Integer ;
  AccValue : Integer ;
  Index : Integer ;
  Q : Integer ;
  Begin

  CRC := Seed ;

  { Iterate through the string that is to be checksum-computed }
  For L9 := 1 To Length( S ) Do
      Begin

      { Get ASCII value for the current character }
      ByteVal := Ord( S[L9] ) ;

      { Right shift an Unsigned Long 8 bits (last CRC) }
      AccValue := CRC shr 8 ;

      { Now select the right adding value from the holding table }
      Index := Crc And $FF ;         {Low byte of last CRC}
      Index := Index xor ByteVal ;

      { Now select the right adding value from the holding table}
      Q := Crc32Table[ Index ] ;

      { Then mix new Crc32 value with previous accumulated Crc32 value

Quote:
}

      CRC := AccValue xor Q ;
   End; {For L9}

   { Set function value the the new Crc32 checksum }
   Result := CRC ;

End; {AddCrc32}

Exports CRC32 ;

begin
  InitCrc32 ;
end.

============================================

On Fri, 11 May 2001 21:25:37 -0400, "Dmitrii Boldovsky"

Quote:

> hi to everybody,

>I'm sort of new to the VB6.
>I'm trying to call the DLL wriiten and compiled with the delphi 4.0

>Every time I'm trying to call a procedure from that DLL
>Visual basic returns "Run time Error 453,  Can't find enty point ...."

>How can I  fight it?

>Thanks ,
> Dmitrii



Wed, 05 Nov 2003 18:11:54 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Need help/ calling external DLL from VB6

2. Please Help! - Calling external DLL function with ByRef

3. Adding external modules to a project...need help calling them

4. COM DLL calling external non-COM DLL problem.

5. Calling external DLL gets error 48, unable to load DLL

6. HELP: Need help with wininet.dll calls!

7. Calling an external Program from VB6 with Parameters

8. Calling proceedure in external DLL

9. How to call external DLL procedures in VBA

10. Calling externals DLLs from VBscript

11. How to call external function from DLL

 

 
Powered by phpBB® Forum Software