# Cache tutorial help!

**URL:** <https://forum.kirupa.com/t/cache-tutorial-help/35290>\
**Category:** flash\
**Created:** [November 12, 2003, 11:37am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290 "2003-11-12T11:37:05Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![rave\_t](https://avatars.discourse-cdn.com/v4/letter/r/58956e/32.png) [@rave\_t](https://forum.kirupa.com/u/rave_t)\
**Post date:** [November 12, 2003, 11:37am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/1 "2003-11-12T11:37:05Z")

</div>

Can someone explaien how i should use those two lines of code?

I have one main.swf and one pic.swf. pic.swf is loaded from the maintimeline in main.swf with the command

loadMovie(“pic.swf”, “pic1”);

and i wnat to use the unique identifier but i dont know where to enter the code from…

[http://www.kirupa.com/developer/actionscript/tricks/cache.htm](http://www.kirupa.com/developer/actionscript/tricks/cache.htm)

any help would be great !:toad:

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 12, 2003, 11:53am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/2 "2003-11-12T11:53:55Z")

</div>

What is it you don’t understand? :h:

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 12, 2003, 11:56am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/3 "2003-11-12T11:56:33Z")

</div>

Exactly where to put the two line of codes?🅱

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 12, 2003, 11:57am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/4 "2003-11-12T11:57:31Z")

</div>

They replace your loadMovie line :bu:

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 12, 2003, 2:00pm UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/5 "2003-11-12T14:00:10Z")

</div>

well its not working cause i get an error message in the output window saying:

Error opening URL “file:///C|/Documents%20and%20Settings/rave\_t/Webbpage/pic.swf?uniq=7686”

What should i do?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 12, 2003, 2:19pm UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/6 "2003-11-12T14:19:20Z")

</div>

Test it on your browser.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 13, 2003, 7:33am UTC](https://forum.kirupa.com/t/cache-tutorial-help/35290/7 "2003-11-13T07:33:13Z")

</div>

I must be stupid…I cant get it to work !!

In my main timeline in main.swf i got this line:

loadMovie(“pic.swf”, “picHolder”);

Should i just do it like this??

myIdentifier=Math.round(Math.random()\*10000);  
loadMovie(“pic.swf?uniq=”+myIdentifier,“picHolder”);

?

Do i have to do anything in the pic.swf ??
