Dim Y As Integer Private Sub Command_click( ) Dim X as integer x=1 y=1 call AA (Y+1) 'AA加了括号 需要等号 加了Call就不用等号了z=BB(x) 'z等于'y=z+x 'z=x+y '和函数BB是一样的print x, y, z end sub private sub AA(ByVal Z as integer )'这个是过程AAy=z+x z=x+y end sub private function BB(ByRef y as integer)'这个是函数BBy=y+1 BB=x+y end function