Topic: Simpleviewer galleries randomly will say "gallery not found"

Hi!  I'm not sure if I'm using Simpleviewer Pro 1 or 2, I downloaded about 5 months ago.

I'm using multiple simpleviewer galleries embedded in one flash website.  All will work perfectly well, and weeks will go by, and I'll go to click on a gallery and it will say, "gallery not found".  When I click on another gallery in the website, and it loads properly, I can then go click back the the first gallery that previously told me it couldn't be found, and it will load, no problem. 

It's an issue because I don't know when it will happen.  So I might have customers going to my site who, randomly, cannot load certain galleries.

Let me know what I'm doing wrong!  Thanks!

-Katie

Re: Simpleviewer galleries randomly will say "gallery not found"

Sounds like SimpleViewer 1.x, try setting mcLoader._lockroot = true;

//Example of loading multiple SimpleViewer swfs into another flash movie.

//init stage
Stage.align = "TL"; 
Stage.scaleMode = "noScale";

//set width and height of SimpleViewer swf
_global.SVStageWidth = 640;
_global.SVStageHeight = 420;

var galleryId:Number;
var mLoader_mcl = new MovieClipLoader();
mcLoader._lockroot = true;
mLoader_mcl.addListener(this);

//Set button actions
mcGal1.onRelease = function(){ 
    loadGallery(1);   
}

mcGal2.onRelease = function(){
    loadGallery(2); 
}

mcHide.onRelease = function(){
    mcLoader._visible = !mcLoader._visible; 
}

function loadGallery(galId){
    galleryId = galId
    mLoader_mcl.loadClip("viewer.swf?xmlDataPath=" + "gallery"+galleryId + ".xml",mcLoader);
}

function onLoadInit(){
    
    //set gallery xml name
    _root.xmlDataPath = "gallery"+galleryId + ".xml";
    //set gallery specific options
    if (galleryId == 1){
        com.airtightinteractive.apps.viewers.simpleViewer.Options.imageFrameColor = 0x00ffff; 
    }else{
        com.airtightinteractive.apps.viewers.simpleViewer.Options.imageFrameColor = 0xff00ff; 
    }
}

//load first gallery
loadGallery(1);

You can determine your version ass follows.

How do I tell which version of SimpleViewer I have?

For SimpleViewer standard version, right click the SWF to see the version number. For SimpleViewer-Pro, check the readme.html file in the top level of the pro download for the version number.

Mike Richards
SimpleViewer Support Team.

Re: Simpleviewer galleries randomly will say "gallery not found"

thanks so much for getting back to me so quickly!  so i tried that, and my code looked like this:

stop();

//Example of loading multiple SimpleViewer swfs into another flash movie.

//init stage
Stage.align = "TL";
Stage.scaleMode = "noScale";

//set width and height of SimpleViewer swf
_global.SVStageWidth = 980;
_global.SVStageHeight = 510;

var galleryId:Number;
var mLoader_mcl = new MovieClipLoader();
mcLoader._lockroot = true;
mLoader_mcl.addListener(this);

//load first gallery
loadGallery(1);

function loadGallery(galId){
    galleryId = galId
    mLoader_mcl.loadClip("viewer.swf",mcLoader);
}

function onLoadInit(){
   
    //set gallery xml name
    _root.xmlDataPath = "gallery"+galleryId + ".xml";
    //set gallery specific options
   
}

----------------

and then NONE of the galleries loaded at all!  so, i switched it back, but am still having the same problem. 

?

thanks!

katie

Re: Simpleviewer galleries randomly will say "gallery not found"

var mLoader_mcl = new MovieClipLoader();
mcLoader._lockroot = true;
mLoader_mcl.addListener(this);

Change mcLoader._lockroot = true; to mLoader._lockroot = true; match your code.

Mike Richards
SimpleViewer Support Team.

Re: Simpleviewer galleries randomly will say "gallery not found"

cool!  i think it worked.  we'll see if any "no gallery found" messages randomly pop up.  thanks again for your help.

if you have time, and just out of curiosity, what does the "mLoader._lockroot = true;" do?

thanks,

katie

Re: Simpleviewer galleries randomly will say "gallery not found"

You can see what adobe has to say here.

http://help.adobe.com/en_US/AS2LCR/Flas … 01321.html
http://livedocs.adobe.com/flash/9.0/main/00001110.html

Mike Richards
SimpleViewer Support Team.

Re: Simpleviewer galleries randomly will say "gallery not found"

AHHHH!  It's still happening!

So, i just randomly went to my website yesterday while in a meeting with a client, and when I clicked on my second gallery I got the - "gallery not found" message.  Now, when I then click on another gallery that loads, I can go BACK to the second gallery and it suddenly works.  Here's the "lockroot true" code that I replaced like you told me last time.  Any other suggestions?  I don't understand why one minute it can't find a gallery, and then once I get another gallery to load, the broken gallery suddenly works. 

Ideas? 

Thanks,

Katie

------------

stop();

//Example of loading multiple SimpleViewer swfs into another flash movie.

//init stage
Stage.align = "TL";
Stage.scaleMode = "noScale";

//set width and height of SimpleViewer swf
_global.SVStageWidth = 980;
_global.SVStageHeight = 510;

var galleryId:Number;
var mLoader_mcl = new MovieClipLoader();
mLoader._lockroot = true;
mLoader_mcl.addListener(this);

//load first gallery
loadGallery(3);

function loadGallery(galId){
    galleryId = galId
    mLoader_mcl.loadClip("viewer.swf",mcLoader);
}

function onLoadInit(){
   
    //set gallery xml name
    _root.xmlDataPath = "gallery"+galleryId + ".xml";
    //set gallery specific options
   
}

Re: Simpleviewer galleries randomly will say "gallery not found"

Also, the website is here - http://www.dreamlovephotography.com

Thanks,

katie

Re: Simpleviewer galleries randomly will say "gallery not found"

Here is another website where I use multiple simpleviewer galleries, and you can see, it has the same problem.

www.katiebarnes.com/portraiture

when you click on the first gallery option - "kids", it comes up with the gallery not found.  but when you click on the gallery below kids, "family", and then go back to "kids", it suddenly works.  now, as i said previously, i can go to my simpleviewer source folder, hit publish, and re-drag the viewer.swf into my ftp account, and it will fix the problem for X number of weeks.  until i randomly go to the website again, and suddenly the problem reappears.

thanks again,

katie