Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Words 97,2000,2002
Message
From
16/10/2002 10:11:01
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
Words 97,2000,2002
Miscellaneous
Thread ID:
00711701
Message ID:
00711701
Views:
49
I don't have Word2002(xp), so I wonder if someone can confirm something for me. I'm working from an error that one of our clients is getting. He's on Windows XP using Word XP. The company I work for does not support either, so I have neither to work with.

I'm using Word for spell checking. In word97 and word2000 the code works fine, but in Word XP an error is being produced.

In Word97 and Word2000, in spite of the information in the Word vba help files, I can change the windowstate of the word object without first having to activate it. However, it appears as though MSFT has 'fixed' this in Word XP. He's getting an OLE error that Word is Maximized. This happens on a piece of code that tries to move Word (which cannot be done if it is maximized).

Of Course, word cannot be activated if it is not visible, so it appears to me that the code must do something like the following:
If oWord.WindowState <> wdWindowStateNormal
   oWord.Visible = .T.
   oWord.Activate()
   oWord.WindowState = wdWindowStateNormal
   oWord.Visible = .F.
Endif
oWord.Move(x,y)
This seems to me as though this is going to look pretty ugly. Am I correct that this is what I'll need to do?

Alan
Reply
Map
View

Click here to load this message in the networking platform