Peristiwa
17 Mac, 9 PTG - 21 Mac, 10 PG
Sertai siri perjumpaan untuk membina penyelesaian AI berskala berdasarkan kes penggunaan dunia sebenar dengan rakan pembangun dan pakar.
Daftar sekarangPelayar ini tidak lagi disokong.
Naik taraf kepada Microsoft Edge untuk memanfaatkan ciri, kemas kini keselamatan dan sokongan teknikal yang terkini.
Transfers control to a Function
, Sub
, or dynamic-link library (DLL) procedure.
[ Call ] procedureName [ (argumentList) ]
Part | Description |
---|---|
procedureName |
Required. Name of the procedure to call. |
argumentList |
Optional. List of variables or expressions representing arguments that are passed to the procedure when it is called. Multiple arguments are separated by commas. If you include argumentList , you must enclose it in parentheses. |
You can use the Call
keyword when you call a procedure. For most procedure calls, you aren’t required to use this keyword.
You typically use the Call
keyword when the called expression doesn’t start with an identifier. Use of the Call
keyword for other uses isn't recommended.
If the procedure returns a value, the Call
statement discards it.
The following code shows two examples where the Call
keyword is necessary to call a procedure. In both examples, the called expression doesn't start with an identifier.
Sub TestCall()
Call (Sub() Console.Write("Hello"))()
Call New TheClass().ShowText()
End Sub
Class TheClass
Public Sub ShowText()
Console.Write(" World")
End Sub
End Class
.NET maklum balas
.NET ialah projek sumber terbuka. Pilih pautan untuk memberikan maklum balas:
Peristiwa
17 Mac, 9 PTG - 21 Mac, 10 PG
Sertai siri perjumpaan untuk membina penyelesaian AI berskala berdasarkan kes penggunaan dunia sebenar dengan rakan pembangun dan pakar.
Daftar sekarang