Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 447
Default Macro location

I have a macro in a workbook that was emailed with 2 additional workbooks
that need to use this macro. There seems to be a problem when they save the
master as a new name. They still have to bring up last month's spreadsheet to
access the macro. What are the rules for macro location and how can I
simplify this process for my users? Can it also be because they make a new
folder for each period and save the renamed master in it?.
--
Excelsolutions4U
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Macro location

While the code modules are saved to the new workbook along with the data on
the sheets, it can be problematic to run the code for a few reasons.

1. If the code references the name of the original workbook, it will throw
errors for subscript out of bounds.

2. If there are links to cells in the original workbook, then those links
are still there and the new workbook will be looking for those links.

and a few others. What you really need to do is contact the creator of the
workbooks and have them troubleshoot the problem.

"Karen" wrote:

I have a macro in a workbook that was emailed with 2 additional workbooks
that need to use this macro. There seems to be a problem when they save the
master as a new name. They still have to bring up last month's spreadsheet to
access the macro. What are the rules for macro location and how can I
simplify this process for my users? Can it also be because they make a new
folder for each period and save the renamed master in it?.
--
Excelsolutions4U

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 447
Default Macro location

I created the macros and audited the contents of all these spreadsheets.
There is no reference to the original sheet name in the macro. Other
spreadsheets are linked to the spreadsheets using the macro (source data
only). The original author is long gone, and it doesn't matter because I had
to do extensive revisions to accommodate a new payroll system. I will go
into the office and try to replicate their problems next week. Thanks for
trying, K

"JLGWhiz" wrote:

While the code modules are saved to the new workbook along with the data on
the sheets, it can be problematic to run the code for a few reasons.

1. If the code references the name of the original workbook, it will throw
errors for subscript out of bounds.

2. If there are links to cells in the original workbook, then those links
are still there and the new workbook will be looking for those links.

and a few others. What you really need to do is contact the creator of the
workbooks and have them troubleshoot the problem.

"Karen" wrote:

I have a macro in a workbook that was emailed with 2 additional workbooks
that need to use this macro. There seems to be a problem when they save the
master as a new name. They still have to bring up last month's spreadsheet to
access the macro. What are the rules for macro location and how can I
simplify this process for my users? Can it also be because they make a new
folder for each period and save the renamed master in it?.
--
Excelsolutions4U

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 46
Default Macro location

It is likely because they are changing the name of the file. If the code
contains any statements that refer to the original name of the workbook it
won't work in a new workbook without editing it. Is there a lot of code?
Can you find anything that references the old workbook name? If you can post
that section of code and I am sure that someone will be able to help you with
a better way to code that part.

Karen wrote:
I have a macro in a workbook that was emailed with 2 additional workbooks
that need to use this macro. There seems to be a problem when they save the
master as a new name. They still have to bring up last month's spreadsheet to
access the macro. What are the rules for macro location and how can I
simplify this process for my users? Can it also be because they make a new
folder for each period and save the renamed master in it?.


--
Message posted via http://www.officekb.com

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Macro location

How do you call the macros?

Did you place buttons (or other shapes) on the worksheet and then assign the
macro?

Did you attach a toolbar to the workbook that points at those macros?



Karen wrote:

I have a macro in a workbook that was emailed with 2 additional workbooks
that need to use this macro. There seems to be a problem when they save the
master as a new name. They still have to bring up last month's spreadsheet to
access the macro. What are the rules for macro location and how can I
simplify this process for my users? Can it also be because they make a new
folder for each period and save the renamed master in it?.
--
Excelsolutions4U


--

Dave Peterson


Reply
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
Macro - save to current location vs excel default location leezard Excel Discussion (Misc queries) 0 October 28th 08 03:04 PM
Macro location?? SpeedyR Excel Discussion (Misc queries) 0 September 4th 08 10:52 PM
How to call up a macro in a different location? Tom Excel Discussion (Misc queries) 1 December 18th 07 12:29 AM
Macro Storage Location Richard Excel Discussion (Misc queries) 1 September 18th 07 02:48 AM
macro changes sheet location alanmart Excel Programming 2 April 12th 07 09:52 PM


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

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

About Us

"It's about Microsoft Excel"