ASP.Net/Mobile Control/Panel — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
Admin (обсуждение | вклад) м (1 версия) |
(нет различий)
|
Текущая версия на 11:52, 26 мая 2010
Add control to mobile panel in code (VB.net)
<%@ Page
Inherits="System.Web.UI.MobileControls.MobilePage"
Language="VB"
%>
<%@ Register
TagPrefix="mobile"
Namespace="System.Web.UI.MobileControls"
Assembly="System.Web.Mobile"
%>
<script runat="server" language="VB">
Sub Page_Load(ByVal Sender as Object, ByVal E as EventArgs)
Dim MyLabel = New System.Web.UI.MobileControls.Label
Dim MyTB = New System.Web.UI.MobileControls.TextBox
MyLabel.ID = "lbl1"
MyLabel.Text = "The first label."
Pan1.Controls.Add(MyLabel)
MyTB.ID = "txt1"
MyTB.Text = "Enter some text!"
Pan1.Controls.Add(MyTB)
End Sub
</script>
<mobile:form
id="FirstPage"
runat="server">
<mobile:panel
id="Pan1"
runat="server"
/>
</mobile:form>
Add mobile label to mobile panel (VB.net)
<%@ Page
Inherits="System.Web.UI.MobileControls.MobilePage"
Language="VB"
%>
<%@ Register
TagPrefix="mobile"
Namespace="System.Web.UI.MobileControls"
Assembly="System.Web.Mobile"
%>
<script runat="server" language="VB">
</script>
<mobile:form
id="FirstPage"
runat="server">
<mobile:panel
id="Pan1"
runat="server"
forecolor="Red"
font-name="Arial"
alignment="right"
>
Raw text
<BR>
<B>More raw text</B>
<BR>
<mobile:label
id="lbl1"
runat="server"
text="Hello"
/>
</mobile:panel>
</mobile:form>