共用方式為


My.Computer.Network Object 

Provides a property, event, and methods for interacting with the network to which the computer is connected.

Tasks

The following table lists examples of tasks involving the My.Computer.Network object.

To See

Upload a file

How to: Upload a File in Visual Basic

Download a file

How to: Download a File in Visual Basic

Check connection status

How to: Check Connection Status in Visual Basic

Determine if a remote computer is available

How to: Determine if a Remote Computer is Available in Visual Basic

Example

This example uploads the file Order.txt to https://www.cohowinery.com/uploads.

My.Computer.Network.UploadFile ( _
"C:\My Documents\Order.txt", _
"https://www.cohowinery.com/uploads.aspx")

Requirements

Namespace: Microsoft.VisualBasic.Devices

Class: Network

Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)

See Also

Reference

My.Computer.Network Object Members
My.Computer Object
My.Computer.Network.NetworkAvailabilityChanged Event
Microsoft.VisualBasic.Devices.Network