|
-
Aug 29th, 2000, 06:08 AM
#1
Thread Starter
Member
Hello there, could (please) anyone help me with this annoying problem?
I'm making an application that has to put data on a simple Microsoft Word 2000 document. I use this code for it...
--Begin Code--
dim objWrdApp As Word.Application
On Error Resume Next
Set objWrdApp = GetObject(, "Word.Application.9")
If Err.Number = 429 Then
Set objWrdApp = CreateObject("Word.Application.9")
Err.Clear
End If
--End Code--
My application runs well until I -close- Microsoft Word myself or by code...
When I try to use the Word reference again in the same application (I didn't close it and it has ran the above declarations again), it gives me this Error message:
**********
Run-time error '462':
The remote server machine does not exist or is unavailable
**********
My application craches on all the code that uses the Word(.Global) functions, all the rest is OK.
-Begin Code-
With .ActiveDocument.PageSetup
.LineNumbering.Active = False
.Orientation = wdOrientPortrait
.TopMargin = CentimetersToPoints(0.2) <-- CRASH!
.BottomMargin = 7.1 '0.25 cm <-- Works fine without the function...
-End Code-
I don't know what the problem is but I need a solution QUICK cause I've got to make a deadline... (AAaargh)
Can Someone help me?
Thank You for Your time!
Bart Lipkens
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|