Click here to Skip to main content
15,912,021 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi im getting a problem in

XML FILE


XML
<?xml version="1.0" encoding="utf-8"?>
<Advertisements></Advertisements>
<Ad>
<ImageUrl>Adds\\CA.JPG</ImageUrl>
<NavigateUrl>http://www.google.com</NavigateUrl>
  <AlternateUrl>canada</AlternateUrl>
  <Impressions>25</Impressions>
  </Ad>
<Ad>
  <ImageUrl>Adds\\UK.jpg</ImageUrl>
  <NavigateUrl>http://www.gmail.com</NavigateUrl>
  <Alternate Text>United states</Alternate Text>
  <Impressions>25</Impressions>

</Ad>
Posted

The following are the properties of AdRotator control.

1. AdvertisementFile: The path of the XML file in which you store the information of images.
2. AlternateTextField: A data field to use instead of the Alt text for an advertisement.
3. ImageUrlField: The name of the image url field in which image path is store.
4. NavigateUrlField: The name of the navigate url field in which navigate url is store.
5. Target: The target property specify frame that display the content of the AdRotator. It has four type
_blank, _parent, _self, _top.

try to change:-
XML
<?xml version="1.0" encoding="utf-8"?>
<Advertisements></Advertisements>
<Ad>
<ImageUrl>Adds\\CA.JPG</ImageUrl>
<NavigateUrl>http://www.google.com</NavigateUrl>
  <AlternateUrl>canada</AlternateUrl>
  <Impressions>25</Impressions>
  </Ad>
<Ad>
  <ImageUrl>Adds\\UK.jpg</ImageUrl>
  <NavigateUrl>http://www.gmail.com</NavigateUrl>
  <Alternate Text>United states</Alternate Text>
  <Impressions>25</Impressions>
</Ad>


to

XML
<?xml version="1.0" encoding="utf-8"?>
<Advertisements>
<Ad>
<ImageUrl>Adds\\CA.JPG</ImageUrl>
<NavigateUrl>http://www.google.com</NavigateUrl>
  <AlternateUrl>canada</AlternateUrl>
  <Impressions>25</Impressions>
  </Ad>
<Ad>
  <ImageUrl>Adds\\UK.jpg</ImageUrl>
  <NavigateUrl>http://www.gmail.com</NavigateUrl>
  <Alternate Text>United states</Alternate Text>
  <Impressions>25</Impressions>
</Ad>
</Advertisements>
 
Share this answer
 
XML
<?xml version="1.0" encoding="utf-8"?>
<Advertisements>
<Ad>
<ImageUrl>Adds\\CA.JPG</ImageUrl>
<NavigateUrl>http://www.google.com</NavigateUrl>
  <AlternateUrl>canada</AlternateUrl>
  <Impressions>25</Impressions>
  </Ad>
<Ad>
  <ImageUrl>Adds\\UK.jpg</ImageUrl>
  <NavigateUrl>http://www.gmail.com</NavigateUrl>
  <Alternate Text>United states</Alternate Text>
  <Impressions>25</Impressions>

</Ad>

</Advertisements>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900