/// <summary>
        /// Updates note settings
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void SaveSettingsButton_Click(object sender, RoutedEventArgs e)
        {
            int    refreshValue   = int.Parse(RefreshActiveNotesTextBox.Text);
            string timeOptionsVal = ((ComboBoxItem)TimeOptions.SelectedItem).Content.ToString(); //TimeOptions.SelectedValue.ToString();

            NoteSettingsRequest noteSetReq = new NoteSettingsRequest()
            {
                Id = 1,
                NoteRefreshInterval = ConstructTimeSpan(timeOptionsVal, refreshValue).ToString(),
                NumberOfActiveNotes = int.Parse(ActiveNotesTextBox.Text)
            };

            ServiceManager noteSettingsMgr = new ServiceManager(AppConfiguration.NoteSettingsURI);
            var            x = noteSettingsMgr.CallPOSTService <NoteSettingsRequest>(noteSetReq);
        }
Example #2
0
        /// <summary>
        /// Updates note settings
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void SaveSettingsButton_Click(object sender, RoutedEventArgs e)
        {
            int refreshValue = int.Parse(RefreshActiveNotesTextBox.Text);
            string timeOptionsVal = ((ComboBoxItem)TimeOptions.SelectedItem).Content.ToString(); //TimeOptions.SelectedValue.ToString();
            
            NoteSettingsRequest noteSetReq = new NoteSettingsRequest()
            {
                Id = 1,
                NoteRefreshInterval = ConstructTimeSpan(timeOptionsVal,refreshValue).ToString(),
                NumberOfActiveNotes = int.Parse(ActiveNotesTextBox.Text)
            };

            ServiceManager noteSettingsMgr = new ServiceManager(AppConfiguration.NoteSettingsURI);
            var x = noteSettingsMgr.CallPOSTService<NoteSettingsRequest>(noteSetReq);
        }