+ Reply to Thread
Results 1 to 5 of 5

macro not running in other files

  1. #1
    Registered User
    Join Date
    05-27-2013
    Location
    Karachi
    MS-Off Ver
    Excel 2007
    Posts
    2

    Unhappy macro not running in other files

    i have created a macro in a file for converting numbers to words like "1,000" to "One Hundred Thousand Only". When I am copying this macro in other excel file, it does not work.

  2. #2
    Valued Forum Contributor john55's Avatar
    Join Date
    10-23-2010
    Location
    Europe
    MS-Off Ver
    Excel for Microsoft 365
    Posts
    2,028

    Re: macro not running in other files

    insert a module in yr (new) file, copy/paste the macro into it and run the macro, it shoulkd work!
    Regards, John55
    If you have issues with Code I've provided, I appreciate your feedback.
    In the event Code provided resolves your issue, please mark your Thread as SOLVED.
    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

    ...enjoy -funny parrots-

  3. #3
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,873

    Re: macro not running in other files

    As far as the code you are talking about is concerned, it is a Function Procedure isnt it?

    Copy the code to a Module of your new workbook.

    Thank You,

    Deep
    Cheers!
    Deep Dave

  4. #4
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,924

    Re: macro not running in other files

    If you want your code to work in all workbooks, create a Personal.xlsb file and store you macro in there. Here is a link to learn how to create a Personal.xlsb file.

    http://www.rondebruin.nl/win/personal.htm
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  5. #5
    Registered User
    Join Date
    05-27-2013
    Location
    Karachi
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: macro not running in other files

    it worked.. thanks alot

+ 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