This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal


Apr 27, 2015, 6:27 PM
2 Posts

Issue with Windows 2012, Notes 9 and Word 2013

  • Category: Application Development
  • Platform: Windows
  • Release: 9.0.1
  • Role: Administrator,Developer,End User
  • Tags:
  • Replies: 8

I am putting this is multiple Forums (development and admin) so, please bare with me.

We have a process currently running in production today. Scheduled agent (LotusScript) that runs on server (Win 2003) to generate PDF (via PDFCreator), then runs Word 2007 to create a table of contents and then ports it all over to Adobe in .pdf format. Works great and has been for years.

Now, we are in the process of upgrading all of our servers to Windows 2012 64 bit, Notes 9 32 bit and Office 2013 32 bit. During testing, we are noticing that the Word portion of the code is no longer working. The code does load Word 2013 (viewed through Task Manager on server) but, we can't seem to get a handle on it to perform the rest of the functionality. We have added in extra code to test for Null or Nothing and still runs the exact same, as if it does recognize Word but, does nothing.

Testing new piece of code locally, Word 2013 does load up on the screen. Moving that exact code over to the new server, Word 2013 does load in task manager BUT never loads on the screen. Also, the rest of the code does NOT run. This code is a simple TypeText that just adds text to the blank document. In fact, here is the test code that works locally (laptop) but NOT on server. By not work I mean there are no errors or anything being thrown. It runs, loads up Word 2013 (as viewed in Task manager) but does not add text to document or save it:

Sub Initialize
Dim msWord As Variant
Dim msDoc As Variant
Dim msText As Variant

On Error Resume Next

Print "Loading Microsoft Word...Please Wait..."
Set msWord = GetObject("", "Word.Application")

If msWord Is Nothing Then
Set msWord = CreateObject("Word.Application")
End If
Print "Microsoft Word Loaded"

msWord.Visible = True
Print "Microsoft Word Visible"

msWord.documents.Add
Print "Microsoft Word added new blank document"

msWord.Selection.TypeText("and you know my name is Simon....")
Print "Microsoft Word added text"

Dim msFileName As String
msFileName = "C:\temp\JasonCyr.doc"

msWord.ActiveDocument.SaveAs2 msFileName$
Print "Microsoft Word saved new document"

Print "Loading complete"
End Sub

My questions are, is anyone else doing anything similar to this and does it work for you? Also, is there perhaps some setting (windows server, word, notes 9, security even) that we are missing? Finally, does anyone know what logs are out there on the server to help us troubleshoot Word 2013 in case that is throwing an error in backend and we just don't see it up front?

Any help would be greatly appreciated.

Apr 27, 2015, 10:10 PM
326 Posts
Wondering

is the domino server 32 ot 64 bit ?

Is the Word 2013 32 or 64 bit?

 

Did you manually run the word 2013 under the same id that the server is running under?  Just trying to rule out permission issues.  I looked at this link and wonder also if .net is installed?  https://technet.microsoft.com/en-us/library/ee624351.aspx#section26

 

I also found this

https://msdn.microsoft.com/en-us/library/office/ff838565.aspx   Convert the code to lotusscript and see if you at least a document to open.

 

Set wrd = GetObject(, "Word.Application") 
wrd.Visible = True 
wrd.Documents.Open "C:\My Documents\Temp.doc" 
Set wrd = Nothing

 

 

 

Apr 28, 2015, 8:00 AM
30 Posts
The problem is in Word

You are trying to create a .doc - word is now .docx and will whinge and pop up a window to confirm that's what you want - in a server agent, there's no way to respond to that whinge

You need to create a new .docx template from scratch - you can't just save-as your existing one - and open that instead

Apr 28, 2015, 3:59 PM
2 Posts
Create new template???

When you say new docx template, do you mean

msWord.documents.Add("C:\temp\JasonCyr.docx")

If not, what exactly are you referring to?

Thanks for your response

Apr 29, 2015, 7:52 AM
30 Posts
From experience...

I strongly suggest creating a new template, in a blank docx file

Because even copying (e.g.) images from a .doc to a .docx file buggers up the file format

Same problems occur with .xls and .xlsx files

Jun 1, 2015, 1:40 PM
8 Posts
Timing issue in COM object initialization
There appears to have been a change in how Microsoft Office COM objects initialize starting with Office 2010.
In previous versions once the GetObject / CreateObject call returned you could immediately start using it.

In most cases adding a pause {sleep(1)} before doing anything with the object fixes this problem.

Have fun.

Ninke.

Jul 16, 2015, 11:19 AM
2 Posts
Did you get this resolved?

We are having the same issue at our organization. Were you able to resolve this?

Jul 16, 2015, 11:19 AM
2 Posts
Did you get this resolved?

We are having the same issue at our organization. Were you able to resolve this?


This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal