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

I've exported several macros to be imported into other workbooks when they
are first used.

When a macro is imported it retains the link to the original workbook. How
do I remove the links?

It's likely I'm missing somehting obvious but I'm lost for looking.

--
Jim
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 132
Default Macro links to other workbooks

Correction: they aren't linked to the original workbook. It's the name of
thisworkbook. When I write a macro that creates the buttons, I can't put
thisworkbook.name in the "OnAction" command.
--
Jim


"Jim G" wrote:

I've exported several macros to be imported into other workbooks when they
are first used.

When a macro is imported it retains the link to the original workbook. How
do I remove the links?

It's likely I'm missing somehting obvious but I'm lost for looking.

--
Jim

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Macro links to other workbooks

This kind of thing works for me:

..OnAction = "'" & ThisWorkbook.Name & "'!" & "somemacronamehere"

Jim G wrote:

Correction: they aren't linked to the original workbook. It's the name of
thisworkbook. When I write a macro that creates the buttons, I can't put
thisworkbook.name in the "OnAction" command.
--
Jim

"Jim G" wrote:

I've exported several macros to be imported into other workbooks when they
are first used.

When a macro is imported it retains the link to the original workbook. How
do I remove the links?

It's likely I'm missing somehting obvious but I'm lost for looking.

--
Jim


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 132
Default Macro links to other workbooks

Thanks Dave, worked perfectly. The double quotes and apostrophe's get me
every time!
--
Jim


"Dave Peterson" wrote:

This kind of thing works for me:

..OnAction = "'" & ThisWorkbook.Name & "'!" & "somemacronamehere"

Jim G wrote:

Correction: they aren't linked to the original workbook. It's the name of
thisworkbook. When I write a macro that creates the buttons, I can't put
thisworkbook.name in the "OnAction" command.
--
Jim

"Jim G" wrote:

I've exported several macros to be imported into other workbooks when they
are first used.

When a macro is imported it retains the link to the original workbook. How
do I remove the links?

It's likely I'm missing somehting obvious but I'm lost for looking.

--
Jim


--

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 to open, Update links, save and close workbooks Anton Excel Discussion (Misc queries) 0 January 7th 10 03:18 AM
Slow opening links between workbooks with links created in 2003 Russell Excel Discussion (Misc queries) 0 December 14th 09 02:59 PM
Updating Workbooks from multiple links Workbooks TimJames Excel Worksheet Functions 1 December 15th 07 03:34 PM
Macro to copy from workbooks listed as http links Nick Smith[_2_] Excel Programming 8 April 29th 06 06:12 PM
Update links to other workbooks while running macro [email protected] Excel Programming 5 July 28th 05 06:17 AM


All times are GMT +1. The time now is 10:31 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"