Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize

RelativePath Property (VCWebDeploymentTool)

Visual Studio .NET 2003

The path relative to the virtual directory to which the primary project output is copied when deployment occurs.

[Visual Basic .NET]
Public Property RelativePath() As String
[Visual Basic 6]
Property Get RelativePath() As String
Property Let RelativePath( _
   ByVal NewValue As String _
) 
[C++]
HRESULT __stdcall get_RelativePath(
   /* [out, retval] */ BSTR* retVal
);
HRESULT __stdcall put_RelativePath(
   /* [in] */ BSTR NewValue
);
[C#]
public string RelativePath {get; set;}
[JScript .NET]
public function get RelativePath() : String
public function set RelativePath(
   NewValue : String
)

Remarks

By default, the relative path is bin.

Example

The following sample code uses the RelativePath property in the development environment:

' add reference to Microsoft.VisualStudio.VCProjectEngine
Imports EnvDTE
Imports Microsoft.VisualStudio.VCProjectEngine
Public Module Module1
   Sub Main()
      Dim prj As VCProject
      Dim cfgs, tools As IVCCollection
      Dim cfg As VCConfiguration
      Dim wdt As VCWebDeploymentTool
      prj = DTE.Solution.Projects.Item(1).Object
      cfgs = prj.Configurations
      cfg = cfgs.Item(1)
      wdt = cfg.Tools("VCWebDeploymentTool")
      wdt.RelativePath = "relativePathName"
      MsgBox(wdt.RelativePath)
   End Sub
End Module

See Samples for Project Model Extensibility for information on how to compile and run this sample.

See Also

VirtualDirectoryName Property | PrimaryOutput Property | RelativePath Property

Applies To: VCWebDeploymentTool Object

Show:
© 2015 Microsoft