H
hon123456
Dear all,
I am new to .net environment. I have a code example as
follows:
<WebMethod()> Public Function GetCities(ByVal State As String) As
DataSet
Dim dsn As String =
"server=<servername>;database=<databasename>;uid=sa;pwd="
Dim myconnection As SqlConnection = New SqlConnection(dsn)
Dim mycommand As SqlDataAdapter = New SqlDataAdapter("select
city from citystate where state='" & State & "' order by city",
myconnection)
Dim ds As New DataSet()
mycommand.Fill(ds, "city")
Return ds
End Function
Could someone elaborate what is the use and meaning of "city"
in mycommand.Fill (ds."city")
I am new to .net environment. I have a code example as
follows:
<WebMethod()> Public Function GetCities(ByVal State As String) As
DataSet
Dim dsn As String =
"server=<servername>;database=<databasename>;uid=sa;pwd="
Dim myconnection As SqlConnection = New SqlConnection(dsn)
Dim mycommand As SqlDataAdapter = New SqlDataAdapter("select
city from citystate where state='" & State & "' order by city",
myconnection)
Dim ds As New DataSet()
mycommand.Fill(ds, "city")
Return ds
End Function
Could someone elaborate what is the use and meaning of "city"
in mycommand.Fill (ds."city")