CHPP Development/C

From Hattrick
Revision as of 16:15, 4 September 2006 by 62.253.96.44 (talk)
Jump to navigationJump to search

Step 1. Connecting to a recommended Server

       static public String getRecommendedServer()
       {
               DataSet xmlDataSet = new DataSet();
               DataTable xmlDataTable = new DataTable();
              
              xmlDataSet.ReadXml("http://www.hattrick.org/common/menu.asp?outputType=XML");
              xmlDataTable = xmlDataSet.Tables[0];
              DataRow [] xmlDataRow = xmlDataTable.Select("", "",DataViewRowState.CurrentRows);
              return (xmlDataRow[0]["RecommendedURL"].ToString());
       }