Visual Basic 2005 in a Nutshell (In a Nutshell (OReilly))

IsNetworkDeployed Property

Location

My.Application.IsNetworkDeployed

Syntax

Dim result As Boolean = My.Application.IsNetworkDeployed

Description

The IsNetworkDeployed property indicates whether the application was deployed from a network using ClickOnce (TRue) or not (False).

Usage at a Glance

  • This property is read-only.

  • This property is only valid in Windows Forms and console applications.

  • Always use this property before using the My.Application.Deployment property. The Deployment property is only valid when the IsNetworkDeployed property is true.

Example

The following example attempts to update the application, but only if it is a ClickOnce installation deployed over a network.

If (My.Application.IsNetworkDeployed = True) Then _ My.Application.Deployment.Update( )

Related Framework Entries

  • Microsoft.VisualBasic.ApplicationServices.ConsoleApplicationBase.,IsNetworkDeployed Property

See Also

Application Object, Deployment Property

Категории