您的位置:程序门 -> .net技术 -> vb.net



有谁能翻译???


[收藏此页] [打印本页]选择字色:背景色:字体:[][][]


有谁能翻译???
发表于:2007-06-24 21:16:23 楼主
procedure   tform1.setfocustodoc;  
  begin  
   if   webbrowser1.document   <>   nil   then  
    with   webbrowser1.application   as   ioleobject   do  
     doverb(oleiverb_uiactivate,   nil,   webbrowser1,   0,   handle,   getclientrect);  
  end;    

  除此之外,我还找到一种更简单的方法,这里一并列出:  

  if   webbrowser1.document   <>   nil   then  
   ihtmlwindow2(ihtmldocument2(webbrowser1.document).parentwindow).focus    

  刚找到了更简单的方法,也许是最简单的:  

  if   webbrowser1.document   <>   nil   then  
   ihtmlwindow4(webbrowser1.document).focus    

  还有,需要判断文档是否获得焦点这样来做:  

  if   ihtmlwindow4(webbrowser1.document).hasfocus   then    


有谁能把这翻译成vb.net啊?
发表于:2007-06-24 21:18:461楼 得分:0
哦买疙瘩。。。

dephi不会,vb不会。。。

建议先编译好,然后用反编译器转换。
发表于:2007-06-24 21:37:352楼 得分:0
自己对应一下,名字差距不是很大。
发表于:2007-06-25 08:11:293楼 得分:0
帮顶下!


快速检索

最新资讯
热门点击