Delphi使用VB6编写的ActiveX控件???

2008-04-11 12:27:08来源:互联网 阅读 ()

新老客户大回馈,云服务器低至5折

以下是我在VB6编写的ActiveX控件wjprnview.ocx,注册并导入Delphi5的开发环境后,Delphi生成的wjprnview_TLB.pas文件,其没有生成Twjprnview类,也没有注册面板上,无法使用,请问有方法吗?

unit wjprnview_TLB;

// ************************************************************************ //
// WARNING
// -------
// The types declared in this file were generated from data read from a
// Type Library. If this type library is explicitly or indirectly (via
// another type library referring to this type library) re-imported, or the
// ''''Refresh'''' command of the Type Library Editor activated while editing the
// Type Library, the contents of this file will be regenerated and all
// manual modifications will be lost.
// ************************************************************************ //

// PASTLWTR : $Revision: 1.88.1.0.1.0 $
// File generated on 2004-06-11 14:04:44 from Type Library described below.

// ************************************************************************ //
// Type Lib: E:\R95\wjprnview.ocx (1)
// IID\LCID: {D72F975E-72DC-11D6-923D-00E04CE8FBA7}\0
// Helpfile:
// DepndLst:
// (1) v2.0 stdole, (C:\WINNT\system32\stdole2.tlb)
// (2) v4.0 StdVCL, (C:\WINNT\system32\STDVCL40.DLL)
// ************************************************************************ //
{$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers.
interface

uses Windows, ActiveX, Classes, Graphics, OleServer, OleCtrls, StdVCL;

// *********************************************************************//
// GUIDS declared in the TypeLibrary. Following prefixes are used:
// Type Libraries : LIBID_xxxx
// CoClasses : CLASS_xxxx
// DISPInterfaces : DIID_xxxx
// Non-DISP interfaces: IID_xxxx
// *********************************************************************//
const
// TypeLibrary Major and minor versions
wjprnviewMajorVersion = 29;
wjprnviewMinorVersion = 0;

LIBID_wjprnview: TGUID = ''''{D72F975E-72DC-11D6-923D-00E04CE8FBA7}'''';

IID__prnview: TGUID = ''''{18CF3D27-3867-425A-BCE2-C754EE5FFE5A}'''';
DIID___prnview: TGUID = ''''{A47CD1BA-2E3A-4DCC-BE25-EA98C08DD135}'''';
CLASS_prnview: TGUID = ''''{D72F9760-72DC-11D6-923D-00E04CE8FBA7}'''';
type

// *********************************************************************//
// Forward declaration of types defined in TypeLibrary
// *********************************************************************//
_prnview = interface;
_prnviewDisp = dispinterface;
__prnview = dispinterface;

// *********************************************************************//
// Declaration of CoClasses defined in Type Library
// (NOTE: Here we map each CoClass to its Default Interface)
// *********************************************************************//
prnview = _prnview;


// *********************************************************************//
// Interface: _prnview
// Flags: (4560) Hidden Dual NonExtensible OleAutomation Dispatchable
// GUID: {18CF3D27-3867-425A-BCE2-C754EE5FFE5A}
// *********************************************************************//
_prnview = interface(IDispatch)
[''''{18CF3D27-3867-425A-BCE2-C754EE5FFE5A}'''']
procedure PsetA(var X: OleVariant; var Y: OleVariant; var color: OleVariant); safecall;
function TextWidth(var str: WideString): Single; safecall;
function TextHeight(var str: WideString): Single; safecall;
procedure PaintPicture(var pic: IDispatch; var pLeft: OleVariant; var pTop: OleVariant;
var pWidth: OleVariant; var pHeight: OleVariant); safecall;
procedure Refresh; safecall;
procedure StartDoc(zm: OleVariant; Pw: OleVariant; Ph: OleVariant); safecall;
function Get_DrawWidth: OleVariant; safecall;
procedure Set_DrawWidth(var Param1: OleVariant); safecall;
function Get_CurrentX: Single; safecall;
procedure Set_CurrentX(Param1: Single); safecall;
function Get_CurrentY: Single; safecall;
procedure Set_CurrentY(Param1: Single); safecall;
function Get_BackColor: OLE_COLOR; safecall;
procedure Set_BackColor(Param1: OLE_COLOR); safecall;

标签:

版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com
特别注意:本站所有转载文章言论不代表本站观点,本站所提供的摄影照片,插画,设计作品,如需使用,请与原作者联系,版权归原作者所有

上一篇:关于 MP3 中的 ID3V2 格式探讨。及我写的 ID3V2 读取源码。

下一篇:COM程序编写入门(全文-1)