<%@ Register TagPrefix="mob" Namespace="System.Web.UI.MobileControls" Assembly="S..." /> Explain A .NET Mobile Example With Details? <%@ Register TagPrefix="mob" Namespace="System.Web.UI.MobileControls" Assembly="S..." /> <%@ Register TagPrefix="mob" Namespace="System.Web.UI.MobileControls" Assembly="S..." />
Answers

Question and Answer:

  Home  .Net Mobile

⟩ Explain a .NET Mobile example with details?

Example:

<%@ Page Inherits="System.Web.UI.MobileControls.MyPage" %>

<%@ Register TagPrefix="mob" Namespace="System.Web.UI.MobileControls" Assembly="System.Web.Mobile" %>

<mob:Form runat="server">

<mob:Label runat="server">Hello World</mob:Label>

</mob:Form>

This is similar to a traditional ASP.NET webpage. The only difference being the tag mob which uses the System.Web.UI.MobileControls library.

Output for a WAP Enabled Mobile device:

<?xml version='1.0'?>

<!DOCTYPE wml PUBLIC '-//WAPFORUM//DTD WML 1.1//EN' 'http://www.wapforum.org/DTD/wml_1.1.xml'>

<wml>

<card>

<p>Hello World</p>

</card>

</wml>

Output for a Pocket PC:

<html>

<body>

<form id="ctrl1" name="ctrl1" method="post" action="example.aspx">

<div>Hello World</div>

</form>

</body>

</html>

 196 views

More Questions for you: