Nel file in cui farai il loadMovie sul frame incolli il codice
devi cambiare i valori in rosso che corrispondono al nome del file e alle misure che vuoi assegnargli.codice://nome="prova"; // function: loadFlashPaper // ------------------------ // Load FlashPaper document, size it, // Parameters: // path_s: Path of SWF to load // dest_mc: Movie clip to hold the imported SWF // width_i: New size of the dest MC // height_i: New size of the dest MC // loaded_o: (optional) Object to be notified that loading is complete function loadFlashPaper(path_s, dest_mc, width_i, height_i, loaded_o) { var intervalID = 0; var loadFunc = function(){ dest_mc._visible = false; var fp = dest_mc.getIFlashPaper(); if (!fp) { return; } else if (fp.setSize(width_i, height_i) == false) { return; } else { clearInterval(intervalID); var pages_i = fp.getNumberOfPages(); ctrlHolder_mc.swapDepths(_root.control_mc); dest_mc._visible = true; // Now show the document _root.control_mc._visible = true; // Now show the controller loaded_o.onLoaded(fp); } } intervalID = setInterval(loadFunc, 100); dest_mc.loadMovie(path_s); } // function: onLoaded() // ------------------------ // Called once loading is complete // Parameters: // fp: FlashPaper interface (returned by getIFlashPaper()) function onLoaded(fp) { // We can now call the FlashPaper API functions. // Remove the standard user interface features: fp.showUIElement("PrevNext", true); fp.showUIElement("Print", false); fp.showUIElement("Find", true); fp.showUIElement("Tool", true); fp.showUIElement("Pop", true); fp.showUIElement("Zoom", true); fp.showUIElement("Page", true); fp.showUIElement("Overflow", true); fp.enableScrolling(true); // Some additional API features (here commented out): // Go to page: fp.setCurrentPage(1); // Change the magnification to 50%: fp.setCurrentZoom(65); } // Hide the navigation controller until after the document is loaded: _root.control_mc._visible = false; // Create movie clip to hold the document: var theDocMC_mc = this.createEmptyMovieClip("theDocMC",100); // Create movie clip to exchange the depth with the navigation controller clip: var ctrlHolder_mc = this.createEmptyMovieClip("ctrlHolder",200); // Position the document clip on the stage: theDocMC_mc._x = 0; theDocMC_mc._y = 0; // Load the FlashPaper document: loadFlashPaper("NomeFlashPaper.swf ", theDocMC_mc, 1000, 500 , this);
ciao

Rispondi quotando