當前位置: 首頁>>代碼示例>>C#>>正文


C# Controls.SelectionChangedEventArgs類代碼示例

本文整理匯總了C#中System.Windows.Controls.SelectionChangedEventArgs的典型用法代碼示例。如果您正苦於以下問題:C# SelectionChangedEventArgs類的具體用法?C# SelectionChangedEventArgs怎麽用?C# SelectionChangedEventArgs使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


SelectionChangedEventArgs類屬於System.Windows.Controls命名空間,在下文中一共展示了SelectionChangedEventArgs類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: checkerGrid_SelectionChanged

 /// <summary>
 /// 安檢單列表選擇改變
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void checkerGrid_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     GeneralObject item = checkerGrid.SelectedItem as GeneralObject;
     if (item == null)
         return;
     GeneralObject go = new GeneralObject();
     go.WebClientInfo = Application.Current.Resources["dbclient"] as WebClientInfo;
     go.EntityType = "T_INSPECTION";
     if (!item.GetPropertyValue("CONDITION").Equals("未檢"))
     {
         go.Path = "one/select distinct t from T_INSPECTION t left join fetch t.LINES where t.id ='" + item.GetPropertyValue("id").ToString() + "'";
         go.DataLoaded += go_DataLoaded;
         //if (!item.GetPropertyValue("CONDITION").Equals("正常"))
         //    userfile.IsEnabled = false;
         //else
         //    userfile.IsEnabled = true;
         go.Load();
     }
     else
     {
         userfile.DataContext = null;
         ClearAll();
         //userfile.IsEnabled = false;
     }
 }
開發者ID:DuBin1988,項目名稱:anjian_phone_server,代碼行數:30,代碼來源:燃氣表故障明細.xaml.cs

示例2: LongListSelector_SelectionChanged

        private void LongListSelector_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            LongListSelector selector = sender as LongListSelector;
            //verifying our sender is actually a LongListSelector
            if (selector == null)
                return;

            SoundData data = selector.SelectedItem as SoundData;
            //verifying our sender is actually SoundData
            if (data == null)
                return;
            if (File.Exists(data.FilePath))
            {
                AudioPlayer.Source = new Uri(data.FilePath, UriKind.RelativeOrAbsolute);
            }
            else
            {
                using (var storageFolder = IsolatedStorageFile.GetUserStoreForApplication())
                {
                    using (var stream = new IsolatedStorageFileStream(data.FilePath, FileMode.Open, storageFolder))
                    {
                        AudioPlayer.SetSource(stream);
                    }
                }
            }
            selector.SelectedItem = null;
        }
開發者ID:njlxyaoxinwei,項目名稱:SoundBoard,代碼行數:27,代碼來源:MainPage.xaml.cs

示例3: SelectionChanged

 private void SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (directDeleteRadioButton.IsChecked == true)
     {
         RemoveItem();
     }            
 }
開發者ID:ohnoitsfraa,項目名稱:1TIN_dotNetEssentials,代碼行數:7,代碼來源:MainWindow.xaml.cs

示例4: Purpose_Combo_SelectionChanged

 private void Purpose_Combo_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (this.IsInitialized)
     {
         refresh();
     }
 }
開發者ID:Stankim,項目名稱:Onion,代碼行數:7,代碼來源:ClassList.xaml.cs

示例5: combo1_SelectionChanged

 private void combo1_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     var classType = combo1.SelectedValue as Type;
     shapeWidth.IsEnabled = true;
     int argCount = NumberOfArguments(classType.Name);
     shapeHeight.IsEnabled = (argCount > 1);
 }
開發者ID:jcockhren,項目名稱:SharpShapes,代碼行數:7,代碼來源:MainWindow.xaml.cs

示例6: OnSelectionChanged

		protected override void OnSelectionChanged(SelectionChangedEventArgs e)
		{
			base.OnSelectionChanged(e);
			if (this.SelectedIndex != CompilerMessageView.Instance.SelectedCategoryIndex) {
				CompilerMessageView.Instance.SelectedCategoryIndex = this.SelectedIndex;
			}
		}
開發者ID:Paccc,項目名稱:SharpDevelop,代碼行數:7,代碼來源:CompilerMessageViewToolbarCommands.cs

示例7: Student_Combo_SelectionChanged

 private void Student_Combo_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (event_running) return;
     event_running = true;
     runEvent();
     event_running = false;
 }
開發者ID:GrayJumba,項目名稱:Onion,代碼行數:7,代碼來源:ExtendedStudentPicker.xaml.cs

示例8: Help3CatalogsSelectionChanged

 void Help3CatalogsSelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     string item = (string)help3Catalogs.SelectedValue;
     if (!string.IsNullOrEmpty(item)) {
         Help3Service.ActiveCatalogId = item;
     }
 }
開發者ID:2594636985,項目名稱:SharpDevelop,代碼行數:7,代碼來源:Help3OptionsPanel.xaml.cs

示例9: symbolCombo_SelectionChanged

		// Cancel current shape request when the symbol selection changes 
		private async void symbolCombo_SelectionChanged(object sender, SelectionChangedEventArgs e)
		{
			if (MyMapView.Editor.IsActive)
				MyMapView.Editor.Cancel.Execute(null);

			await AcceptPointsAsync();
		}
