By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,847 Members | 2,402 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,847 IT Pros & Developers. It's quick & easy.

Trying to use the Word Application object in Microsoft Visual Basic .NET

P: n/a
Hi,

I'm using Microsoft Visual Basic .NET and want to reference the
ThisApplication variable but cannot get to it or find the OfficeCodeBehind
class. Is this a shortcomming of the fact that I have Microsoft Visual Basic
and not Visual Studio .NET?

On page:
http://msdn.microsoft.com/library/de...tionobject.asp I
read:
If you are working in Word, the Application object is automatically created
for you, and you can use the Application property to return a reference to
the Word Application object. When you are creating your solution in Visual
Studio .NET, you can use the ThisApplication variable defined for you within
the OfficeCodeBehind class. IntelliSense displays the list of collections,
methods, and properties for the Application object.

When you are referring to objects and collections beneath the Application
object, you do not need to explicitly refer to the Application object. For
example, you can refer to the active document without the Application object
by using the built-in ThisDocument property. ThisDocument refers to the
active document, and allows you to work with members of the Document object.

Regards,

Marcel
Jul 21 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
I can't find the Microsoft Word 9.0 or 10.0 object library also, it is not
present in the COM Components tab.

"Marcel" <m.*********@home.nl> schreef in bericht
news:32*************@individual.net...
Hi,

I'm using Microsoft Visual Basic .NET and want to reference the
ThisApplication variable but cannot get to it or find the OfficeCodeBehind
class. Is this a shortcomming of the fact that I have Microsoft Visual
Basic and not Visual Studio .NET?

On page:
http://msdn.microsoft.com/library/de...tionobject.asp I
read:
If you are working in Word, the Application object is automatically
created for you, and you can use the Application property to return a
reference to the Word Application object. When you are creating your
solution in Visual Studio .NET, you can use the ThisApplication variable
defined for you within the OfficeCodeBehind class. IntelliSense displays
the list of collections, methods, and properties for the Application
object.

When you are referring to objects and collections beneath the Application
object, you do not need to explicitly refer to the Application object. For
example, you can refer to the active document without the Application
object by using the built-in ThisDocument property. ThisDocument refers to
the active document, and allows you to work with members of the Document
object.

Regards,

Marcel

Jul 21 '05 #2

P: n/a
At last I found it. Thanks anyway.

Marcel

"Marcel" <m.*********@home.nl> schreef in bericht
news:32*************@individual.net...
Hi,

I'm using Microsoft Visual Basic .NET and want to reference the
ThisApplication variable but cannot get to it or find the OfficeCodeBehind
class. Is this a shortcomming of the fact that I have Microsoft Visual
Basic and not Visual Studio .NET?

On page:
http://msdn.microsoft.com/library/de...tionobject.asp I
read:
If you are working in Word, the Application object is automatically
created for you, and you can use the Application property to return a
reference to the Word Application object. When you are creating your
solution in Visual Studio .NET, you can use the ThisApplication variable
defined for you within the OfficeCodeBehind class. IntelliSense displays
the list of collections, methods, and properties for the Application
object.

When you are referring to objects and collections beneath the Application
object, you do not need to explicitly refer to the Application object. For
example, you can refer to the active document without the Application
object by using the built-in ThisDocument property. ThisDocument refers to
the active document, and allows you to work with members of the Document
object.

Regards,

Marcel

Jul 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.