各位朋友大家好!   我正在尝试把一个Delphi的控件转换成一个ActiveX控件。我需要用类型库编辑器添加一些属性和方法。对于一般数据类型问题能简单一些,但是如果我们需要引用一些特殊的数据类型,问题就出来了,比如:type
 PDirEntry = ^TDEntry;
 TDEntry = record
    ShortName: String;
    LongName: String;
    Imported: Boolean;
    Size, SizeJ: Int64;
    Path: String;
    Address,
    AddressJ: Integer;
    Depth: Byte;
    Number: Integer;
    Parent: PDirEntry;
    Files: PFileEntry;
    Order: Integer;
  end;    以上是一个记录类型声明和一个指向这个纪录类型的指针类型声明。如何在类型库(Type Library)里声明这两种数据类型的变量或者参数?    还有一些其他的类型也不好弄:~~~~~~~~~~~~~~~~~~~~~~~~~~~
typeTSearchRec = record  // 记录类型,请问怎么在类型库里声明?
  Time: Integer;
  Size: Integer;
  Attr: Integer;
  Name: TFileName;
  ExcludeAttr: Integer;
  FindHandle: THandle;
  FindData: TWin32FindData;PFileEntry = ^TFEntry;  // 一个指向数据类型的指针,请问怎么在类型库里声明?
TFEntry = record
  ShortName: String;
  LongName: String;
  Path: String;
  Imported: Boolean;
  Time: TDateTime;
  FileSize, FileSizeJ: Int64;
  SpaceReqOnDisc: Int64;
  Address: Integer;
  AddressJ: Integer;
  Attr: Integer;
  ResetArchiveBit: Boolean;
  DirRec: PDirEntry;  
  Next: PFileEntry;   
  Prev: Boolean;
  Buffer: PChar;
end;TDisc = record  // 又是一个记录类型,?
  Valid: Boolean;
  TotalBlocks: Cardinal;
  UsedBlocks: Cardinal;
  BlockLength: Cardinal;
  FirstCompleteSession,
  LastCompleteSession,
  DiscStatus,
  LastSession : Byte;
  DiscTypeCode: Word;
  DiscType: String;
  Eraseable: Boolean;
end;TScsiDeviceCapabilities = ( dcReadCDR,
                            dcReadCDRW,
                            dcReadMethod2,
                            dcReadDVD,
                            dcReadDVDR,
                            dcReadDVDRW,
                            dcReadDVDRAM,
                            dcReadDVDPLUSR,
                            dcReadDVDPLUSRW,
                            dcWriteCDR,
                            dcWriteCDRW,
                            dcWriteTest,
                            dcWriteDVDR,
                            dcWriteDVDRW,
                            dcWriteDVDRAM,
                            dcWriteDVDPLUSR,
                            dcWriteDVDPLUSRW,
                            dcWriteISRC,
                            dcUnderrunProtection );  // 枚举类型,这个容易!
TDeviceCapabilities = set of TScsiDeviceCapabilities; // 集合类型,请问如何做?TInquiryData = packed record // 压缩纪录类型,里面还有数组,如何做?
  PeripheralData: Byte;
  RMB: Byte;
  Version: Byte;
  Byte3: Byte;
  AdditionalLen: Byte;
  Byte5: Byte;
  Byte6: Byte;
  Byte7: Byte;
  VendorID: array[8..15] of char;
  ProductID: array[16..31] of char;
  ProductRev: array[32..35] of char;
  VendorSpecific: array[36..55] of char;
  Byte56: Byte;
  Reseverd: Byte;
  v1, v2, v3, v4: Word;
  OtherVData: array [0..62] of byte;
  DeviceType: ShortInt;  //PeripheralData
  Qulifier: Byte;
end;    还有三个类型我也不知道如何做:type
  A: Pointer;
  B: TWinControl;
  C: THandle;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   注意,“?”表示我不知道如何在类型库里声明的数据类型。   天啊,我的问题太多了。希望大家不要厌烦。请求帮助,非常感谢!   光明兄弟