開發者ID:MagicWang,項目名稱:arcgis-runtime-samples-dotnet,代碼行數:8,代碼來源:LineFillSymbols.xaml.cs

示例10: Letters_SelectionChanged

 private void Letters_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (this.listLetters.SelectedIndex == -1)
         return;
     NavigationService.Navigate(new Uri("/Views/Words.xaml?nid=0&l=" + AppSettings.CyrillicLetters[this.listLetters.SelectedIndex], UriKind.Relative));
     this.listLetters.SelectedIndex = -1;
 }
開發者ID:supudo,項目名稱:Neolog-WP,代碼行數:7,代碼來源:NestsAndLetters.xaml.cs

示例11: ArrangementList_SelectionChanged

 private void ArrangementList_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     curArr = ArrangementList.SelectedIndex;
     if (curArr < 0)
         return;
     UpdateArrangement();
 }
開發者ID:Herringway,項目名稱:EBArrangementViewer,代碼行數:7,代碼來源:MainWindow.xaml.cs

示例12: lstGroups_SelectionChanged

 private void lstGroups_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (lstGroups.SelectedIndex > -1)
     {
         NavigationService.Navigate(new Uri("/GroupDetailPage.xaml?ID=" + (lstGroups.SelectedItem as RecipeDataGroup).UniqueId, UriKind.Relative));
     }
 }
開發者ID:WindowsPhone-8-TrainingKit,項目名稱:HOL-PortingWindows8AppToWP8,代碼行數:7,代碼來源:MainPage.xaml.cs

示例13: lstAdapters_SelectionChanged

        private void lstAdapters_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            lstAdapterItem selItem = ((lstAdapterItem)lstAdapters.SelectedItem);
            TextBox dnsBox = new TextBox() { Text = selItem.PrimaryDNS };

            TiltEffect.SetIsTiltEnabled(dnsBox, true);

            CustomMessageBox messageBox = new CustomMessageBox()
            {
                Caption = "Edit DNS for " + selItem.Name,
                Message = "Primary DNS Server:",
                Content = dnsBox,
                LeftButtonContent = "save",
                RightButtonContent = "cancel",
                IsFullScreen = false
            };

            messageBox.Dismissed += (s1, e1) =>
            {
                if (e1.Result == CustomMessageBoxResult.LeftButton)
                {
                    Registry.SetMultiStringValue(selItem.KeyRoot, selItem.KeyPath, "DNS", new string[] { dnsBox.Text });
                    //TODO: Clear the list first
                    refreshAdapters();
                }
                //TODO: Fix this
                //lstAdapters.SelectedIndex = -1;
            };

            messageBox.Show();
        }
開發者ID:Digiex,項目名稱:DNSChangerWP7,代碼行數:31,代碼來源:MainPage.xaml.cs

示例14: comboBoxCameras_SelectionChanged

 private void comboBoxCameras_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     _cameraFrameSource.Camera = comboBoxCameras.SelectedItem as Camera;
     panelCameraInfo.Visibility = comboBoxCameras.SelectedItem != null
                                         ? Visibility.Visible
                                         : Visibility.Collapsed;
 }
開發者ID:donnaknew,項目名稱:programmingProject,代碼行數:7,代碼來源:CameraFrameSourceConfigurationElement.xaml.cs

示例15: lvItems_SelectionChanged

        private void lvItems_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            StockList.Value v = (StockList.Value)lvItems.SelectedItem;
            if (v != null)
            {
                XmlDataProvider provider = (XmlDataProvider)grdRssFeed.FindResource("rssData");

                switch (v.Market)
                {
                    case "NASDAQ":
                        provider.Source = new Uri("http://articlefeeds.nasdaq.com/nasdaq/symbols?symbol=" + v.Symbol);
                        break;
                    case "LSE":
                        provider.Source = new Uri("http://www.londonstockexchange.com/exchange/CompanyNewsRSS.html?newsSource=RNS&indexSymbol=ASX");
                        break;
                    case "DAX":
                        provider.Source = new Uri("http://feeds.finance.yahoo.com/rss/2.0/headline?s=" + v.Symbol + "&region=US&lang=en-US");
                        break;
                }

                if (!couchDb.isMyStock(v.Symbol))
                {
                    btnDelete.Visibility = System.Windows.Visibility.Collapsed;
                    btnAdd.Visibility = System.Windows.Visibility.Visible;
                }
                else
                {
                    btnDelete.Visibility = System.Windows.Visibility.Visible;
                    btnAdd.Visibility = System.Windows.Visibility.Collapsed;
                }

                wbChart.Navigate(new Uri("http://83.254.83.56:8001/files/highcharts/chart.html?symbol=" + v.Symbol + "&market=" + v.Market.ToLower()));
            }
        }
開發者ID:JohnBurchell,項目名稱:School,代碼行數:34,代碼來源:MainWindow.xaml.cs


注:本文中的System.Windows.Controls.SelectionChangedEventArgs類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。