12 references to TryGetService
System.Windows.Forms (4)
System\Windows\Forms\ComponentModel\COM2Interop\COM2ComponentEditor.cs (1)
127if (!context.TryGetService(out IUIService? uiService))
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.cs (1)
1096if (this.TryGetService(out IUIService? uiService))
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyDescriptorGridEntry.ExceptionEditor.cs (1)
21if (context.TryGetService(out IUIService? uiService))
System\Windows\Forms\Design\EventsTab.cs (1)
81if (context.TryGetService(out IEventBindingService? contextEventBindingService))
System.Windows.Forms.Design (8)
System\ComponentModel\Design\BinaryEditor.cs (1)
27return _context.TryGetService(out IDesignerHost? designerhost)
System\ComponentModel\Design\CollectionEditor.cs (3)
95if (Context.TryGetService(out IDesignerHost? host) && typeof(IComponent).IsAssignableFrom(itemType)) 201if (Context.TryGetService(out IDesignerHost? host)) 407if (Context.TryGetService(out IHelpService? helpService))
System\ComponentModel\Design\EventBindingService.EventPropertyDescriptor.cs (1)
362if (context.TryGetService(out IEventBindingService? ebs))
System\Windows\Forms\Design\FormatStringDialog.cs (1)
80if (_context.TryGetService(out IHelpService? helpService))
System\Windows\Forms\Design\ListViewGroupCollectionEditor.cs (2)
39if (Context.TryGetService(out INameCreationService nameService) 40&& Context.TryGetService(out IContainer container))