我的一个Vb程序哪里错了?
来源:百度知道 编辑:UC知道 时间:2024/09/25 22:16:29
Private Sub munfileOpen_Click()
On Error GoTo ErrHander
ConmmenDialog1.Filter = "All Files(*.*)|*.*|TextFile(*.txt)|*.txt|Batch Files(*.bat)|*.bat"
CommenDialog1.FilterIndex = 2
CommenDialog1.ShowOpen
OpenFile (CommenDialog1.FileName)
Exit Sub
ErrHander:
Exit Sub
End Sub
编译出现下面的错误:
compiel erro:
sub or function not defined
原因出现什么地方?还请高手帮忙
On Error GoTo ErrHander
ConmmenDialog1.Filter = "All Files(*.*)|*.*|TextFile(*.txt)|*.txt|Batch Files(*.bat)|*.bat"
CommenDialog1.FilterIndex = 2
CommenDialog1.ShowOpen
OpenFile (CommenDialog1.FileName)
Exit Sub
ErrHander:
Exit Sub
End Sub
编译出现下面的错误:
compiel erro:
sub or function not defined
原因出现什么地方?还请高手帮忙
你这拼写错误太吓人了,CommonDialog能写成ConmmenDialog和CommenDialog,居然错的还不一样,汗。
拼错了
如果ConmmenDialog1没有写错的话那就是OpenFile()这个过程或函数没有定义
将所有的ConmmenDialog1改成ConmmonDialog1
你好像多出个end sub吧...