• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Getting list of open files in Excell
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Getting list of open files in Excell


  • Subject: Re: Getting list of open files in Excell
  • From: Zsolt Magyar <email@hidden>
  • Date: Tue, 14 Aug 2001 17:08:48 +0200

Dear All/Ehsan,

Not even your suggestion will work as it again comes down to the point that
the Window doesn't have a Name property. Some further digging showed that
the Workbook has a Name property and you end up with a same thing.

But as Ehsan explained, you still can't use the "of every Workbook" so you
have to go with the loop and ID number.

What remains a mystery is how does then the:
----
Activate Window "Workbook1"
----
work? (I got this by recording the script)

Just another M$ thing.

Thanks to all reading my mail and to Ehsan replying to it.

Zsolt

>
> welcome to the bugzilla ;>
>
> Open Excel's dictionary in your editor, look at the elements of the
> application class they all say:
>
> <element name> by numeric index, by name
>
> none says by range. That's why you can't use: get <property> of "every"
> <element>
> You can only get properties by index and name. So you may want to try
> like this:
>
> --------
> set winList to {}
> tell application "Microsoft Excel"
> try
> repeat with x from 1 to 666
> set end of winList to Name of Window x
> end repeat
> on error
> end try
> end tell
> --------
>
> cheers
> ehsan


>> Dear All,
>>
>> First of all pls reply to me directly as I'm not on the list. Unfortunately
>> I can take some time for scripting just occasionally.
>>
>> The task is quite simple. I need to find out if a certain file is already
>> open in Excel or not.
>>
>> As I couldn't find a way to check for open files I thought I get a list of
>> open windows. This approach works fine almost everywhere except in Excel.
>>
>> First the window class doesn't have a name property, but if I compile a code
>> like
>>
>> "get name of every window"


  • Prev by Date: what makes this droplet return extra info
  • Next by Date: airport software base station script?
  • Previous by thread: Re: Getting list of open files in Excell
  • Next by thread: does property exists in a record
  • Index(es):
    • Date
    • Thread