+ Reply to Thread
Results 1 to 11 of 11

Excel Formula for Comments?

  1. #1
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Excel Formula for Comments?

    It seems there was some confusion regarding my previous thread that was closed, which can be found here:
    http://www.excelforum.com/excel-prog...ml#post2390707

    My original question is the same:
    Is there a way to copy/get the "comments" of a cell using an excel formula?
    i.e. if A1 contains a comment, copy that comment to B1?

    What I meant by "locked" in the previous thread is that the VBA portion is locked out, and therefore I cannot run the macro within that specific file. The intent is not to crack the password, or get around password protection (in the sense of maliciously accessing data).
    I can easily just copy and paste all the cells from the VBA-locked file and then copy it into my new file, but because this locked file is constantly being updated, I can't have a current update report without the "human macro" of copying and pasting these cells.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Excel Formula for Comments?

    Cross posted here: http://www.mrexcel.com/forum/showthread.php?t=498249

    GunNam please ready this: http://www.excelguru.ca/node/7

    Dom
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Excel Formula for Comments?

    For info a macro can as easily be written to run on any workbook as the one that contains the code. You could store the code that you want to run in another workbook and just open that whenever you want to run it or in an add-in that will always be available to you.

    Dom

  4. #4
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Excel Formula for Comments?

    Quote Originally Posted by Domski View Post
    Dom,

    Thanks for bringing that to my attention.

  5. #5
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Excel Formula for Comments?

    Quote Originally Posted by Domski View Post
    For info a macro can as easily be written to run on any workbook as the one that contains the code. You could store the code that you want to run in another workbook and just open that whenever you want to run it or in an add-in that will always be available to you.

    Dom
    Thanks for this, but I am not looking for a way to do it in a macro, I am looking for an Excel formula, if one even exists.

  6. #6
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Excel Formula for Comments?

    No problem.

    As I said on Mr Excel I'm pretty sure it's not possible with a formula.

    Dom

  7. #7
    Forum Expert
    Join Date
    06-25-2009
    Location
    Sofia, Bulgaria, EU
    MS-Off Ver
    Excel 2003-2013
    Posts
    1,290

    Re: Excel Formula for Comments?

    you can have UDF, stored in a addin or personal workbook, that will get cell reference as an argument and return the comment text.
    If you are pleased with a member's answer then use the Star icon to rate it.

  8. #8
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Excel Formula for Comments?

    buran, I think you just gave me an idea... I'm going to go test it out.

  9. #9
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Excel Formula for Comments?

    Before I over complicate things:
    I found this thread: http://www.excelforum.com/excel-prog...cel4macro.html

    Is there a way to pull the comment in the above example instead of the value?

  10. #10
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Excel Formula for Comments?

    Not sure to be honest but a UDF like this should do the trick:

    Please Login or Register  to view this content.

    Dom

  11. #11
    Registered User
    Join Date
    09-28-2010
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Excel Formula for Comments?

    Thanks Dom, but my goal is to be able to call it (formula) within ExecuteExcel4Macro.
    On my previous post I linked a thread that has this code in it which is similar to what I'm running to retrieve the values of the cells:

    Please Login or Register  to view this content.
    Unless I'm mistaken, I believe I should be able to enter a FORMULA in the following part of the code... hopefully there is a formula to extract comments.
    Please Login or Register  to view this content.

    GunNam

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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