private void button1_Click(object sender, EventArgs e) { try { m_LsConnector = new LsConnector(); m_LsConnector.SchemaFilePath = @"E:\NotificationProvider\LS.Client\LightStreamerConnector\SchemaInfo.xml"; m_LsConnector.Initialize(); } catch (Exception exp) { MessageBox.Show(exp.ToString()); } }
private void btnGetNotificaions_Click(object sender, EventArgs e) { try { m_LsConnector = new LsConnector(); m_LsConnector.PushServer = "localhost"; m_LsConnector.Port = 8080; m_LsConnector.AdapterSetName = "WELCOME"; m_LsConnector.FeedAdapter = "MY_REMOTE"; m_LsConnector.UserName = "******"; m_LsConnector.Password = "******"; // will be used to resolve schema info to send it to Metadata Provider m_LsConnector.SchemaFilePath = @"E:\NotificationProvider\LS.Client\LightStreamerConnector\SchemaInfo.xml"; m_LsConnector.Initialize(); m_LsConnector.LoadSchemaInfo(); bool result = m_LsConnector.ConnectToLs(); if (result == true) { MessageBox.Show("Connected to LightStreamer Successfully"); m_ReceivedFeedBCollecion = m_LsConnector.ReceivedFeedBCollecion; Task.Factory.StartNew(() => { StartProcessFeed(); }); } } catch (Exception exp) { MessageBox.Show(exp.ToString()); } }