| T.R | Title | User | Personal Name
 | Date | Lines | 
|---|
| 1484.1 | Has Copy moved to another lib ? | GVPROD::MSTEINER |  | Wed Jun 04 1997 06:15 | 4 | 
|  |     Would you know where is "Copy" in Windows NT 4.0 ? (I've tried with
    gdi32.dll, but it tells me "can't find DLL entry point in gdi32" !)
    
    Michel.
 | 
| 1484.2 | Try Kernel32 | EVTSG8::TOWERS |  | Wed Jun 04 1997 07:27 | 6 | 
|  |     The main controversial aspect to NT4 was that Microsoft moved a lot of
    stuff from GDI to Kernel32, so that's the obvious place to look. There
    you'll find CopyMemoryLpToLp/Byte/Str etc.
    
    Cheers,
    Brian
 | 
| 1484.3 | No success... yet ! | GVPROD::MSTEINER |  | Wed Jun 04 1997 13:35 | 23 | 
|  |     Re .-1
    
    I didn't find CopyMemoryLpToLP in kernel32, nor in any other standard
    DLL (How did you manage to find this name ?). However, I find a
    CopyMemory (alias memcpy, alias RtlCopyMemory, alias RtlCopyMemory32)
    in the VC++ DLL's (MSVCRT*.DLL). Now, the problem is that I don't find
    how to declare/use it so that it does not generate a "bad DLL calling
    convention" !!! :-(
    
    Declare Sub memcpy Lib "msvcrtl.dll" _
       (dst As Any, src As Any, ByVal nCount as Long)
    
    Dim ACE1 As ACCESS_ALLOWED_ACE
    Dim pACE as long
    
    ' Get pACE from a call to GetACE
    ...
    Call memcpy(ACE1, ByVal pACE, Len(ACE1))
    
    It looks like the first two parameters are declaired in C as VOID. Is
    that the problem ? (VB docs says this translates to a Sub !).
    
    Michel.
 | 
| 1484.4 |  | EVTSG8::TOWERS |  | Thu Jun 05 1997 03:39 | 10 | 
|  |     Michel, CopyMemoryLpToLP came from a .tlb file (type library). I
    suspect that it is generated via aliasing something else. That is, the
    different flavours of CopyMemoryLPToxxx are generated by aliased
    declarations refering to the same underlying routine.
    
    I've used CopyMemory on a previous project I'll try and look up an
    example for you to put in tomorrow.
    
    Cheers,
    Brian
 | 
| 1484.5 | RtlMoveMemory does the job | GVPROD::MSTEINER |  | Thu Jun 05 1997 03:53 | 13 | 
|  |     To make a long story short...
    
    - I did not manage to get this "memcpy" work !
    - I found a "RtlMoveMemory" in kernel32.dll, and it does the job I want
      (yes, it works... finally... !).
    
    I'll have a look at these type library files anyway. I'm interested to
    better understand the subject...
    
    Thanks for your help, it's appreciated.
    
    Cheers,
    Michel.
 |