• 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: get row number of first empty cell in Excel
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: get row number of first empty cell in Excel


  • Subject: Re: get row number of first empty cell in Excel
  • From: Barry Wainwright <email@hidden>
  • Date: Mon, 14 Dec 2009 00:23:16 +0000

first row index of foundRange

if the range may have more than one row (not likely in your case) then you can add the height of the range as well:

(first row index of foundRange) -1 + (height of foundRange)

-- 
Barry




On 13 Dec 2009, at 22:43, Mason wrote:

Hey AppleScripters,

I have an Excel document which I am working with and
though I know how to find the first empty cell in a range
I do not know how to get the exact number of the cell.

So my script contains:

tell application "Microsoft Excel"
set foundRange to find range "A:A" what ""
end tell

The result is:

range "'[spreadsheet1.csv]spreadsheet1.csv'!$A$962" of application "Microsoft Excel"

I want to extract the '962' row number out of that result so I can set it to
a variable and perform other functions in the script.

I inserted another line: "get properties of foundRange" and then
played around with text item delimiters but couldn't get it.

Does anyone know how to extract the row number of the first empty cell 
and then set it to a variable?

Thanks in advance for 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
References: 
 >get row number of first empty cell in Excel (From: Mason <email@hidden>)

  • Prev by Date: Re: How do I pause a script to allow a webpage to load and then resume the script?
  • Next by Date: Re: get row number of first empty cell in Excel
  • Previous by thread: get row number of first empty cell in Excel
  • Next by thread: Re: get row number of first empty cell in Excel
  • Index(es):
    • Date
    • Thread