Has anyone been able to get "Method ObjResult =" to trigger a run-time error in VB or VBScript?
I'm an old VB guy and I tend to look for analogs in PowerBasic for the things I've used in VB.
In VB you can trigger a run-time error in a COM client by raising an error via the VB Err object:
It appears that the analog in PB is some combination of the "ObjResult =" and the "IDispInfo.Set" statements:
I've created a PowerBasic COM server that I'm instantiating from VB and whenever I execute the following method I get a fatal VB crash:
No matter what value I've used with ObjResult, If I set the MSB, I always get a fatal VB crash.
So, what is the trick to triggering a run-time error in a VB COM client?
-Wes
I'm an old VB guy and I tend to look for analogs in PowerBasic for the things I've used in VB.
In VB you can trigger a run-time error in a COM client by raising an error via the VB Err object:
Code:
Err.Raise vbObjectError + VBErrorsOffset + YourErrorNumber [,Source] [,Description] [,Helpfile] [,Helpcontext]
Code:
Method ObjResult = hResult or Property ObjResult = hResult and IDispInfo.Set code& [, source$, desc$, help$, context&]
Code:
Method Bang <92> () As Long Method = 999& Method ObjResult = &H80040000& End Method
So, what is the trick to triggering a run-time error in a VB COM client?
-Wes
Comment