I have 2 seperate pages where I need to use a single excel attachment and I need this attachment to display an excel macro. If I attach the excel file on one page I can create an excel macro on that particular page. In order to display the same file on the other page I have to again attach the same file on the other page. Is there a way to use the attachment on one page on another page and use it to display excel macro.
Thanks
Sunny
If the attachment is viewable on both pages, perhaps you could wrap the Excel Macro in an Except Macro on one page, then use the Except Include Macro on the other.
Just in addition to Jamie and David. If you face this problem quite a lot I'd suggest creating an Inclusions Library as described here:
Using Confluence, you can dynamically include content from one page into another page. You can include a whole page into another one, using the Include macro. You can also define an ‘excerpt’ on a page, and then include that excerpted text into another page using the Excerpt Include macro.
To organise your re-usable content, we recommend that you create a set of pages called an 'inclusions library'.
- Open the 'Browse' menu and select 'Pages'.
- The 'List Pages' screen will appear. Open the 'Add' menu and select 'Page'.
This will add a page at the root of the space, at the same level as the home page.- Enter a suitable title. We use '_InclusionsLibrary'. The unusual format of the title helps to let people know this page is special.
- Enter some content on the page. We enter text explaining the purpose of the inclusions library and how to re-use the content. You can copy our text by clicking through to one of the example pages listed below.
- Add child pages containing your re-usable content. See the examples of our own inclusions libraries listed below.
Some notes about inclusions libraries:
- The inclusions library is not a specific feature of Confluence. The pages in the inclusions library are just like any other Confluence page.
- The pages are located at the root of the wiki space, not under the home page. This means that they will not appear in the table of contents on the left and they will not be picked up by the search in the left-hand navigation bar either.
- The pages will be picked up by other searches, because they are just normal wiki pages.
- We have decided to start the page name with an underscore. For example, '_My Page Name'. This indicates that the page is slightly unusual, and will help prevent people from changing the page name or updating the content without realising that the content is re-used in various pages.
Examples of Inclusions Libraries
Here are some examples in our documentation:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If Jamie's suggestion works, it would obviously be the simplest. Otherwise, if you have the Reporting Plugin, you can use {report-on} to allow the attachment to execute in the context of the other page. Something like this:
{report-on:value:content "Other Page Name"}{view-excel:my.xls}{report-on}
You could turn it into a User Macro to make life simpler if you do this a lot.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can't you refer to the attachment using the page name, ie SomePage^file.xls, then have it on both pages using the {include} macro?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.