Finally, its possible to advertise on your mobile phones. Mobile toolkit provides an add rotator control very similar to the ad rotator control for the Web. This Control will display the Advertisement in the random manner picking from the XML file.
Just Check out the Example.
Source Code:
// Source Code Starts
//Here is the XML File named myAd.xml
<?xml version="1.0"?>
<Advertisements>
<Ad>
<ImageUrl>http://urhostname:2526/smcreation.wbmp</ImageUrl>
<NavigateUrl>http://www.smcreation.com</NavigateUrl>
<AlternateText>Just Hello</AlternateText>
<KeywordFilter>Hello</KeywordFilter>
<Impressions>80</Impressions>
</Ad>
<Ad>
<ImageUrl>http://urhostname:2526/smentertainment.wbmp
</ImageUrl>
<NavigateUrl>http://www.smentertainment.com</NavigateUrl>
<AlternateText>Just Hi</AlternateText>
<KeywordFilter>Hi</KeywordFilter>
<Impressions>80</Impressions>
</Ad>
</Advertisements>
//And here is ur Main Code goes
<%@ Page Inherits="System.Web.UI.MobileControls.MobilePage" Language="C#" %>
<%@ Register TagPrefix="mobile"
Namespace="System.Web.UI.MobileControls"
Assembly="System.Web.Mobile" %>
<mobile:Form runat="server" ID="Form1" NAME="Form1">
<mobile:AdRotator runat="server" AdvertisementFile="myAd.xml" ID="Adrotator1" NAME="Adrotator1"/>
<mobile:Label runat="server" ID="Label1" NAME="Label1">
Its Gonna Change on Refresh
</mobile:Label>
</mobile:Form>
// Source Code End