NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand Engine. Execute sequence

Hi,

 

I am trying to execute a sequence using the TestStand API using javascript.

 

My html code is as follows:

 

<!DOCTYPE html>

<html>
<head>

 

</head>
<body onload="CreateTestStandEngine()">
<p>
<object classid="clsid:B2794EF6-C0B6-11D0-939C-0020AF68E893" id="TSEngine" height="300" width="300"></object>
<button type="button" onclick="RunSeq()">Run Sequence</button>
</p>

</body>


<script type="text/javascript">
var TestStand_Engine;

function CreateTestStandEngine(){
try{
TestStand_Engine = document.getElementById("TSEngine");
console.log('TestStand Engine version >> ' + TestStand_Engine.VersionString);
console.log('TestStand Engine UniqueEngineID >> ' + TestStand_Engine.UniqueEngineId);

}
catch(e){
alert(e.message);
}

return (TestStand_Engine);
}

function RunSeq(){
try{
var Seq = TestStand_Engine.GetSequenceFileEx('C:\\Users\\Public\\Documents\\National Instruments\\Seq1.seq',107,1)
var Exec = TestStand_Engine.NewExecution(Seq,'MainSequence',null,false,0x10,null,null,null);
Exec.WaitForEndEx(-1);
TestStand_Engine.ReleaseSequenceFileEx(Seq, 0x0);
}
catch(e){
alert(e.message);
}
return
}

</script>

</html>

 

I am using Internet Explorer as browser and TestStand Engine Version 2019 f2 (19.0.0.170) 32-bit

 

The issue arises when I execute the javascript function 'RunSeq()'.

error code  -2147352571

 

Thanks in advance for any help.

 

Regards

 

 

0 Kudos
Message 1 of 1
(849 Views)