4 writes to instance
System.Windows.Forms (4)
winforms\Managed\System\WinForms\AxHost.cs (4)
2562instance = ret; 2573icf2.CreateInstanceLic(null, null, ref NativeMethods.ActiveX.IID_IUnknown, license, out instance); 2593instance = CreateInstanceCore(this.clsid); 4563instance = null;
39 references to instance
System.Windows.Forms (39)
winforms\Managed\System\WinForms\AxHost.cs (39)
2574Debug.WriteLineIf(AxHTraceSwitch.TraceVerbose, "\t" + (instance != null).ToString()); 2582if (instance == null) { 2588Debug.Assert(instance == null, "instance must be null"); 2594Debug.Assert(instance != null, "w/o an exception being thrown we must have an object..."); 2619return instance; 3110if (instance is UnsafeNativeMethods.IPersistStreamInit) { 3111iPersistStreamInit = (UnsafeNativeMethods.IPersistStreamInit) instance; 3121if (instance is UnsafeNativeMethods.IPersistStream) { 3123iPersistStream = (UnsafeNativeMethods.IPersistStream) instance; 3126if (instance is UnsafeNativeMethods.IPersistStorage) { 3129iPersistStorage = (UnsafeNativeMethods.IPersistStorage) instance; 3138if (instance is UnsafeNativeMethods.IPersistPropertyBag) { 3140iPersistPropBag = (UnsafeNativeMethods.IPersistPropertyBag) instance; 3157iPersistStream = (UnsafeNativeMethods.IPersistStream) instance; 3165if (instance is UnsafeNativeMethods.IPersistStreamInit) { 3167iPersistStreamInit = (UnsafeNativeMethods.IPersistStreamInit) instance; 3183iPersistStorage = (UnsafeNativeMethods.IPersistStorage) instance; 3197iPersistPropBag = (UnsafeNativeMethods.IPersistPropertyBag)instance; 3213return instance; 3218if (instance == null) { 3224return instance; 4428if (!(instance is UnsafeNativeMethods.IQuickActivate)) return false; 4429UnsafeNativeMethods.IQuickActivate iqa = (UnsafeNativeMethods.IQuickActivate) instance; 4561if (instance != null) { 4562Marshal.FinalReleaseComObject(instance); 4654Debug.Assert(instance != null, "must have the ocx"); 4655iOleControl = (UnsafeNativeMethods.IOleControl) instance; 4668Debug.Assert(instance != null, "must have the ocx"); 4670iOleInPlaceActiveObject = (UnsafeNativeMethods.IOleInPlaceActiveObject)instance; 4681Debug.Assert(instance != null, "must have the ocx"); 4682iOleObject = (UnsafeNativeMethods.IOleObject) instance; 4689Debug.Assert(instance != null, "must have the ocx"); 4690iOleInPlaceObject = (UnsafeNativeMethods.IOleInPlaceObject) instance; 4701if (iCategorizeProperties == null && !axState[checkedCP] && instance != null) { 4703if (instance is NativeMethods.ICategorizeProperties) { 4704iCategorizeProperties = (NativeMethods.ICategorizeProperties) instance; 4711if (iPerPropertyBrowsing == null && !axState[checkedIppb] && instance != null) { 4713if (instance is NativeMethods.IPerPropertyBrowsing) { 4714iPerPropertyBrowsing = (NativeMethods.IPerPropertyBrowsing) instance;