Skip to main content
All docs
V23.2

ClipboardAccessPolicy.SuppressContainsOperations() Method

Applies a policy to suppress clipboard-access operations performed by DevExpress WinForms and WPF controls.

Namespace: DevExpress.Data.Utils

Assembly: DevExpress.Data.Desktop.v23.2.dll

NuGet Packages: DevExpress.Data.Desktop, DevExpress.ExpressApp.Win.Design

Declaration

public static void SuppressContainsOperations()

Remarks

DevExpress controls access the clipboard on demand (for example, the Rich Text Editor can check if the clipboard contains RTF or XML data). Call the SuppressContainsOperations on application startup to disable such operations within all DevExpress controls in the application.

using System;
using System.Windows.Forms;
using DevExpress.Data.Utils;

namespace DXApplication {
    internal static class Program {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main() {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            ClipboardAccessPolicy.SuppressContainsOperations();
            Application.Run(new Form1());
        }
    }
}

Read the following topic for additional information: Clipboard Access Policy.

See Also