Flash Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Try It Free
Go Back   Dev Shed ForumsWeb DesignFlash Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old June 6th, 2003, 10:33 AM
sojourner sojourner is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Location: Pittsburgh
Posts: 3 sojourner User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Please analyze this actionscript...

Should this not work?--

--------------------------------------------------
//This var is declared on main timeline
var _root.cad = "1"

// This code is run inside of a movie clip on the main timeline
if (_root.cad <> "") {
gotoAndStop(_root.cad);
} else {
stop();
}

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

I am having a problem with gotoAndStop(_root.cad);

I cannot get flash to jump to the frame number when passing it in. Is there something I have to to make that happen?

Reply With Quote
  #2  
Old June 6th, 2003, 10:42 AM
sojourner sojourner is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Location: Pittsburgh
Posts: 3 sojourner User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Sorry, here is the snippet of code I am having trouble with:

_root.cad = "1"

if (_root.cad <> "") {
"gotoAndStop(cad"+_root.cad+");"
} else {
stop();
}

I am trying to addend frame name dynamically into the gotoAndStop Action. Is this possible?

Reply With Quote
  #3  
Old June 6th, 2003, 03:35 PM
CyanBlue CyanBlue is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2003
Location: Chantilly, VA
Posts: 31 CyanBlue User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Howdy...

Try this...
PHP Code:
 _root.cad "1";

if (
_root.cad <> "")
{
    
gotoAndStop("cad" _root.cad);
}
else
{
    
stop();


Reply With Quote
  #4  
Old June 11th, 2003, 05:27 AM
SlankenOgen SlankenOgen is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Location: The Netherlands
Posts: 122 SlankenOgen User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
I sometimes find it is necessary to use-

_root.gotoAndStop(_root.cad);

~mgb

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignFlash Help > Please analyze this actionscript...


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway