标题:[求助]如何使用GOTO命令跳到另一过程中
只看楼主
z_jzhao
Rank: 1
等 级:新手上路
帖 子:17
专家分:0
注 册:2007-9-29
 问题点数:0 回复次数:0 
[求助]如何使用GOTO命令跳到另一过程中

原程序大致情况如下:

Private Sub Command1_Click()
........
........
if x=1 then goto fail
.......
.......
if y=1 then goto fail
.......
.......
if z=1 then goto fail
......
.....
.....
......
fail:
.....
.....
.....
End sub
现在我想把这段放到另一个过程中:
if x=1 then goto fail
.......
if y=1 then goto fail
.......
if z=1 then goto fail
通过在执行中调用这个过程,但是在执行中,当遇到x=1,y=1,z=1时不能跳到command1过程中的fail标号处,来执行fail标号后的语句,请如何实现这样的跳转功能?

搜索更多相关主题的帖子: 如何 
2007-10-11 20:40



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-176865-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 1.371290 second(s), 7 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved