1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

cell value displayed in another cell

Discussion in 'Business Applications' started by scouse13, Nov 21, 2011.

Thread Status:
Not open for further replies.
  1. scouse13

    scouse13 Thread Starter

    Joined:
    Oct 29, 2009
    Messages:
    137
    hi guys

    on a worksheet i would like cell c5 to show the value thats been entered in any other cell thats is selected, obviously i can use = to show a single cells value but what code do i need to show any value the user selects,i.e
    c5 is the main cell that displays whatever other cell value is selected
    if d6 has a value entered of 100 and the user highlights this cell the result is shown in c5
    if e6 has a value entered of 50 and the user highlights this cell the result is shown in c5

    i hopei have explained this ok,any help appreciated
     
  2. bomb #21

    bomb #21

    Joined:
    Jul 1, 2005
    Messages:
    8,546
    "what code"?

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    If Target.Address <> "C5" Then
    Range("C5") = Target.Value
    End If
    End Sub
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1027900

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice