Share via


SPVirtualServerConfig.EmailInsertsEnabled property

NOTE: This API is now obsolete.

Obsolete. The e-mail insert feature has been removed. The EmailInsertsEnabled property always returns false, and setting the property has no effect. (In Windows SharePoint Services 2.0, the EmailInsertsEnabled property was used to get or set a Boolean value that specified whether document libraries on the virtual server can accept e-mail attachments, and is maintained for backward compatibility.)

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
<ObsoleteAttribute("E-Mail Inserts have been removed from WSS V3.")> _
Public Property EmailInsertsEnabled As Boolean
    Get
    Set
'Usage
Dim instance As SPVirtualServerConfig
Dim value As Boolean

value = instance.EmailInsertsEnabled

instance.EmailInsertsEnabled = value
[ObsoleteAttribute("E-Mail Inserts have been removed from WSS V3.")]
public bool EmailInsertsEnabled { get; set; }

Property value

Type: System.Boolean
true if document libraries can accept e-mail attachments; otherwise, false.

Remarks

Setting the value of the EmailInsertsEnabled property requires calling the SPPropertyBag.Update method to commit the property changes to the database.

Examples

The following code example enables e-mail attachments for document libraries on the specified virtual server.

Dim globalAdmin As New SPGlobalAdmin()

Dim uri As New System.Uri("http://Server_Name")
Dim vServer As SPVirtualServer = globalAdmin.OpenVirtualServer(uri)

Dim vConfig As SPVirtualServerConfig = vServer.Config
vConfig.EmailInsertsEnabled = True

vConfig.Properties.Update()

globalAdmin.Close()
SPGlobalAdmin globalAdmin = new SPGlobalAdmin();

System.Uri uri = new System.Uri("http://Server_Name");
SPVirtualServer vServer = globalAdmin.OpenVirtualServer(uri);

SPVirtualServerConfig vConfig = vServer.Config;
vConfig.EmailInsertsEnabled = true;

vConfig.Properties.Update();

globalAdmin.Close();

See also

Reference

SPVirtualServerConfig class

SPVirtualServerConfig members

Microsoft.SharePoint.Administration namespace