Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Paste in WinWord, problems with several processes
When using the following code, winword remain as an process in task-manager.
That become a problem when I run the macro again and again. I had hundereds of processes running. _____________________________________ Dim wdbasic As Object Set wdbasic = CreateObject("word.basic") With wdbasic .FileOpen "I:\PROTOKOL\" & yyyy & "\" & inv$ & b$ & "." & yy & iLOOP & ".doc" .EditPaste .FileSave .fileclose End With Set wdbasic = Nothing ______________________________________ any clue ? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Paste in WinWord, problems with several processes
Why are you using
CreateObject("word.basic") instead of CreateObject("Word.Application")??? For that matter, if you are going to open and work with a specific Word doc, then why not something like: Dim WD As Object Dim doc As Object Dim dName As String Set WD = CreateObject("Word.Application") dName = "I:\PROTOKOL\" & yyyy & "\" & inv$ & b$ & "." & yy & iLOOP & ".doc" Set doc = WD.Documents.Add dName With doc .EditPaste .FileSave .fileclose End With WD.Quit Set doc = Nothing Set WD = Nothing (Note: pieced together from previous macros; not tested like this) Ed "lasse g" <lasse wrote in message ... When using the following code, winword remain as an process in task-manager. That become a problem when I run the macro again and again. I had hundereds of processes running. _____________________________________ Dim wdbasic As Object Set wdbasic = CreateObject("word.basic") With wdbasic .FileOpen "I:\PROTOKOL\" & yyyy & "\" & inv$ & b$ & "." & yy & iLOOP & ".doc" .EditPaste .FileSave .fileclose End With Set wdbasic = Nothing ______________________________________ any clue ? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Paste in WinWord, problems with several processes
Hi Lasse,
When using the following code, winword remain as an process in task-manager. That become a problem when I run the macro again and again. I had hundereds of processes running. any clue ? . Well, I know that the same is happening when opening and closing Outlook... maybe its a whole Office task that closed programs are not unloaded from the task manager... This is no solution for your problem, I know, but I just want to give "my two cents" ;o) Best Markus |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Processes in one cell | Excel Discussion (Misc queries) | |||
Multiple Excel Processes | Excel Programming | |||
hiding processes | Excel Programming | |||
Open Winword from Excel | Excel Programming | |||
Open Winword-file using a Excel 97 VBA macro | Excel Programming |