Forums     Knowledge Base     OfficeWriter Online     
 
 
This documentation is for
OfficeWriter v3.8.1
.NET Platform

View Docs for Another
Version or Platform

Programmer's Reference > WordApplication API > Shading

The Shading Object


This class is represents background shading for text, table cells, etc.

MS Word equivalent: Format menu > Borders and Shading... > Shading tab

The following example demonstrates how to get the shading object of a paragraph.



Examples:

[csharp]
WordApplication app = new WordApplication();
 Document doc = app.Create();
 Paragraph paragraph = doc.InsertParagraphAfter(null);
 Shading shad = paragraph.Shading;
[vbnet]
Dim app As New WordApplication()
 Dim doc As Document = app.Create()
 Dim paragraph As Paragraph = doc.InsertParagraphAfter(Nothing)
 Dim shad As Shading = paragraph.Shading


Shading Enumerations

NameDescription
Shading.ShadingPattern

Shading patterns that can be applied to an element



Shading Properties

Property Type Access Description
BackgroundColor Color read
write

Sets or returns a Color object that represents the background (fill) color

ForegroundColor Color read
write

Sets or returns a Color object that represents the foreground color

Pattern Shading.ShadingPattern read
write

Sets or returns a Shading.ShadingPattern object that represents the shading pattern used



This object does not have any methods defined.



Copyright 2007 © SoftArtisans, Inc. All Rights Reserved.