Closed Thread
Results 1 to 2 of 2

VBA creating variable name not working

  1. #1
    Registered User
    Join Date
    04-04-2020
    Location
    Palo Alto, CA
    MS-Off Ver
    365
    Posts
    12

    VBA creating variable name not working

    I'm using a button/macro to generate a new sheet based on a template and then create a reference card ("card") on the master sheet ("Board") that previews a couple cell references ("title" and "owner") on the new sheet and has a hyperlink to take you to the new sheet. My challenge is that I'm trying to use a variable name to ensure that the reference card links to the new sheet instead of the template and it isn't working. The first half of the code works great and copies the "template" sheet well and names it ("Id1, Id2, Id3, etc.") using a variable name (strNewName), but I can't seem to use that variable name with the referencing. My grouping also doesn't seem to be working. Any help you can offer would much appreciated.

    HTML Code: 
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,933

    Re: VBA creating variable name not working

    Thread closed in favour of the one opened in the commercial services forum.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

Closed Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Error handling not working in "vba object variable or with block variable not set" in Loop
    By caabdul in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-23-2019, 06:40 PM
  2. Filter with a variable and select sheet with a variable not working
    By Jubb in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-29-2017, 04:23 PM
  3. [SOLVED] creating variable within Sub to run a Function
    By RSa in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-21-2016, 03:45 PM
  4. [SOLVED] creating a variable range in VBA to be copied to variable sheets
    By adamNBU in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 09-29-2013, 06:20 PM
  5. Call a constant/variable by creating another variable
    By pienaaj in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-12-2013, 10:36 AM
  6. Creating a formula with a variable
    By sk51 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 07-14-2008, 10:10 AM
  7. Creating Variable stanines
    By Redbeard45 in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 04-01-2007, 07:56 AM

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