+ Reply to Thread
Results 1 to 3 of 3

Why do I have to create a new sub?

  1. #1
    Forum Contributor
    Join Date
    02-13-2013
    Location
    Columbia, SC
    MS-Off Ver
    Excel 2010
    Posts
    217

    Why do I have to create a new sub?

    Why when I put the following code does it ask me to create a sub name? And can someone help me so that it doesnt? I just want to paste then into module, click play, and it works without making me open another sub

    Please Login or Register  to view this content.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Why do I have to create a new sub?

    What exactly do you mean, I've never been asked by VBA to create a new sub.

    Where are you pasting the code?

    By the way, are you sure you want this code to run every time the selection is changed to select something in the range X:AI?
    If posting code please use code tags, see here.

  3. #3
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,643

    Re: Why do I have to create a new sub?

    Do you already have a Worksheet_SelectionChange procedure? You can only have one procedure like this for a given worksheet.

    If you had two, you could combine their code between the start and end of one procedure

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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