• 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: Excel 2004 issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Excel 2004 issue


  • Subject: Re: Excel 2004 issue
  • From: Paul Berkowitz <email@hidden>
  • Date: Fri, 18 Dec 2009 10:39:12 -0800
  • Thread-topic: Excel 2004 issue

Title: Re: Excel 2004 issue
That sounds as if you have a localized version of Excel which uses different punctuation in formulas, but AppleScript doesn't know about it. You're probably set in OS X International prefs to use the comma (not period) as decimal point. In your version of Excel that may trigger the "punctuation" separating elements in formulas and functions to be semicolon rather than comma - or it may be set like that always. (I've never heard of this before.) There's no preference for this behavior, at least not in the US version of Excel.  Check Excel Help for COUNTIF and other formals - does it show the semicolon as the separator within the parentheses? Is this true in both Excel 2004 and 2008? Anyway, AppleScript is evidently not localized and just knows the US version.

If you can tell me which localized version of Excel you have (or which country you bought it in) and confirm that it uses the semicolon in 2008 in formulas, I'll make inquiries. It's some sort of bug.

--
Paul Berkowitz



From: Jan Bultereys <email@hidden>
Date: Fri, 18 Dec 2009 10:48:02 +0100
To: Paul Berkowitz <email@hidden>, AppleScript-Users <email@hidden>
Subject: Re: Excel 2004 issue

Hi Paul,

You are right it worked with the comma.... And no I didn’t typed any error... I just copied the code generated from excel (2004-2008) back into the script which is with at semicolon.

So changing the semicolon in a comma worked from the script ...But when I look at the code in Excel it changed back to semicolon.... Really odd.

Anyway you helped me out Paul thanks for the fix!

Kind regards,jan







From: Paul Berkowitz <email@hidden>
Date: Thu, 17 Dec 2009 09:11:27 -0800
To: "email@hidden" <email@hidden>
Subject: Re: Excel 2004 issue

There were bugs in 2004 that were fixed in 2008. This may be one of those.

Isn't it good they fix bugs sometimes?

Is there any workaround using 'value' instead of 'formula'? (I no longer have 2004.) It should work the same.

However, note you have an error in that script - it shouldn't work in Excel 2008 either (and doesn't here). Between the C:C600 and A2 you have a semicolon (;) - it should be a comma (,). Perhaps the problem is simply that when Excel 2008 you typed the script correctly and when using 2004 you didn't?

--
Paul Berkowitz



From: Jan Bultereys <email@hidden>
Date: Thu, 17 Dec 2009 14:33:04 +0100
To: AppleScript-Users <email@hidden>
Subject: Excel 2004 issue

Does anyone knows why this works in Excel 2008 and not in Excel 2004 (version 11.5.5)

tell application "Microsoft Excel"
    tell active sheet of active workbook
       set inputFormula to "=COUNTIF(C8:C600;A2)"
        set formula of cell "D2" to inputFormula
   end tell
end
tell

I don’t get an error, the formula just doesn’t get placed in the cell.

Other formulas eg.
=COUNT(C8:C600) seems to work without any problem

Many thanks for any feedback
Jan



_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden


_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Excel 2004 issue
      • From: Yvan KOENIG <email@hidden>
    • Re: Excel 2004 issue
      • From: Yvan KOENIG <email@hidden>
References: 
 >Re: Excel 2004 issue (From: Jan Bultereys <email@hidden>)

  • Prev by Date: re: constant folding
  • Next by Date: Re: Trying to convert QXP Annotate script to work for InDesign
  • Previous by thread: Re: Excel 2004 issue
  • Next by thread: Re: Excel 2004 issue
  • Index(es):
    • Date
    • Thread