* This did not work (weel it worked for one InteractiveChange. Subsequent Interactives [from the combo] did not make it to the proc. So first fire worked (went to this proc, second fire did not make it to the proc. PROCEDURE TC_cmbRoof_Type_InterActiveChange(oform,ocmbRoof_Type) &&- WITH ocmbRoof_Type IF [FIX]$.Value IF VARTYPE(R6_FRLossFactors)==[O] R6_FRLossFactors.cntLFToolBar.ocxLFToolBar.buttons([LFCOPY]).enabled=.f. FR_ZeroLossFactors(R6_FRLossFactors) FR_SETFormCaption(R6_FRLossFactors,[ (fixed n-a)]) ELSE ENDIF IF VARTYPE(R6_MTDLossSummary)==[O] *ZeroOutLossFactors LS_ZeroMTDLandingLossSummaries(R6_MTDLossSummary) ELSE ENDIF STORE 0 to oform.txtRleg_Gaft.Value,oform.txtRleg_Gain.value,oform.chkShowLandingLosses.Value ELSE IF VARTYPE(R6_FRLossFactors)==[O] R6_FRLossFactors.cntLFToolBar.ocxLFToolBar.buttons([LFCOPY]).enabled=.t. IF !oform.lNewTank FR_PopulateLossFactors(R6_FRLossFactors) ELSE ENDIF FR_SETFormCaption(R6_FRLossFactors,oform.txtTank_Numb.Value) ELSE ENDIF IF VARTYPE(R6_MTDLossSummary)==[O] LS_PopulateMTD([Void]) ELSE ENDIF ENDIF TC_TankConstructionHasChanged(oform) STORE [FLOAT]$.Value TO oform.txtRleg_Gaft.Enabled,oform.txtRleg_Gain.Enabled,; oform.chkShowLandingLosses.Enabled .Setfocus ENDWITH && ocmbRoofType ENDPROC &&TC_cmbRoof_Type_InterActiveChange(oform,ocmbRoof_Type) &&-
*This oone works PROCEDURE TC_cmbRoof_Type_InterActiveChange(oform,ocmbRoof_Type) &&- WITH ocmbRoof_Type IF [FIX]$.Value IF TYPE('R6_FRLossFactors')==[O] R6_FRLossFactors.cntLFToolBar.ocxLFToolBar.buttons([LFCOPY]).enabled=.f. FR_ZeroLossFactors(R6_FRLossFactors) FR_SETFormCaption(R6_FRLossFactors,[ (fixed n-a)]) ELSE ENDIF IF TYPE('R6_MTDLossSummary')==[O] *ZeroOutLossFactors LS_ZeroMTDLandingLossSummaries(R6_MTDLossSummary) ELSE ENDIF STORE 0 to oform.txtRleg_Gaft.Value,oform.txtRleg_Gain.value,; oform.chkShowLandingLosses.Value ELSE IF TYPE('R6_FRLossFactors')==[O] R6_FRLossFactors.cntLFToolBar.ocxLFToolBar.buttons([LFCOPY]).enabled=.t. IF !oform.lNewTank FR_PopulateLossFactors(R6_FRLossFactors) ELSE ENDIF FR_SETFormCaption(R6_FRLossFactors,oform.txtTank_Numb.Value) ELSE ENDIF IF TYPE('R6_MTDLossSummary')==[O] LS_PopulateMTD([Void]) ELSE ENDIF ENDIF TC_TankConstructionHasChanged(oform) STORE [FLOAT]$.Value TO oform.txtRleg_Gaft.Enabled,oform.txtRleg_Gain.Enabled,; oform.chkShowLandingLosses.Enabled .Setfocus ENDWITH && ocmbRoofType ENDPROC &&TC_cmbRoof_Type_InterActiveChange(oform,ocmbRoof_Type) &&-I also note that VARTYPE does not vette OCX objects. For two years (or so) my code has been vetting OCX exclusively with TYPE. I maintained VARTYPE for form vetting. But in 8, VARTYPE is not as reliable as it was with 7 or 6 - at least that's what I think I am seeing.
>>If VARTYPE(SoAndSo)=="O" >> SoAndSo.Value="New Value" >>Endif>>I just had an incident where VFP error manager told me SoAndSo "is not an object" at SoAndSo.Value="New Value" , even though VFP vetted the test (in the line before) as true!