Forum Discussion
sfo_sc
13 years agoContributor
Hi Robert,
I have try to use the codes you provide above to create a event handler. I am getting error when trying to run the first IsSupported statement. Can you shade some lights on this? Here is my codes.
GeneralEvents_OnStopTest(Sender)
The error is:
An exception occurred in the "DDT_Close" unit at line 3:
Microsoft JScript runtime error
'Global' is undefined
Global DDT has already been closed in this case, but your if statement should check whether global exists right?
I have try to use the codes you provide above to create a event handler. I am getting error when trying to run the first IsSupported statement. Can you shade some lights on this? Here is my codes.
function GeneralEvents_OnStopTest(Sender)
GeneralEvents_OnStopTest(Sender)
{
if (IsSupported(DDT.DriverByName(Global.Name), "ADOCommandObject"))
{
if (DDT.DriverByName(Global.Name).ADOCommandObject != EmptyVariant)
{
DDT.CloseDriver(Global.Name);
}
}
if (IsSupported(DDT.DriverByName(Local.Name), "ADOCommandObject"))
{
if (DDT.DriverByName(Local.Name).ADOCommandObject != EmptyVariant)
{
DDT.CloseDriver(Local.Name);
}
}
}
The error is:
An exception occurred in the "DDT_Close" unit at line 3:
Microsoft JScript runtime error
'Global' is undefined
Global DDT has already been closed in this case, but your if statement should check whether global exists right?
Related Content
- 12 months ago
- 12 months ago
Recent Discussions
- 7 hours ago