DotNetGnat
Programmer
Hello All,
I have created a webservice and i have one function in it called GetData() which returns a dataset.
Now what i first tried is to consume this using ordinary webform controls and was successful without any problems...
then i tried to do the same thing using mobile controls...the page doesnt throw errors but i get a blank output...what am i doing wrong..here is my code...
MobileWebForm1.aspx
MobileWebForm1.aspx.vb
i used list mobile control...is it the correct one to use for holding the dataset??
-DNG
I have created a webservice and i have one function in it called GetData() which returns a dataset.
Now what i first tried is to consume this using ordinary webform controls and was successful without any problems...
then i tried to do the same thing using mobile controls...the page doesnt throw errors but i get a blank output...what am i doing wrong..here is my code...
MobileWebForm1.aspx
Code:
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="MobileWebForm1.aspx.vb" Inherits="MobileWebApp1.MobileWebForm1" %>
<%@ Register TagPrefix="mobile" Namespace="System.Web.UI.MobileControls" Assembly="System.Web.Mobile" %>
<HEAD>
<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
<meta name="vs_targetSchema" content="[URL unfurl="true"]http://schemas.microsoft.com/Mobile/Page">[/URL]
</HEAD>
<body Xmlns:mobile="[URL unfurl="true"]http://schemas.microsoft.com/Mobile/WebForm">[/URL]
<mobile:Form id="Form1" runat="server">
<mobile:Label id="lblName" runat="server">Enter Name:</mobile:Label>
<mobile:TextBox id="txtName" runat="server"></mobile:TextBox>
<mobile:Command id="cmdName" runat="server">Go</mobile:Command>
<mobile:List id="liststate" runat="server"></mobile:List>
</mobile:Form>
</body>
MobileWebForm1.aspx.vb
Code:
Private Sub cmdName_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdName.Click
Dim ws As New myservername.myservicename
txtName.Visible = False
lblName.Visible = False
cmdName.Visible = False
liststate.DataSource = ws.GetData(txtName.Text)
liststate.Visible = True
End Sub
i used list mobile control...is it the correct one to use for holding the dataset??
-DNG