CHPP Development/VB.NET/

From Hattrick
Revision as of 05:45, 28 April 2006 by Chpp-ste1n (talk | contribs) (CHPP Development/VB.NET moved to CHPP Development/VB.NET/)
Jump to navigationJump to search

Code #1: Getting the recommended server


Protected Function Get_Recommended_Server()
   Dim xmlds As New System.Data.DataSet
   Dim xmlTable As New System.Data.DataTable
   Dim xmldr As System.Data.DataRow()
   xmlds.ReadXml("http://www.hattrick.org/common/menu.asp?outputType=XML")
   xmlTable = xmlds.Tables("HattrickData")
   xmldr = xmlTable.Select(Nothing, Nothing, Data.DataViewRowState.CurrentRows)
   Return (xmldr(0)("RecommendedURL").ToString)
End Function