<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
<head>
<meta http-equiv="cache-control" content="max-age=180,private" />
</head>
<card id="discuz_wml" title="CnPack Forum">
<p>#1 请问 CnActiveScriptWindow 如何使用？？<br /><small>我在CB6.0中，为什么我的 code 脚本并不执行？？ 谢谢各位指教<br />
 <br />
void __fastcall TForm1::Button1Click(TObject *Sender)<br />
{<br />
    WideString code=&quot;&quot;;<br />
    code+=L&quot;Function Func() \r\n&quot;;<br />
    code +=L&quot;Func = 12 \r\n&quot;;<br />
    code +=L&quot;msgbox Func \r\n&quot;;<br />
    code +=L&quot;End Function \r\n&quot;;<br />
<br />
    OleVariant s=this-&gt;CnActiveScriptWindow1-&gt;Execute(code);<br />
    if (!s.IsNull())<br />
    {<br />
        ShowMessage(String(s));<br />
    }<br />
}<br />
//-------------------------------------------------------- ..</small><br />
</p>
<p>#1 <a href="index.php?action=thread&amp;tid=2359&amp;start=0&amp;offset=497&amp;sid=otGKMO">&gt;&gt;Next Page</a><br />
<br />Forum:<a href="index.php?action=forum&amp;fid=8&amp;sid=otGKMO">CnPack IDE 专家包（CnW ...</a>
<br />Thread:<a href="index.php?action=thread&amp;tid=2359&amp;sid=otGKMO">请问 CnActiveScriptW ...</a>
<br />Next Thread:<a href="index.php?action=thread&amp;tid=2367&amp;sid=otGKMO">如何让不同版本的Delp ...</a>
</p>
<p align="center"><br /><a href="index.php?sid=otGKMO">Home</a><br />
<a href="index.php?action=login&amp;sid=">Login</a><br /><br />
<small>Powered by Discuz!</small></p>
</card>
</wml>