locked
WML11 Choice under devicespecific on ObjectList RRS feed

  • Question

  • User968307270 posted

    Hi,

    I am trying to template my mobile app for use with a WML based device (a nokia 6230i). The code I am using for the choice is as follows:

     

     
    			<DeviceSpecific>
    				<Choice Filter="isWML11" Xmlns="http://schemas.microsoft.com/mobile/chtml10template">
    					<ItemTemplate>
    								<asp:LinkButton Runat="server" CssClass="formLabel" CommandName="TemplateLink" ID="Linkbutton5">
    									<%# CType(Container, ObjectListItem)("description") %>
    								</asp:LinkButton><BR>
    								(<%# CType(Container, ObjectListItem)("project_name") %>)<BR>
    					</ItemTemplate>
    					<AlternatingItemTemplate>
    								<asp:LinkButton Runat="server" CssClass="formLabel" CommandName="TemplateLink" ID="Linkbutton6">
    									<%# CType(Container, ObjectListItem)("description") %>
    								</asp:LinkButton><BR>
    								(<%# CType(Container, ObjectListItem)("project_name") %>)<BR>
    					</AlternatingItemTemplate>
    				</Choice>
                            </DeviceSpecific>

     

    However, the code that is rendered isn't WML and I am getting a "Invalid Web Address" on my phone when i try to access an item generated by the objectlist control. Similarily I am getting a "Malformed URL" error in my openwave simulator.

    When I don't use "DeviceSpecific", everything works OK (the code generated is definately WML).

    Can anyone advise where I am going wrong?

    Thanks in advance for any advice.

    Tomás

    Monday, April 24, 2006 1:08 PM

All replies

  • User968307270 posted

    Hi,

    Figured out what I was doing wrong. Correct me if I'm wrong but it seems I needed to be using <Mobile:Command> instead of <asp:linkbutton> for the control to be rendered in the correct format (in this case WML).

    Thanks all anyway for any post you would have posted and any you might still post in response!!

    Tomás

     

    Tuesday, April 25, 2006 4:43 AM