+ Reply to Thread
Results 1 to 3 of 3

Code Applicable for any workbook which is open

  1. #1
    Forum Contributor
    Join Date
    02-22-2012
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    102

    Code Applicable for any workbook which is open

    Hello,

    i have a vba code which is assigned to a command button. i would require this command button to be available for any workbook which is open ( and so it will be triggered - upon clicking - and should run) and the workbook in which i have this code need not be opened)

    can someone assist please..

  2. #2
    Forum Expert tigeravatar's Avatar
    Join Date
    03-25-2011
    Location
    Colorado, USA
    MS-Off Ver
    Excel 2003 - 2013
    Posts
    5,361

    Re: Code Applicable for any workbook which is open

    vidyuthrajesh,

    There are a couple of ways to go about what you're asking for. The easiest is probably to use the personal.xls file:
    http://office.microsoft.com/en-us/ex...001087296.aspx


    Another way, if you need to distribute the macro to multiple machines/users would be to make an excel add-in:
    http://www.cpearson.com/excel/createaddin.aspx
    http://msdn.microsoft.com/en-us/libr...ffice.10).aspx
    Hope that helps,
    ~tigeravatar

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Registered User
    Join Date
    10-08-2009
    Location
    Hull, England
    MS-Off Ver
    Excel 2003, Excel 2007
    Posts
    73

    Re: Code Applicable for any workbook which is open

    Stay away from me. And thisworkbook. Statements as that would only work in the current workbook.
    You may need to reference each seperate sheet or workbook in the code of the button or use the application. Variable for your code
    Like my post? Considered leaving Rep? Thanks.

+ 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