Guest:
Register
|
Login
|
Member List
|
Search
|
Statistics
|
FAQ
Language
----------
Simplifed Chinese
Traditional Chinese
English
CnPack Forum
»
技术板块灌水区
» [急]把Delphi代码中的方法导出,作为脚本中的事件
‹‹ Last Thread
|
Next Thread ››
Poll
Trade
Reward
Activity
Printable Version
|
Email to Friend
|
Subscription
|
Favorites
Subject: [急]把Delphi代码中的方法导出,作为脚本中的事件
rise
普通灌水员
UID 40734
Digest Posts 0
Credits 92
Posts 33
点点分 92
Reading Access 10
Registered 2008-8-4
Status Offline
#1
Post at 2009-3-25 17:15
Profile
|
Blog
|
P.M.
[急]把Delphi代码中的方法导出,作为脚本中的事件
如题。脚本是RemObject Pascal script。
尝试过用AddMethod(Self, @TForm1.TestEvent, 'procedure TestEvent(Sender:
TObject);
然后在脚本中用btn.OnClick := @TestEvent;
编译提示"unKown dentifier TestEvent"。找了好几天了,都没有找到例子,请懂的告知一下,谢谢了
Passion
(LiuXiao)
管理员
UID 359
Digest Posts
19
Credits 6838
Posts 3591
点点分 6838
Reading Access 102
Registered 2004-3-28
Status Offline
#2
Post at 2009-3-25 23:06
Profile
|
Blog
|
P.M.
CnWizards中还没有以这种方式用到脚本的动态事件,还需要研究才能知道。
rise
普通灌水员
UID 40734
Digest Posts 0
Credits 92
Posts 33
点点分 92
Reading Access 10
Registered 2008-8-4
Status Offline
#3
Post at 2009-3-25 23:47
Profile
|
Blog
|
P.M.
那用脚本创建按钮后,这个按钮的事件怎么去绑定呢?这个应该是脚本本身就有方法支持的
Passion
(LiuXiao)
管理员
UID 359
Digest Posts
19
Credits 6838
Posts 3591
点点分 6838
Reading Access 102
Registered 2004-3-28
Status Offline
#4
Post at 2009-3-26 12:27
Profile
|
Blog
|
P.M.
看看另一帖子?zjy提到的的FormDemo1.pas里头就有。
Poll
Trade
Reward
Activity
CnPack Forum
CnPack English Forum
> CnWizards IDE Wizards
> CVSTracNT
> Announcements & Others
All times are GMT++8, the time now is 2024-11-24 11:21
Powered by
Discuz!
5.0.0
© 2001-2006
Comsenz Inc.
Processed in 0.007783 second(s), 7 queries , Gzip enabled
TOP
Clear Cookies
-
Contact Us
-
CnPack Website
-
Archiver
-
WAP
Member's CP Home
Edit Profile
Credits Transaction
Public User Groups
Buddy List
Main
Page Views
User Agents
Posts History
Top Forums
Top Threads
Post Ranking
Credit Ranking
Online Time
Team
Moderation Stats