+ Reply to Thread
Results 1 to 4 of 4

Vb- How to return value instead of formula

  1. #1
    Registered User
    Join Date
    05-25-2009
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    9

    Vb- How to return value instead of formula

    Hey dudes/dudettes

    I need the K3:K9 range to copy only the value and not the formula for the cells. Ive just started with vb and although im finding it hard to use im finding it incredibly interesting. Any help would be greatly appreciated.

    Thanks

    Andrew

    Below is my script.

    Sub Yay()
    Dim rng, dest As Range
    Worksheets("Calendar").Activate
    Set rng = Range("N3:N8")
    rng.Copy
    Worksheets("Enquiry Sheet").Activate
    Set dest = Cells(Rows.Count, "b").End(xlUp).Offset(1, 0)
    dest.PasteSpecial Transpose:=True
    Application.CutCopyMode = False
    Worksheets("Calendar").Activate
    Set rng = Range("K3:K9")
    rng.Copy
    Worksheets("Enquiry Sheet").Activate
    Set dest = Cells(Rows.Count, "b").End(xlUp).Offset(0, 5)
    dest.PasteSpecial Transpose:=True
    Application.CutCopyMode = False
    Worksheets("Calendar").Activate
    End Sub

  2. #2
    Forum Expert
    Join Date
    10-10-2008
    Location
    Northeast Pennsylvania, USA
    MS-Off Ver
    Excel 2007
    Posts
    2,387

    Re: Vb- How to return value instead of formula

    Bing005,

    Try:

    Please Login or Register  to view this content.

    If the above does not work, then please post your workbook - scroll down and see "Manage Attachments".
    Have a great day,
    Stan

    Windows 10, Excel 2007, on a PC.

    If you are satisfied with the solution(s) provided, please mark your thread as Solved by clicking EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.

  3. #3
    Registered User
    Join Date
    05-25-2009
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: Vb- How to return value instead of formula

    You've probably heard this before, but Stan you are the man!

    Thank you very much. It works great. Just need to realign a few cells.

  4. #4
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983

    Re: Vb- How to return value instead of formula

    Bing005

    Your Original 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 Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

+ 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