WebResourceAttribute.PerformSubstitution Property
Gets or sets a Boolean value that determines whether, during processing of the embedded resource referenced by the WebResourceAttribute class, other Web resource URLs are parsed and replaced with the full path to the resource.
Assembly: System.Web (in System.Web.dll)
Property Value
Type: System.Booleantrue if embedded resources are resolved during processing of the resource; otherwise, false. The default is false.
When a resource is streamed from the assembly to the response, references to other Web resources in the embedded resources can be resolved at this time, if the PerformSubstitution property is set to true.
The following code example demonstrates how to query the value of the PerformSubstitution property. In this example, the WebResourceAttribute attribute of the HTML file Help.htm is defined with the PerformSubstitution property set to true.
This code example is part of a larger example provided for the WebResourceAttribute class.
An example of an HTML Web resource that could be used in this example is shown next. Note that the WebResource syntax is used when you set the PerformSubstitution property to true for the resource.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<title>Included Help Page</title>
</head>
<body>
<div>
<img alt="help image" src=<% = WebResource("image1.jpg") %> />
Included help file.
</div>
</body>
</html>
Available since 2.0