From 3328e58ff19b545b6320b2019ca65660e0d217b3 Mon Sep 17 00:00:00 2001 From: clay_shooter <> Date: Sat, 6 Oct 2007 22:06:50 +0000 Subject: [PATCH] 1.13 release notes updates with more details about redistributable packages. --- jacob/docs/ReleaseNotes.html | 12 ++--- jacob/docs/UsingJacob.html | 16 ++++--- .../jacob/samples/office/VisioPrintTest.java | 45 +++++++++++++++++++ 3 files changed, 63 insertions(+), 10 deletions(-) create mode 100644 jacob/samples/com/jacob/samples/office/VisioPrintTest.java diff --git a/jacob/docs/ReleaseNotes.html b/jacob/docs/ReleaseNotes.html index e43e019..cae4d40 100644 --- a/jacob/docs/ReleaseNotes.html +++ b/jacob/docs/ReleaseNotes.html @@ -5,13 +5,13 @@

JACOB 1.13

What's New

@@ -83,8 +83,10 @@

Tracked Changes

VC++ libraries - Jacob 1.13 is built with VC++ 2005 that creates a dependency on msvcr80.dll. - Users of older systems may have to obtain the dll as from the MS downloads site. + Jacob 1.13 is built using VC++ 2005. + That creates a dependency on the Visual C++ 2005 libraries and msvcr80.dll. + This library is normally installed on XP systems but may have to be manually + installed on older systems. It can be obtained from the MS downloads site. @@ -94,7 +96,7 @@

JACOB 1.12

What's New

diff --git a/jacob/docs/UsingJacob.html b/jacob/docs/UsingJacob.html index 0e360eb..8ad203c 100644 --- a/jacob/docs/UsingJacob.html +++ b/jacob/docs/UsingJacob.html @@ -55,14 +55,20 @@

The Jacob DLL

Microsoft Visual C++ library dependencies.

Jacob 1.13 is built with VC++ 2005 that creates a dependency on msvcr80.dll. Windows XP and later seem to already include the necessary components. - NT/2000 and Server/2003 require that you download vcredist_x86.exe - from the microsoft web site. + NT/2000 and Server/2003 require that you download the Visual C redistributable package, + vcredist_x86.exe from the microsoft web site. Microsoft has a download available that supplies the necessary components. It is distributed as a redistributable package. - See the following links. +

+If you see the following message then you probably don't have the right C++ libraries. +

+Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\apps\...\jacob.dll: This application has fa 
+iled to start because the application configuration is incorrect. Reinstalling the application may fix this pr 
+oblem 
+
-http://www.microsoft.com/downloads/details.aspx?familyid=32bc1bee-a3f9-4c13-9c99-220b62a191ee&displaylang=en
-http://www.microsoft.com/downloads/details.aspx?FamilyID=200b2fd9-ae1a-4a14-984d-389c36f85647&displaylang=en
+
+Visual C redistributable installer SP1
 

diff --git a/jacob/samples/com/jacob/samples/office/VisioPrintTest.java b/jacob/samples/com/jacob/samples/office/VisioPrintTest.java new file mode 100644 index 0000000..d47cb08 --- /dev/null +++ b/jacob/samples/com/jacob/samples/office/VisioPrintTest.java @@ -0,0 +1,45 @@ +package com.jacob.samples.office; + +import com.jacob.activeX.ActiveXComponent; +import com.jacob.com.ComFailException; +import com.jacob.com.Dispatch; + +/** + * Snippet to show Visio print dialog + *

+ * Sample submitted by fatbuttlarry in SourceForge 1803140 + * as part of bug report + *

+ * Tested with Java 6.0SE and MS Office 2003 ** Note: 1010 = VB's + * visCmdFilePrint constant + */ +public class VisioPrintTest { + + /** + * Runs the print ant lets the user say ok or cancel. Note the funky Visio + * behavior if someone hits the cancel button + * + */ + public void testPrintDialog() { + ActiveXComponent oActiveX = new ActiveXComponent("Visio.Application"); + Dispatch oDocuments = oActiveX.getProperty("Documents").toDispatch(); + // create a blank document + Dispatch.call(oDocuments, "Add", ""); + try { + Dispatch.call(oActiveX, "DoCmd", new Integer(1010)) + .getInt(); + System.out.println("User hit the ok button."); + } catch (ComFailException e) { + System.out.println("User hit the cancel button: " + e); + } finally { + oActiveX.invoke("Quit"); + } + return; + } + + /** quick main() to test this */ + public static void main(String[] args) { + VisioPrintTest testObject = new VisioPrintTest(); + testObject.testPrintDialog(); + } +}