ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Modelling Object Models (https://www.excelbanter.com/excel-programming/374399-modelling-object-models.html)

John[_88_]

Modelling Object Models
 
Hi there,

Can anyone tell me how to go about modelling an Office object model.

The part I'm not sure of is how to iterate through the objects and methods
etc.

Would you start with looping through the Application object and then go from
there and if so how would you get hold of the various names of those objects
and methods?

Best regards

John



NickHK[_3_]

Modelling Object Models
 
John,
If you mean in code to loop through the properties, methods etc, basically
you can't.
There may be components that can examine the type library and present them
in some way like that, but natively, it's not supported.

If you mean to research/learn the object model, the Object Browser will show
you all available. And help has a section on the hierarchy of objects.
There's also app like Type Library Explorer that may be useful.

NickHK

"John" bl...
Hi there,

Can anyone tell me how to go about modelling an Office object model.

The part I'm not sure of is how to iterate through the objects and methods
etc.

Would you start with looping through the Application object and then go
from there and if so how would you get hold of the various names of those
objects and methods?

Best regards

John




John[_88_]

Modelling Object Models
 
Hi Nick,

Thanks for your reply. Yes, its the first one really. I'd like to be able
to print off different versions and manipulate what to show.

Do you think this would be easier in VB.NET (I appreciate this is geting out
of scope of the NG)?

Anyway thanks for your time.

Best regards

John

"NickHK" wrote in message
...
John,
If you mean in code to loop through the properties, methods etc, basically
you can't.
There may be components that can examine the type library and present them
in some way like that, but natively, it's not supported.

If you mean to research/learn the object model, the Object Browser will
show you all available. And help has a section on the hierarchy of
objects.
There's also app like Type Library Explorer that may be useful.

NickHK

"John"
bl...
Hi there,

Can anyone tell me how to go about modelling an Office object model.

The part I'm not sure of is how to iterate through the objects and
methods etc.

Would you start with looping through the Application object and then go
from there and if so how would you get hold of the various names of those
objects and methods?

Best regards

John






NickHK

Modelling Object Models
 
John,
This will get you started
http://www.devx.com/vb2themax/Tip/19223

This sounds it's what you're after
http://msdn.microsoft.com/msdnmag/issues/1200/TypeLib/
"The built-in Object Browser in Visual Basic, like other component browsers
such as OLE View and XRay, is one of the more useful tools. But an even
better tool would be customizable. You can build your own type library
browser using the TypeLib Information Object Library (TLI), a set of COM
objects designed to allow programmers to browse type libraries
programmatically."

NickHK

"John" wrote in message
...
Hi Nick,

Thanks for your reply. Yes, its the first one really. I'd like to be

able
to print off different versions and manipulate what to show.

Do you think this would be easier in VB.NET (I appreciate this is geting

out
of scope of the NG)?

Anyway thanks for your time.

Best regards

John

"NickHK" wrote in message
...
John,
If you mean in code to loop through the properties, methods etc,

basically
you can't.
There may be components that can examine the type library and present

them
in some way like that, but natively, it's not supported.

If you mean to research/learn the object model, the Object Browser will
show you all available. And help has a section on the hierarchy of
objects.
There's also app like Type Library Explorer that may be useful.

NickHK

"John"
bl...
Hi there,

Can anyone tell me how to go about modelling an Office object model.

The part I'm not sure of is how to iterate through the objects and
methods etc.

Would you start with looping through the Application object and then go
from there and if so how would you get hold of the various names of

those
objects and methods?

Best regards

John








John[_88_]

Modelling Object Models
 
Nick, that's perfect! Thanks very much for your time.

Best regards

John

"NickHK" wrote in message
...
John,
This will get you started
http://www.devx.com/vb2themax/Tip/19223

This sounds it's what you're after
http://msdn.microsoft.com/msdnmag/issues/1200/TypeLib/
"The built-in Object Browser in Visual Basic, like other component
browsers
such as OLE View and XRay, is one of the more useful tools. But an even
better tool would be customizable. You can build your own type library
browser using the TypeLib Information Object Library (TLI), a set of COM
objects designed to allow programmers to browse type libraries
programmatically."

NickHK

"John" wrote in message
...
Hi Nick,

Thanks for your reply. Yes, its the first one really. I'd like to be

able
to print off different versions and manipulate what to show.

Do you think this would be easier in VB.NET (I appreciate this is geting

out
of scope of the NG)?

Anyway thanks for your time.

Best regards

John

"NickHK" wrote in message
...
John,
If you mean in code to loop through the properties, methods etc,

basically
you can't.
There may be components that can examine the type library and present

them
in some way like that, but natively, it's not supported.

If you mean to research/learn the object model, the Object Browser will
show you all available. And help has a section on the hierarchy of
objects.
There's also app like Type Library Explorer that may be useful.

NickHK

"John"
bl...
Hi there,

Can anyone tell me how to go about modelling an Office object model.

The part I'm not sure of is how to iterate through the objects and
methods etc.

Would you start with looping through the Application object and then
go
from there and if so how would you get hold of the various names of

those
objects and methods?

Best regards

John











All times are GMT +1. The time now is 02:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com