Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
OLE error code0x8000ffff : Unexpected Failure ?????
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00241709
Message ID:
00241995
Views:
20
>>FOR EACH oForm in _VFP.Forms
>> oForm.Release()
>>ENDFOR
>>
>
>oForm.name would tell you which form is causing the problem? Maybe put a WAIT WINDOW in your code to display the value.
>

Thanks Wayne, using that info, I tried to debug by watching the value of 'oform.name'. What happened was that its value changed, as expected, when it hit the Diary form (the one on which I'm getting this problem) and it proceeded to release the Diary form. As soon as it entered the form's unload method the value of 'oform.name' disappeared! Nevertheless, the unload method completed its task without incident and the form duly disappeared.

However, when the loop took it back to 'oForm.Release()', because the value of oform.name had vanished into the mist, we crashed with the 'unexpected failure'. If I 'ignore' its protest, it then finds the remaining forms, correctly assigns 'oform.name' and there is no further difficulty.

The kludge I have implemented to get around this peculiar behaviour is simply to test for the existence of the variable 'oform.name' ahead of the 'oForm Release() command. (If type('oform.name')<>'U' )

which resolves the problem, but the question left hanging in the air is, of course, why should I need to do that in the first place?

Thanks for the help

Harry
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform