public void sendNewInstance(InstancePacket instancePacket) { string artN = instancePacket.ArtistName; string songN = instancePacket.SongName; string fanNum = instancePacket.FanNumber; string videoChk = instancePacket.VideoChk; string rule = instancePacket.Rule; // 이제 여기서 이 정보를 서버에게 넘기면 됨 }
public void sendNewInstance(InstancePacket instancePacket) { string[] attribute = new string[5]; attribute[0] = instancePacket.Rule; attribute[1] = instancePacket.ArtistName; attribute[2] = instancePacket.SongName; attribute[3] = instancePacket.FanNumber; attribute[4] = instancePacket.VideoChk; // 이제 여기서 이 정보를 서버에게 넘기면 됨 ((App)Application.Current).Send(attribute); }
private void Hyperlink_Click(object sender, RoutedEventArgs e) { string artN = ArtistName.Text as string; if (artN == "") { MessageBox.Show("Artist Name is empty!"); return; } string songN = SongName.Text as string; if (songN == "") { MessageBox.Show("SongName is empty!"); return; } string fanNum = FanNum.Text as string; if (fanNum == "") { MessageBox.Show("FanNumber is empty!"); return; } string videoChk = MVChk.IsChecked.Value? "yes":"no"; string rule = RuleCombo.SelectedItem as string; InstancePacket instancePacket = new InstancePacket( artN, songN, fanNum, videoChk, rule); MainWindowViewModel mwvm = MainWindowViewModel.instance; mwvm.sendNewInstance(instancePacket); PredictUserControlViewModel pucv = PredictUserControlViewModel.instance; //pucv.AFR = fanNum; //pucv.SMR = videoChk; pucv.Rule = rule; PredictButton.IsChecked = true; mwvm.loadPredictPage(artN); }