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.

Excel Workbook Question

Discussion in 'Business Applications' started by rjosepht, Jul 10, 2006.

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

    rjosepht Thread Starter

    Joined:
    Jul 10, 2006
    Messages:
    1
    Tech Support Guy,

    I have a question regarding linking two Excel (I am using Office 2003) workbooks and varying worksheets.
    Here's what I want to do, using a macro, create a link to a cell in workbook A/worksheet X to workbook B/worksheet X (where X is variable).
    Now creating a link is easy, except I want the "link" itself to appear in workbook A.
    I tried the following:
    Workbooks("Workbook A.xls").Worksheets(Worksheet A).Cells(6, 4).Value _
    = Workbooks("Workbook B.xls").Worksheets(Worksheet A).Cells(57, 3).Value
    However, Excel places the value instead of the link in the cell. I want both, meaning, you see the value in the cell, but when you highlight the cell, you see the link to the 2nd workbook.

    I have also tried the the following:
    Workbooks("Workbook A.xls").Worksheets(Worksheet A).Cells(6, 4).Value _
    = "='[Workbook B.xls] Worksheet A '!R57C3"
    This gets me what I need except as I mentioned, the worksheets vary and I have not been able to figure out how to do use a variable worksheet name in this example.
    I appreciate your help in solving this problem
    Take care,
    RJ
     
  2. WhitPhil

    WhitPhil Gone but never forgotten Trusted Advisor

    Joined:
    Oct 4, 2000
    Messages:
    8,684
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/482068

  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