Latest web development tutorials

ASP.NET AdRotator AdvertisementFile property

AdRotator control AdRotator control

Definition and Usage

AdvertisementFile property is used to set or return path contains advertisement data XML file.

grammar

<asp:AdRotator AdvertisementFile="path" runat="server" />

属性 描述
path 字符串值,规定包含广告数据的 XML 文件的位置。

可能的值:

  • 绝对路径(比如 http://www.w3cschool.cc/ads/bigad.xml)
  • 虚拟根路径(比如 ~/ads/bigad.xml)
  • 相对路径(比如 /ads/bigad.xml)


Examples

Examples

Declare a AdRotator (the "try" to view the XML instance document):

<form runat="server">
<asp:AdRotator id="ad1" runat="server"
AdvertisementFile="Ad1.xml" />
</form>

The demonstration >>


AdRotator control AdRotator control