using System; using System.Data; using System.Media; using iMonitorApp.Properties; using MySql.Data.MySqlClient; namespace iMonitorApp { // Token: 0x02000006 RID: 6 public class MarketData { // Token: 0x0600001D RID: 29 private string GetMysqlConnString() { return "server=10.152.16.10;port=3304;Initial Catalog=customRef;User ID=root;Password=FOUR2008;"; } // Token: 0x0600001E RID: 30 RVA: 0x00002F0C File Offset: 0x0000110C public string CheckAlarms() { string result; try { MySqlConnection mySqlConnection = new MySqlConnection(this.GetMysqlConnString()); mySqlConnection.Open(); MySqlDataAdapter mySqlDataAdapter = new MySqlDataAdapter("SELECT * from mktdata_marketdataalarms WHERE highDirty='TRUE' OR lowDirty='TRUE'", mySqlConnection); DataTable dataTable = new DataTable(); mySqlDataAdapter.Fill(dataTable); bool flag = dataTable.Rows.Count > 0; if (flag) { new SoundPlayer(Resources.photo).Play(); } mySqlConnection.Close(); result = "MktData: OK"; } catch (Exception ex) { result = "MktData: " + ex.Message; } return result; } } }