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