By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,830 Members | 1,746 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,830 IT Pros & Developers. It's quick & easy.

Numeric format to a mobile textbox using xhtml & ASP.NET1.1

P: n/a
How to apply a numeric format to a textbox using xhtml? I know you have to
use the "-wap-input-format" style tag in css. I can get this to work in a
regular xhtml page, however, I've been unsuccessful in getting it to work in
asp.net 1.1

The following code has allowCustomAttributes set and works fine for labels,
but not for textboxes. This is because it is building span tags around the
control. I need to embed the class tag inside the input tag.

********
<HEAD>
<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
<meta content="C#" name="CODE_LANGUAGE">
<meta content="http://schemas.microsoft.com/Mobile/Page"
name="vs_targetSchema">
</HEAD>
<body>
<mobile:form id="Pedido" runat="server">
<mobile:Label id="Label1" runat="server"
StyleReference="bold">Cliente:</mobile:Label>
<mobile:TextBox id="txtCliente" runat="server"
StyleReference="numeric"></mobile:TextBox>
<mobile:Command id="cmdOK" runat="server"
Format="Link">OK</mobile:Command>
</mobile:form>
<mobile:stylesheet id="StyleSheet1" runat="server">
<mobile:Style Name="bold">
<DeviceSpecific>
<Choice Filter="isXHTML-mp" Font-Bold="True"> </Choice>
</DeviceSpecific>
</mobile:Style>
<mobile:Style Name="numeric">
<DeviceSpecific>
<Choice Filter="isXHTML-mp"> </Choice>
</DeviceSpecific>
</mobile:Style>
</mobile:stylesheet>
</body>
********

I previously define the device filter "isHTML-mp" of type Equality
Comparison with Preferred Rendering Type in Compare and xhtml-mp in Argument.
I have this information from the OpenWave Emulator in the OpenWave SDK 6.2.2.
I also try create the filter "isHTML-basic" for my Sony Ericsson T616 mobile
phone.

In the section:
<DeviceSpecific>
<Choice Filter="isXHTML-mp" ----HERE---- > </Choice>
</DeviceSpecific>

i try:
Format="NNN"
format="NNN"
wmlFormat="NNN"
wmlformat="NNN"
{-wap-input-format: "NNN"}
-wap-input-format: "NNN"

but when I write one of this options the browser in the emulator and the
phone gives a HTTP Error: 500 Internal Server Error

Thanks.
Jul 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Can somedy help me with this problem? Thanks!
Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.