1.vb多行注释的方法: 在菜单栏空白地方右键,勾选"编辑" 新出来的菜单面板有个图标(在一个手的旁边),是注释代码块 选择多行代码,点一下这个"注释代码块"就行了,右边紧挨的是取消注释代码块
2.form1.winstate=1 表示该窗口是最小化状态
3.Private Sub RichTextBox1_MouseDown(Button As Integer,Shift As Integer,X As Single,Y As Single)
If Button = 2 Then '如果是鼠标右键按下时
Form3.PopupMenu popmenu, 0, X, Y '弹出右键菜单
End If
End Sub
采用上面代码可以弹出popup菜单,注意popupmenu不是名字,是属性。popmenu是菜单的名字。但如果后面加坐标则弹出位置不对,该为 Form3.PopupMenu popmenu则弹出位置正确。