bindings/win32, RAS, error 632

Stewart Gordon smjg_1998 at yahoo.com
Thu Apr 9 14:57:16 PDT 2009


Leonid Krashenko wrote:
<snip>
>     RASENTRYNAME[100] buf;
>     buf.ptr.dwSize = RASENTRYNAME.sizeof;
>     uint entriesNum, length = buf.length*RASENTRYNAME.sizeof;

What value are you actually getting for RASENTRYNAME.sizeof?

And does buf.sizeof give the same value as 
buf.length*RASENTRYNAME.sizeof, as it should?

<snip>
> BUT the analogous DELPHI code works perfectly:
> Code:
> procedure getPhoneBookEntries(list: TStrings);
> var
>   BuffSize          : Integer;
>   Entries           : Integer;
>   Entry             : Array[1..MaxEntries] of TRasEntryName;
>   X,Result_         : Integer;
> begin
>   list.Clear;
>   Entry[1].dwSize:=SizeOf(TRasEntryName);
>   BuffSize:=SizeOf(TRasEntryName)*MaxEntries;
<snip>

Again, what values are you getting?

Stewart.



More information about the Digitalmars-d mailing list