Class SaveOptions

Class SaveOptions

Namespace: Aspose.Tasks.Saving
Assembly: Aspose.Tasks.dll (25.2.0)

This is an abstract base class for classes that allow the user to specify additional options when saving a project into a particular format.

public abstract class SaveOptions : SimpleSaveOptions

Inheritance

objectSimpleSaveOptionsSaveOptions

Derived

HtmlSaveOptions, ImageSaveOptions, PdfSaveOptions, PrintOptions, SvgOptions, XamlOptions, XpsOptions

Inherited Members

SimpleSaveOptions.project, SimpleSaveOptions.SaveFormat, SimpleSaveOptions.TasksComparer, SimpleSaveOptions.TasksFilter, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Remarks

An instance of any derived class from SaveOptions class is passed to the stream Save or string Save overloads for the user to define custom options when saving a document.

Constructors

SaveOptions()

Initializes a new instance of the Aspose.Tasks.Saving.SaveOptions class.

protected SaveOptions()

SaveOptions(SaveOptions)

Initializes a new instance of the Aspose.Tasks.Saving.SaveOptions class.

protected SaveOptions(SaveOptions options)

Parameters

options SaveOptions

The Aspose.Tasks.Saving.SaveOptions to copy.

Properties

BarStyles

Gets or sets the list of the instances of the Aspose.Tasks.Visualization.BarStyle class that appear in project view.

public List<barstyle> BarStyles { get; set; }

Property Value

List<BarStyle&gt;

CustomPageSize

Gets or sets the custom page size in points (1 point = 1/72 of inch).

public SizeF CustomPageSize { get; set; }

Property Value

SizeF

DrawNonWorkingTime

Gets or sets a value indicating whether non-working time should be drawn (Default value is TRUE).

public bool DrawNonWorkingTime { get; set; }

Property Value

bool

EndDate

Gets or sets a date to finish rendering to.

public DateTime EndDate { get; set; }

Property Value

DateTime

FitContent

Gets or sets a value indicating whether row height should be increased to fit its content.

public bool FitContent { get; set; }

Property Value

bool

FitTimescaleToEndOfPage

Gets or sets whether a calendar section of a view should be rendered to the end (right side) of the last page. If value is false, calendar section is rendered exactly to EndDate, even there is an empty space on a page.

public bool FitTimescaleToEndOfPage { get; set; }

Property Value

bool

Gridlines

Gets or sets a list of Aspose.Tasks.Visualization.Gridline that appear in project view.

public List<gridline> Gridlines { get; set; }

Property Value

List<Gridline&gt;

IsPortrait

Gets or sets a value indicating whether the page orientation is portrait; returns false if the page orientation is landscape.

public bool IsPortrait { get; set; }

Property Value

bool

Remarks

Is not applicable when SaveOptions.PageSize == Visualization.PageSize.DefinedInView. In this case View.PageInfo.PageSettings.IsPortrait is used instead. Is not applicable when SaveOptions.CustomPageSize is set.

LegendDrawingOptions

Gets or sets a value which define how to render a legend. Default value is LegendDrawingOptions.OnEveryPage.

public LegendDrawingOptions LegendDrawingOptions { get; set; }

Property Value

LegendDrawingOptions

MarkCriticalTasks

Gets or sets a value indicating whether critical tasks should be displayed in red color (Default value is FALSE).

public bool MarkCriticalTasks { get; set; }

Property Value

bool

NonWorkingTimeColor

Gets or sets the non-working time color.

public Color NonWorkingTimeColor { get; set; }

Property Value

Color

PageCount

Gets or sets the number of pages of project.

public int PageCount { get; protected set; }

Property Value

int

PageSize

Gets or sets the size of page to be rendered (Default value is PageSize.A4).

public PageSize PageSize { get; set; }

Property Value

PageSize

PresentationFormat

Gets or sets the Aspose.Tasks.Saving.SaveOptions.PresentationFormat in which the document will be saved.

public PresentationFormat PresentationFormat { get; set; }

Property Value

PresentationFormat

RenderToSinglePage

Gets or sets a value indicating whether a project should be rendered to a single page when project is saved in graphical format. The page size will be changed so the rendered project can be fit on one page.

public bool RenderToSinglePage { get; set; }

Property Value

bool

RollUpGanttBars

Gets or sets a value indicating whether subtasks on the summary task bar should be marked. For subtasks, the Rollup field indicates whether information on the subtask Gantt bars will be rolled up to the summary task bar. For summary tasks, the Rollup field indicates whether the summary task bar displays rolled up bars. You must have the Rollup field for summary tasks set to Yes for any subtasks to roll up to them.

public bool RollUpGanttBars { get; set; }

Property Value

bool

Remarks

Is only applicable when Gantt chart view is rendered.

StartDate

Gets or sets the date to start rendering from.

public DateTime StartDate { get; set; }

Property Value

DateTime

TextStyles

Gets or sets the list of text styles that applied during rendering of a project view.

public List<textstyle> TextStyles { get; set; }

Property Value

List<TextStyle&gt;

Remarks

These styles override styles defined in GanttCharView.TextStyles.

Timescale

Gets or sets the Aspose.Tasks.Saving.SaveOptions.Timescale value which is used to control how timescale (if present) is rendered when project is saved to graphical format.

public Timescale Timescale { get; set; }

Property Value

Timescale

UseGradientBrush

Gets or sets a value indicating whether gradient brush should be used when rendering Gantt Chart.

public virtual bool UseGradientBrush { get; set; }

Property Value

bool

Remarks

Is only applicable when Gantt chart view is rendered.

View

Gets or sets a list of the view columns to render (Aspose.Tasks.Visualization.GanttChartColumn). If not set then task ids, task names, start and finish are rendered only. If both View and Aspose.Tasks.Saving.SaveOptions.ViewSettings properties are set, columns from View overrides columns from ViewSettings.

public ProjectView View { get; set; }

Property Value

ProjectView

ViewSettings

Gets or sets a view (Aspose.Tasks.Saving.SaveOptions.View) to render. You can use this options to explicitly specify which view should be saved to PDF, HTML or Image formats. If this property is set, Aspose.Tasks.Visualization.PresentationFormat property is ignored when project is saved. View should be from one of the following screen ((Aspose.Tasks.View.Screen)): (Gantt, TaskSheet, TaskUsage, ResourceSheet, ResourceUsage)

public View ViewSettings { get; set; }

Property Value

View

Exceptions

ArgumentException

When set method is called and instance of View class with not supported value of Screen property is provided.