当前位置:首页
开发技术指南» 文章正文
    引言:
 

 

    摘要: pb编写的程序(后台asa),在生成exe以后,在一台没有装pb的机器上,怎么样在运行exe文件后,可以自己连接上数据库。还有我困惑的是,没有装pb的机器上哪里来的asa数据库?? 因为我见过一个东西后台是sqlserver的,它的那个东西是在另一台机器上必须装sqlserver,然后自己写了一个程序用来建库并且自动连接数据库(即在运行exe文件时自动连接)。 大侠们,多多指导啊。 ......
    摘要: 为什么sybase12.5在p4+win2000 sever的机器上安装不成功?我已经安装那个所谓的p4补丁。 ......


删除自己

在vb程序中  
  能否运行程序结束后,  
  自动删除自己。

NO.1   作者: JennyVenus

Private   Sub   DeleteMe()  
  -----------Create   bat-file---------------  
      Open   App.Path   +   "\Delself.bat"   For   Append   As   #1  
      Print   #1,   "@echo   off"  
      Print   #1,   ":try"  
      Print   #1,   "del   "   +   App.EXEName   +   ".exe"  
      Print   #1,   "if   exist   "   +   App.EXEName   +   ".exe   goto   try"  
      Print   #1,   "del   "   +   App.Path   +   "\Delself.bat"  
      Close  
  -----------Executr   it-------------------  
      Shell   App.Path   +   "\Delself.bat",   vbHide  
  End   Sub  
   
  At   Form_Unload   (or   at   the   end   of   Sub_Main)  
  just   call:DeleteMe  
 

NO.2   作者: GLAY

一个自杀程序      
   
  --------------------------------------------------------------------------------  
  下面的代码演示将一个程序在执行时将自己删除。  
  Sub   KillMe()  
      Path   =   App.Path  
      If   Right(Path,   1)   <>   "\"   Then   Path   =   Path   +   "\"  
      PathName   =   Path   +   App.EXEName   +   ".EXE"  
      BatName   =   Path   +   "1.bat"  
      Open   BatName   For   Output   As   #1  
      Print   #1,   ":START"  
      Print   #1,   "del   "   &   PathName  
        Print   #1,   "if   exist   "   &   BatName   &   "   GOTO   START"  
      Print   #1,   "del   "   &   BatName  
      Close   #1  
      Shell   BatName,   vbHide  
      End  
  End   Sub  
   
  注:   Print   #1,   "if   exist   "   &   BatName   &   "   GOTO   START"  
  这一句有的机加了不能把那个.bat删了,有的可以自己看看!


    摘要: 请问怎样改变ie收藏夹中收藏网站前面的ie图标为其他图标? ......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE