PrintDocument for WinForms | ComponentOne
C1.Win.PrintPreview.8 Assembly / C1.Win.C1Preview.Design Namespace / SampleC1PrintDocument Class / Cancel Property

In This Topic
    Cancel Property (SampleC1PrintDocument)
    In This Topic
    Gets or sets a value indicating whether to cancel the generation of the current document. Note that this property is useful only if C1.C1Preview.C1PrintDocument.DoEvents is set to true.
    Syntax
    'Declaration
     
    Public Property Cancel As Boolean
    public bool Cancel {get; set;}
    Remarks
    Setting this property to true can only be done while the current document is being generated (i.e. the value of the C1.C1Preview.C1PrintDocument.BusyState property is equal to C1.C1Preview.BusyStateEnum.Generating). An attempt to set this property to true when the document is not being generated will cause an exception.
    See Also