从你粘贴的这个代码来看错误在这里:
Private Sub Form_Resize()
Command1.Width = Form1.Width / 5 '设置按钮的宽度
Command1.Height = Form1.Height / 6 '设置按钮的高度
'* 这里,forml应该改成form1
Command1.Top = Forml.Height / 2 - Command1.Height / 2
'* 这里,Commandl应该改称Command1
Command1.Left = Form1.Width / 2 - Commandl.Width / 2
End Sub
Command1.Top = Forml.Height / 2 - Command1.Height / 2
Command1.Left = Form1.Width / 2 - Commandl.Width / 2
这两句有问题把1 写成 l 了
Private
Sub
Form_Load()
Dim
i
As
Integer
For
i
=
1
To
1000
List1.AddItem
CStr(i)
Next
i
End
Sub
是这个,
Private
Sub
Form_Load()
Dim
i
As
Integer,strTmp
as
string
For
i
=
1
To
1000
strTmp=str(i)
List1.AddItem
strTmp
Next
i
End
Sub
已改!!!祝你成功!!!
label2这个对象是多余的,删去即可
在窗体上输出文字请使用
print
"计算机等级考试"
==================================
如有问题,请补充,谢谢,我会第一时间解答
Private
Sub
Form_Load()
Dim
i
As
Integer
For
i
=
1
To
1000
List1.AddItem
CStr(i)
Next
i
End
Sub
测试通过