当 vb6 程序终止时卸载模块的是什么 [英] What unloads the modules when a vb6 program terminates

查看:20
本文介绍了当 vb6 程序终止时卸载模块的是什么的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

结束一个 vb6 程序的正确方法是做这样的事情:

The proper way to end a vb6 program is to do something like this :

Dim frm As Form
   For Each frm In Forms 
       Unload frm
   Next frm
   end

它负责处理表单,什么负责处理内存中的模块?

That takes care of forms, what takes care of modules in memory?

推荐答案

在 VB6 中不需要显式卸载模块.当最后一个表格被卸载时,它们会自动卸载.该语言根本不支持对标准模块的引用,只支持对其中定义的(全局)函数和变量的引用.由于您无法引用该模块,因此您也无法卸载它们.

There is no need to explicitly unload modules in VB6. They are unloaded automatically when the last form is unloaded. The language doesn't support references to standard modules at all, only to the (global) functions and variables defined therein. Since you can't reference the module, you can't unload them either.

这篇关于当 vb6 程序终止时卸载模块的是什么的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