Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

WebView.DefaultBackgroundColor property

Applies to Windows and Windows Phone

Gets or sets the color to use as the WebView background when the HTML content does not specify a color.

Syntax


public Color DefaultBackgroundColor { get; set; }


<WebView DefaultBackgroundColor="predefinedColorName"/>
- or -
<WebView DefaultBackgroundColor="#rgb"/>
- or -
<WebView DefaultBackgroundColor="#argb"/>
- or -
<WebView DefaultBackgroundColor="#rrggbb"/>
- or -
<WebView DefaultBackgroundColor="#aarrggbb"/>
- or -
<WebView DefaultBackgroundColor="sc#scR,scG,scB"/>
- or -
<WebView DefaultBackgroundColor="sc#scA,scR,scG,scB"/>

XAML Values

predefinedColorName

One of the colors predefined by the Colors class (static properties), specified by the name of that property and color.

rgb

A three-character hexadecimal value. The first character specifies the color's R value, the second character specifies the G value, and the third character specifies the B value. For example, #00F.

argb

A four-character hexadecimal value. The first character specifies the color's A value, the second character specifies its R value, the third character specifies the G value, and the fourth character specifies its B value. For example, #F00F.

rrggbb

A six-character hexadecimal value. The first two characters specify the color's R value, the next two specify its G value, and the final two specify its B value. For example, #0000FF.

aarrggbb

An eight-character hexadecimal value. The first two characters specify the color's A value, the next two specify its R value, the next two specify its G value, and the final two specify its B value. For example, #FF0000FF.

scA

The color's ScA value as a value between 0 and 1. ScA is not exposed as a Color property directly.

scR

The color's ScR value as a value between 0 and 1. ScR is not exposed as a Color property directly.

scG

The color's ScG value as a value between 0 and 1. ScG is not exposed as a Color property directly.

scB

The color's ScB value as a value between 0 and 1. ScB is not exposed as a Color property directly.

Property value

Type: Color

The background color.

Requirements

Minimum supported client

Windows 8.1

Minimum supported server

Windows Server 2012 R2

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.UI.Xaml.Controls
Windows::UI::Xaml::Controls [C++]

Metadata

Windows.winmd

See also

WebView

 

 

Show:
© 2014 Microsoft