在VB6.0结束按钮的代码怎么写 编译后一点结束按钮程序就退出 在vb.net中用的是Me.Close()
PrivateSubCommand1_Click()DimZ,a,bAsDoubleDimmsg1AsIntegerZ=Text1.TextIfZ>0Thena=5227...
Private Sub Command1_Click()
Dim Z, a, b As Double
Dim msg1 As Integer
Z = Text1.Text
If Z>0 Then
a = 52273.084 + (2852.18 - Z) * Math.Cos(2.478014981)
b = 80923.558 + (2852.18 - Z) * Math.Sin(2.478014981)
Else
msg1 = MsgBox("输入数据有误,请重新输入!", 5+ 32 + 0, "数据检查")
If msg1=4 Then
Text1.Text=" "
Text1.SetFocus
Text1.Text = " "
End If
Text2.Text = a
Text3.Text = b
End Sub
还有一个问题就是怎样在vb6.0中实现 结束按钮的代码编写 在vb.net是用的Me.Close() 展开
Dim Z, a, b As Double
Dim msg1 As Integer
Z = Text1.Text
If Z>0 Then
a = 52273.084 + (2852.18 - Z) * Math.Cos(2.478014981)
b = 80923.558 + (2852.18 - Z) * Math.Sin(2.478014981)
Else
msg1 = MsgBox("输入数据有误,请重新输入!", 5+ 32 + 0, "数据检查")
If msg1=4 Then
Text1.Text=" "
Text1.SetFocus
Text1.Text = " "
End If
Text2.Text = a
Text3.Text = b
End Sub
还有一个问题就是怎样在vb6.0中实现 结束按钮的代码编写 在vb.net是用的Me.Close() 展开
4个回答
2013-08-25
展开全部
结束自身窗体:unload me结束其他窗体:unload 窗体名强制结束程序:End
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-08-25
展开全部
Private Sub Command1_Click()
Dim Z As Double, a As Double, b As Double
Dim msg1 As Integer
Z = Val(Text1.Text)
If Z>0 Then
a = 52273.084 + (2852.18 - Z) * Cos(2.478014981)
b = 80923.558 + (2852.18 - Z) * Sin(2.478014981)
Text2.Text = a
Text3.Text = b
Else
msg1 = MsgBox("输入数据有误,请重新输入!", VbOKCancel + VbQuestion, "数据检查")
If msg1=VbOK Then
Text1.Text=" "
Text1.SetFocus
End If
End Sub
'结束按钮:Private Sub Command2_Click() EndEnd Sub
Dim Z As Double, a As Double, b As Double
Dim msg1 As Integer
Z = Val(Text1.Text)
If Z>0 Then
a = 52273.084 + (2852.18 - Z) * Cos(2.478014981)
b = 80923.558 + (2852.18 - Z) * Sin(2.478014981)
Text2.Text = a
Text3.Text = b
Else
msg1 = MsgBox("输入数据有误,请重新输入!", VbOKCancel + VbQuestion, "数据检查")
If msg1=VbOK Then
Text1.Text=" "
Text1.SetFocus
End If
End Sub
'结束按钮:Private Sub Command2_Click() EndEnd Sub
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-08-25
展开全部
如果你是想退出程序直接在结束按钮添加代码:end
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-08-25
展开全部
end或者unload me
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询