LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Same macro in two files

I have written a VBA macro in an excel file. If a user
loads the excel file, and a renamed version of the same
file Excel uses the macro from the last file loaded. If
the last file loaded is closed first, and then the macro
is again used, Excel wants to load the second file again.

If I have been unclear, perhaps this step-by-step view
will help:

Load file 1:
Load file 2:
Run Macro A
Close file 2:
Run Macro A (it exists in file 1)
Excel wants to load file 2

Is there a way to associate the macro only to the
particular XLS workbook?

Thank you.
Dave Miller
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
run a DOS .bat files under an excel macro B.M.Spell Excel Programming 1 October 27th 03 04:10 PM
Opening CSV files with VBA/macro Vasco[_2_] Excel Programming 3 August 12th 03 12:18 PM
Import multiple files macro can't find files Steven Rosenberg Excel Programming 1 August 7th 03 01:47 AM
Email files using macro David Fernandes Excel Programming 0 July 28th 03 05:25 PM
Run Macro on many files at once steve Excel Programming 0 July 23rd 03 11:52 PM


All times are GMT +1. The time now is 10:39 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"