PROGRAM USING ADROTATOR COMPONENT

DEFAULT.ASPX FILE:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
    <meta http-equiv="refresh" content="1"/>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <asp:AdRotator ID="AdRotator1" runat="server" AdvertisementFile ="~/ads.xml"  />
    </div>
    </form>
   
</body>

</html>

DEFAULT2.ASPX.FILE

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default2.aspx.vb" Inherits="Default2" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
   
    </div>
    </form>
</body>

</html>

ADS.XML FILE:
<?xml version="1.0" encoding="utf-8" ?>
<Advertisements>
  <Ad>
    <ImageUrl>ready.png</ImageUrl>
    <TargetUrl>default2.aspx </TargetUrl>
    <AlternateText>ready is not available</AlternateText>
    <Keyword>READY</Keyword>
    <Impressions>2</Impressions>
  </Ad>
  <Ad>
    <ImageUrl>wait.png</ImageUrl>
    <TargetUrl>default2.aspx </TargetUrl>
    <AlternateText>wait picture is  not available</AlternateText>
    <Keyword>WAIT</Keyword>
    <Impressions>3</Impressions>
  </Ad>
  <Ad>
    <ImageUrl>go.png</ImageUrl>
    <TargetUrl>default2.aspx </TargetUrl>
    <AlternateText>Go picture is  not available</AlternateText>
    <Keyword>GO</Keyword>
    <Impressions>2</Impressions>
  </Ad>
  <Ad>
    <ImageUrl>see.png</ImageUrl>
    <TargetUrl>default2.aspx </TargetUrl>
    <AlternateText>see picture is  not available</AlternateText>
    <Keyword>SEE</Keyword>
    <Impressions>4</Impressions>
  </Ad>

</Advertisements>



No comments:

Post a Comment