Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
JT JT is offline
external usenet poster
 
Posts: 234
Default Open Word from Excel

In my workbook, I have one sheet with high level instructions for the users.
On that sheet. there is a button to open a Word Document with more detailed
instructions for the user to read. It works fairly well and opens quickly.

The issue is once the Word document is open, it is not useable, almost like
it is frozen for 5 to 10 seconds. Once the initial "frozen" period is over,
the user is able to scroll or move through the document.

The code for this button is below:

Dim WApp As Word.Application
Dim WDoc As Word.Document
Set WApp = CreateObject("Word.Application")

Dim ThisPath As String
Dim ThisFile As String

ThisPath = "\\Vs999\public\Accounts\Originals\"
ThisFile = "Instructions - Admin Office.doc"

Set WDoc = WApp.Documents.Open(ThisPath & ThisFile)

WApp.Visible = True

Set WApp = Nothing
Set WDoc = Nothing

Any suggestions or help you can provide to resolve / reduce that waiting
period would be greatly resolved. This the first time I have tried to open a
Word document from Excel. Thanks again......

--
JT
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Open Word from Excel

I haven't had that type of experience - although opening anything via
automation incurs some overhead as the application is stared. If you open
the document manually, does it open instantly?

things I could think of would be Norton Anti-Virus running a scan of the
document.

or the document is large and/or has links that have to be updated - so it
naturally takes a while to open.

From your description, it appears the document is visible on the screen
during this period, so I assume you are not talking about the overhead of
starting up word.


--
Regards,
Tom Ogilvy



"JT" wrote:

In my workbook, I have one sheet with high level instructions for the users.
On that sheet. there is a button to open a Word Document with more detailed
instructions for the user to read. It works fairly well and opens quickly.

The issue is once the Word document is open, it is not useable, almost like
it is frozen for 5 to 10 seconds. Once the initial "frozen" period is over,
the user is able to scroll or move through the document.

The code for this button is below:

Dim WApp As Word.Application
Dim WDoc As Word.Document
Set WApp = CreateObject("Word.Application")

Dim ThisPath As String
Dim ThisFile As String

ThisPath = "\\Vs999\public\Accounts\Originals\"
ThisFile = "Instructions - Admin Office.doc"

Set WDoc = WApp.Documents.Open(ThisPath & ThisFile)

WApp.Visible = True

Set WApp = Nothing
Set WDoc = Nothing

Any suggestions or help you can provide to resolve / reduce that waiting
period would be greatly resolved. This the first time I have tried to open a
Word document from Excel. Thanks again......

--
JT

  #3   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 65
Default Open Word from Excel

JT -

I think you might be mixing early and late binding, which could be
causing some problems. You might want to take a look at
http://word.mvps.org/FAQs/InterDev/E...ateBinding.htm
and
http://word.mvps.org/FAQs/InterDev/C...WordFromXL.htm

Ed

On Apr 18, 9:24 am, JT wrote:
In my workbook, I have one sheet with high level instructions for the users.
On that sheet. there is a button to open a Word Document with more detailed
instructions for the user to read. It works fairly well and opens quickly.

The issue is once the Word document is open, it is not useable, almost like
it is frozen for 5 to 10 seconds. Once the initial "frozen" period is over,
the user is able to scroll or move through the document.

The code for this button is below:

Dim WApp As Word.Application
Dim WDoc As Word.Document
Set WApp = CreateObject("Word.Application")

Dim ThisPath As String
Dim ThisFile As String

ThisPath = "\\Vs999\public\Accounts\Originals\"
ThisFile = "Instructions - Admin Office.doc"

Set WDoc = WApp.Documents.Open(ThisPath & ThisFile)

WApp.Visible = True

Set WApp = Nothing
Set WDoc = Nothing

Any suggestions or help you can provide to resolve / reduce that waiting
period would be greatly resolved. This the first time I have tried to open a
Word document from Excel. Thanks again......

--
JT



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Open Word from Excel

Whilst it may not have any effect on the freeze, as you only require the
document to be shown, drop the COM stuff.

Dim ThisPath As String
Dim ThisFile As String

ThisPath = "\\Vs999\public\Accounts\Originals\"
ThisFile = "Instructions - Admin Office.doc"

ThisWorkbook.FollowHyperlink ThisPath & ThisFile, , True

NickHK

"JT" wrote in message
...
In my workbook, I have one sheet with high level instructions for the

users.
On that sheet. there is a button to open a Word Document with more

detailed
instructions for the user to read. It works fairly well and opens

quickly.

The issue is once the Word document is open, it is not useable, almost

like
it is frozen for 5 to 10 seconds. Once the initial "frozen" period is

over,
the user is able to scroll or move through the document.

The code for this button is below:

Dim WApp As Word.Application
Dim WDoc As Word.Document
Set WApp = CreateObject("Word.Application")

Dim ThisPath As String
Dim ThisFile As String

ThisPath = "\\Vs999\public\Accounts\Originals\"
ThisFile = "Instructions - Admin Office.doc"

Set WDoc = WApp.Documents.Open(ThisPath & ThisFile)

WApp.Visible = True

Set WApp = Nothing
Set WDoc = Nothing

Any suggestions or help you can provide to resolve / reduce that waiting
period would be greatly resolved. This the first time I have tried to

open a
Word document from Excel. Thanks again......

--
JT



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Hyperlink doesn't open Word doc the same way as Word does duugg Excel Discussion (Misc queries) 2 October 12th 06 03:14 PM
How to open a word doc while in Excel Katie Excel Discussion (Misc queries) 5 February 21st 06 07:56 PM
open word doc from within excel with VBA Luc[_3_] Excel Programming 1 March 20th 05 06:56 PM
Graph Excel Selection, Open Word File, Embed Graph Into Word Steve Excel Programming 0 November 17th 03 05:35 PM
In Excel VBA, open .txt with Word? Ed[_9_] Excel Programming 4 October 30th 03 05:42 PM


All times are GMT +1. The time now is 04:32 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"