Periodic refreshing in macro

ket.pjwstk
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 27, 2011

Hi,

I want to implement macro that refresh every, let say, 5 seconds. How can I achive?

For example. Is there anyway to periodically call specifi macro execute?

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

0 votes
Answer accepted
MatthewC
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 27, 2011

Easiet way is to create a user macro.

  • call it refresh-page
  • no macro body
  • Macro generates HTML

Then for the macro contents use:

<script type="text/JavaScript">

<!--

setTimeout("location.reload(true);",$param0);

// -->

</script>

Reload page: $param0 ms.

Usage:

{refresh-page:2000}

If you want, you could put some more code in so the parameter is in seconds, let me know & I can update it.

ket.pjwstk
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 28, 2011

That reloads the whole page and I want to only refresh my macro area. Besides I cant predict on which page that macro would be needed.

MatthewC
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 7, 2011

What are yolu trying to get to refresh? The results of some other macro? If you can give some more details it might be easier to work out. You could use this with an iframe macro to refresh a section of a page?

TAGS
AUG Leaders

Atlassian Community Events