reorganized the samples, again. Moved the programs that were more test cases to the unit test directory and repackaged the unit test directory.
This commit is contained in:
18
unittest/com/jacob/test/vbscript/speed.java
Normal file
18
unittest/com/jacob/test/vbscript/speed.java
Normal file
@@ -0,0 +1,18 @@
|
||||
package com.jacob.test.vbscript;
|
||||
|
||||
import com.jacob.com.*;
|
||||
import com.jacob.activeX.*;
|
||||
|
||||
class speed
|
||||
{
|
||||
public static void main(String args[])
|
||||
{
|
||||
String lang = "VBScript";
|
||||
ActiveXComponent sC = new ActiveXComponent("ScriptControl");
|
||||
Dispatch sControl = sC.getObject();
|
||||
Dispatch.put(sControl, "Language", lang);
|
||||
for(int i=0;i<10000;i++) {
|
||||
Dispatch.call(sControl, "Eval", "1+1");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user