+ Reply to Thread
Results 1 to 6 of 6

Contents of Rightmost Cell

  1. #1
    Registered User
    Join Date
    06-13-2012
    Location
    Singapore
    MS-Off Ver
    Excel
    Posts
    39

    Contents of Rightmost Cell

    Hi everyone,

    I'm looking to get the contents for the rightmost cell of a range selection.

    The contents would be the input for standard excel formulas.

    I've tried a mix of standard formulas but they only seem to work for pure text or numbers. The range I have consists of both text and numbers. (Just for reference the link I used to construct the formula: http://answers.microsoft.com/en-us/o...c-68b599b31bf5)

    Can someone provide a vba formula for this purpose? The input to this vba formula would be the range and the output the contents of the rightmost cell.

    Thanks in advance,
    Andrew

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Contents of Rightmost Cell

    Assuming a single-area range,

    Please Login or Register  to view this content.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    06-13-2012
    Location
    Singapore
    MS-Off Ver
    Excel
    Posts
    39

    Re: Contents of Rightmost Cell

    Hi the following gives a #Value error:

    Function RightMostCell()
    myValue = myRange(1, myRange.Columns.Count).Value2
    RightMostCell = myValue
    End Function


    I've used it in the workbook as:
    "=RightMostCell(INDIRECT(JU9))"

    Indirect references the range where the rightmost cell is wanted. The range is a row eg. "EA9:FA9"

    Please assist to advise? Thanks!

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Contents of Rightmost Cell

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    06-13-2012
    Location
    Singapore
    MS-Off Ver
    Excel
    Posts
    39

    Re: Contents of Rightmost Cell

    Hi sorry think I need to clarify. I'm looking to get the rightmost cell with data and to ignore blanks. The range includes cells that contain either text, numbers or blanks.

  6. #6
    Registered User
    Join Date
    06-13-2012
    Location
    Singapore
    MS-Off Ver
    Excel
    Posts
    39

    Re: Contents of Rightmost Cell

    Hi everyone, any one have any ideas? Still looking for a solution to this. Thanks!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. look for the rightmost cell with data
    By JakeAy in forum Excel General
    Replies: 2
    Last Post: 04-01-2010, 05:31 AM
  2. how to delete the 4 rightmost digits from a cell
    By charlene in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-29-2006, 10:15 AM
  3. [SOLVED] Formula ? Return value from rightmost non-blank cell in a row of
    By Aladin Akyurek in forum Excel Formulas & Functions
    Replies: 18
    Last Post: 09-06-2005, 02:05 PM
  4. [SOLVED] Formula ? Return value from rightmost non-blank cell in a row of
    By tgdavis in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 12:05 PM
  5. Formula ? Return value from rightmost non-blank cell in a row of
    By tgdavis in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 11:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1