我在IActiveFormX中新增属性HostIP,分别设置为
HostIP ReturnType: HRESULT Name=Value Type=BSTR* Modifier=[out,reval]
HostIP ReturnType: HRESULT Name=Value Type=BSTR Modifier=[in]
然后分别填写函数:
function TActiveFormX.Get_HostIP: WideString;
begin
Result := HostIP;
end;procedure TActiveFormX.Set_HostIP(const Value: WideString);
begin
if Value <> '' then
HostIP := Value;
end;在Asp的调用是:<OBJECT
classid="clsid:2A7E60BC-0901-49E6-AA39-068B5734DC6D"
codebase="TideTopo.ocx#version=1,0,0,0"
width=538
height=350
align=center
hspace=0
vspace=0
<PARAM NAME=″HostIP″ VALUE=″10.143.132.135″>
>
</OBJECT>
但我在运行的时候根本就没有执行procedure TActiveFormX.Set_HostIP(const Value: WideString);
也就是说参数HostIP没有传入到我的程序中,为什么?????
HostIP ReturnType: HRESULT Name=Value Type=BSTR* Modifier=[out,reval]
HostIP ReturnType: HRESULT Name=Value Type=BSTR Modifier=[in]
然后分别填写函数:
function TActiveFormX.Get_HostIP: WideString;
begin
Result := HostIP;
end;procedure TActiveFormX.Set_HostIP(const Value: WideString);
begin
if Value <> '' then
HostIP := Value;
end;在Asp的调用是:<OBJECT
classid="clsid:2A7E60BC-0901-49E6-AA39-068B5734DC6D"
codebase="TideTopo.ocx#version=1,0,0,0"
width=538
height=350
align=center
hspace=0
vspace=0
<PARAM NAME=″HostIP″ VALUE=″10.143.132.135″>
>
</OBJECT>
但我在运行的时候根本就没有执行procedure TActiveFormX.Set_HostIP(const Value: WideString);
也就是说参数HostIP没有传入到我的程序中,为什么?????
在privite 中声名 fhostip在读写方法中将hostip 换成fhostid 试试
中加断点调试,程序根本就没有进入该接收过程,其实以前我做通过,很久了,记不得怎样做的,但感觉大方向没有错,估计在某个细节上写错了,只是现在找不到错在哪里
添加属性,
声明
然后在方法程序中写
没什末呀
不行重新加一个属性,重做一次
^@^
classid="clsid:2A7E60BC-0901-49E6-AA39-068B5734DC6D"
codebase="TideTopo.ocx#version=1,0,0,0"
width=538
height=350
align=center
hspace=0
vspace=0
<PARAM NAME=″HostIP″ VALUE=″10.143.132.135″> //这里写错了
>
<PARAM NAME=″HostIP″ VALUE=″10.143.132.135″> //写到这
</OBJECT>
先谢啦
原来<PARAM NAME="HostIP″ VALUE=″10.143.132.135″>这句话有问题,引号格式不对,
我是从网上拷的这句话,在UltraEdit中居然什么看不出来,就在网页上仔细看还看得出来。