+ Reply to Thread
Results 1 to 8 of 8

Message box to display range of cells. Solved, thanks

  1. #1
    Registered User
    Join Date
    12-03-2009
    Location
    yorkshire, england
    MS-Off Ver
    Excel 2003
    Posts
    15

    Message box to display range of cells. Solved, thanks

    Hi,

    I am using the following code to display a range of cells from a single column (A1:A10) in a message box, with each cell value on a seperate line.

    Please Login or Register  to view this content.
    My question is; how do I make it work so that it will display the value of cells from a row, ie A1:J1 ?

    Thanks.
    Last edited by henrysmith; 12-03-2009 at 09:11 AM.

  2. #2
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: message box to display range of cells

    Hi, The "Join" Function Specifies a One Dimensional Array.
    I think you would need something like the code below to achieve your Requirement.
    Please Login or Register  to view this content.
    Regards Mick

  3. #3
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: message box to display range of cells

    or even
    Please Login or Register  to view this content.
    If the solution helped please donate to RSPCA

    Site worth visiting: Rabbitohs

  4. #4
    Forum Contributor
    Join Date
    12-02-2009
    Location
    Akron, Ohio
    MS-Off Ver
    Excel 2010
    Posts
    208

    Re: message box to display range of cells

    Numerous ways to do it, here's another:

    Please Login or Register  to view this content.

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: message box to display range of cells

    henrysmith, welcome to the board... please note:

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code. Posting code without them makes your code hard to read and difficult to be copied for testing. Highlight your code and click the # at the top of your post window. For more information about these and other tags, found here

    Please edit your initial post in line with the above.


    For ref. use Join method as outlined - try to avoid iteration where possible

    To convert a horizontal vector to a single dimension array transpose the array twice over, eg:

    Please Login or Register  to view this content.

  6. #6
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: message box to display range of cells

    If only I'd read the Question !!!
    Here are some options:-
    Please Login or Register  to view this content.
    Regards Mick

  7. #7
    Registered User
    Join Date
    12-03-2009
    Location
    yorkshire, england
    MS-Off Ver
    Excel 2003
    Posts
    15

    Re: message box to display range of cells

    Thanks for all the replies,

    I have gone with donkeyotes, despite the mild rebuke

    ....how the hell do I update this message to "solved"?
    Last edited by henrysmith; 12-03-2009 at 08:56 AM.

  8. #8
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Message box to display range of cells. Solved, thanks

    see FAQ / How To but in general to quote the stock response:

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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