Results 1 to 4 of 4

Thread: Show formulas but not links

  1. #1

    Show formulas but not links



    Register for a FREE account, and/
    or Log in to avoid these ads!

    Hello,

    I'm wondering if it is possible to show excel formulas (not the links). For example, say Cell A1 = 100, Cell B1 = 2, Cell C1 = A1*B1, I'd like a code that converts Cell C1 to 100*2.

    Any help you can provide will be greatly appreciated. I need this to provide an audit trail for an accounting assignment.

    Thanks.

  2. #2
    Conjurer Simi's Avatar
    Join Date
    Feb 2012
    Location
    Utah, USA
    Posts
    187
    Articles
    0
    this can easily be done by simply changing the values of A and B to text to show in column C.
    just put =A1 & "*" & B1
    in cell C1 and there you go.

  3. #3
    Thanks for the quick response seeker. However, I need to do this for over 100 cells and I was looking for something less manual and time consuming.

  4. #4
    Conjurer Simi's Avatar
    Join Date
    Feb 2012
    Location
    Utah, USA
    Posts
    187
    Articles
    0
    Well it is fairly easy to copy and paste a formula even to 100 rows.
    or you can use this macro, provided you don't have any empty rows between data. like
    1
    2
    3

    5
    6
    7

    in the above example my code will only work on the first 3 lines, anyway here is the code.


    Code:
    Sub MyMacro()
    
    
    'declare row counter
    Dim rowCounter As Integer
    rowCounter = 1
    
    
    Do While IsEmpty(ActiveSheet.Range("A" & rowCounter)) = False
    ActiveSheet.Range("C" & rowCounter) = ActiveSheet.Range("A" & rowCounter) & "*" & ActiveSheet.Range("B" & rowCounter)
    rowCounter = rowCounter + 1
    Loop
    
    
    End Sub
    Hope it helps you,

    Simi

Posting Permissions

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