SPSolution.Deploy Method (DateTime, Boolean, Boolean)
Creates a timer job to deploy the language-neutral solution at a specified time.
Namespace: Microsoft.SharePoint.Administration
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No
Syntax
'Declaration
Public Sub Deploy ( _
dt As DateTime, _
globalInstallWPPackDlls As Boolean, _
force As Boolean _
)
'Usage
Dim instance As SPSolution
Dim dt As DateTime
Dim globalInstallWPPackDlls As Boolean
Dim force As Boolean
instance.Deploy(dt, globalInstallWPPackDlls, _
force)
public void Deploy(
DateTime dt,
bool globalInstallWPPackDlls,
bool force
)
Parameters
dt
Type: System.DateTimeA DateTime object containing the time to run the timer job.
globalInstallWPPackDlls
Type: System.BooleanNot used.
If true, then strong-named assemblies are installed in the GAC; if false, they are installed to the bin directory of the application.
force
Type: System.BooleanIf true, then a solution can be redeployed; if false, and the solution has already been deployed, an exception is raised.
Remarks
If a solution contains assemblies you can set the DeploymentTarget attribute in the solution manifest to GlobalAssemblyCache to place assemblies in the global assembly cache, or WebApplication to deploy them to the bin directory. If the attribute is not specified, assemblies are deployed to the bin directory by default.
When deploying assemblies using the object model, no warnings are issued that assemblies are being installed into the global assembly cache. (When using stsadm, the -allowgacdeploymentflag flag is required, and when using the user interface a warning is issued that assemblies are going to be installed into the global assembly cache.)
If you are running multiple jobs and the order in which they run is important, make sure that the specified times are sufficient for each job to complete before the next job is submitted. When multiple jobs are in the pool, the order in which they run is unpredictable.
To deploy a language package, see SPSolutionLanguagePack.