Jump to content

object properties


Recommended Posts

Hi Guys, 
 
I am now working with excel and when you look to AutoIt help for, let's say _Excel_RangeCopyPaste Example 2 - there is line
 
Local $oRange = $oWorkbook2.Worksheets(1).Range("A1")
I understand .worksheets(1) and .range are the properties of the Excel workbook object.
 
But how can I know, what properties are available for specific objects?
 
Is there anything like get-help -detailed in powershell?
 
This is not crucial, I am just curious, because things like that can help shorten and optimize the code. 
 
Thank you
 
Filla
 
Link to comment
Share on other sites

Every such object has its interface description defined somewhere. You can get that "place" in AutoIt using ObjName() function:

$sFileWithDefinition = ObjName($oObject, 4)

ConsoleWrite($sFileWithDefinition & @CRLF)

When you know where the definition is, the only thing that you have to do is use some tool to read definitions (methods, properties, ...) from it. My favorit is >TYPELIB Viewer written in AutoIt, but other exist too, just search the web.

♡♡♡

.

eMyvnE

Link to comment
Share on other sites

Thanks a lot guys, it makes sense now!!! And thanks for link, looks very useful. Actually I happy from the answer, because last weeks I am having more and more fun with autoit, vbs and PSH, so if the properties are something general, it makes my life much easier. Thanks again!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...