p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

vba_word thread: OPEN command in BV


Message #1 by "Roger Strolz" <rstrolz@p...> on Mon, 17 Jun 2002 16:32:12
if i load an word file (from VB). Like:

    Dim objWord As Word.Application
    Dim objDocContent As Word.Range
    Dim sDocName As String
    Dim i As Integer, msg As String, stmpDir As String
    Dim iNoChange As Boolean
    
    
    Set objWord = CreateObject("Word.Application")
    objWord.Visible = True
    objWord.ScreenUpdating = True
    
    sDocName = sFilename
    objWord.Documents.Open FileName:=sDocName
******
      objWord.ActiveWindow.View.ShowFieldCodes = True
      Set objDocContent = objWord.ActiveDocument.Content

how i can find out, when the document is fully loaded and displaeyd.??
I want to change a part of the doc. if i start it in debug mode, every 
thins works fine. if i start the exe, it didn't work.
i think the doc. is no complet loaded.

how can i fix this problem???

thanx roger

  Return to Index