diff --git a/samples/com/jacob/samples/test/powerpoint/PowerpointTest.java b/samples/com/jacob/samples/test/powerpoint/PowerpointTest.java new file mode 100644 index 0000000..79aa904 --- /dev/null +++ b/samples/com/jacob/samples/test/powerpoint/PowerpointTest.java @@ -0,0 +1,103 @@ +package com.jacob.samples.test.powerpoint; + + /* + * $Id: PowerpointTest.java,v 1.1 2005/07/07 01:08:23 clay_shooter Exp $ + */ +import com.jacob.activeX.ActiveXComponent; +import com.jacob.com.ComThread; +import com.jacob.com.Dispatch; + +/** + * + * power point test program posted to sourceforge to demonstrate memory problem. + * The submitter stated they had the problem on windows 2000 with office 2000 + * I have been unable to duplicate on windows XP with office 2003. + * I am comitting this to the tree just in case we need to come back to it. + */ +public class PowerpointTest extends Thread { + private static final int NUM_THREADS = 3; + protected static final int NUM_ITERATIONS = 50; + + private static String POWERPOINT_TEST_PATH = + "D:\\jacob\\samples\\com\\jacob\\samples\\test\\powerpoint\\test"; + //"c:\\PowerpointTest\test"; + + private int threadID; + private Dispatch comPowerpoint; + + public PowerpointTest(int threadID, Dispatch comPowerpoint) { + super("TestThread "+threadID); + this.threadID = threadID; + this.comPowerpoint = comPowerpoint; + } + + public void run() { + System.out.println("Thread \""+Thread.currentThread().getName()+"\" started"); + System.out.flush(); + ComThread.InitMTA(); + try { + for (int i=0; i