Zurück   Flashforum > Flash > ActionScript > ActionScript 1

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 31-07-2003, 16:17   #1 (permalink)
Neuer User
 
Registriert seit: Jul 2003
Beiträge: 30
Question mc-übergreifend auf loadVars()-variablen zugreifen

hab 2 ineinander geschachtelte MC's
Scene 1 -> cafe -> shoutbox

in Scene 1 hole ich mir php variablen:
ActionScript:
  1. onClipEvent (enterFrame) {
  2.  
  3.     System.useCodepage=true;
  4.     loadText = new LoadVars();
  5.     /*loadText.onLoad = function(success) {
  6.         if (success) {
  7.            
  8.         }
  9.     }*/
  10.     loadText.load("inc/shoutbox.inc.php");
  11.     stop();
  12. }

wie kann ich denn von dem MC "shoutbox" aus auf diese variablen zugreifen??

eine variable heißt "message_count"... kann sie aber mit _root.message_count nicht erreichen....??


mfg,
michael
redesign2.3 ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:08   #2 (permalink)
Flash-Wüstling
 
Benutzerbild von pheidrias
 
Registriert seit: Dec 2001
Ort: Halle/Saale
Beiträge: 4.300
Dafür gibt's onLoad !
Warum hast du's auskommentiert ?

Deine Variable wäre dadrin mit this.message_count erreichbar .

Nur Mut !

tanti saluti,
pheidrias
__________________
Ehrlich währt am LÄNGSTEN !
pheidrias ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:14   #3 (permalink)
Neuer User
 
Registriert seit: Jul 2003
Beiträge: 30
ok, aber wie kann ich darauf von nem anderen movieclip zugreifen????
das onLoad event ist ja auf Scene 1 und ich brauch die variable in Scene 1 -> cafe -> shoutbox...

???

danke schon mal für die antwort

mfg,
michael
redesign2.3 ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:20   #4 (permalink)
Hirnverbrannt
 
Benutzerbild von NastyFrog
 
Registriert seit: Aug 2001
Ort: AUSTRIA
Beiträge: 2.020
Scenen sind egal. Kannst die Var auch in Scene 2 abrufen und so.
_root.cafe.shoutbox.meineVar
__________________
50 Seiten hardcore ActionScript von den Grundlagen bis zu 3D Darstellungen.... eben eine Abendlektüre.

Dogs fucked the Pope, no fault of mine. Watch out! ... Why money? My name is Brinks; I was born ... born? Get sheep over side ... women and children to armored car ... orders from Captain Zeep.(Hunter S. Thompson)
NastyFrog ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:28   #5 (permalink)
Neuer User
 
Registriert seit: Jul 2003
Beiträge: 30
glaub ich hab mich bissi doof ausgedrückt....

auf scene 1 ist ein MC "cafe"... in dem MC "cafe" ist ein MC "shoutbox"....
in scene 1 selbst lad ich die variablen rein... und in cafe.shoutbox mach ich

this.box.text = ??????????
redesign2.3 ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:29   #6 (permalink)
Hirnverbrannt
 
Benutzerbild von NastyFrog
 
Registriert seit: Aug 2001
Ort: AUSTRIA
Beiträge: 2.020
Achso: this.box.text = _root.meineVar;
_root geht immer auf die Hauptzeitleiste.
__________________
50 Seiten hardcore ActionScript von den Grundlagen bis zu 3D Darstellungen.... eben eine Abendlektüre.

Dogs fucked the Pope, no fault of mine. Watch out! ... Why money? My name is Brinks; I was born ... born? Get sheep over side ... women and children to armored car ... orders from Captain Zeep.(Hunter S. Thompson)
NastyFrog ist offline   Mit Zitat antworten
Alt 31-07-2003, 17:56   #7 (permalink)
Neuer User
 
Registriert seit: Jul 2003
Beiträge: 30
so klappt das aber nicht
redesign2.3 ist offline   Mit Zitat antworten
Alt 31-07-2003, 19:35   #8 (permalink)
Hirnverbrannt
 
Benutzerbild von NastyFrog
 
Registriert seit: Aug 2001
Ort: AUSTRIA
Beiträge: 2.020
meineVar musst du natürlich ersetzen durch den Namen deiner Variable. Wenns dann nicht geht, dann stimmt was mit der Variable allgemein nicht.
__________________
50 Seiten hardcore ActionScript von den Grundlagen bis zu 3D Darstellungen.... eben eine Abendlektüre.

Dogs fucked the Pope, no fault of mine. Watch out! ... Why money? My name is Brinks; I was born ... born? Get sheep over side ... women and children to armored car ... orders from Captain Zeep.(Hunter S. Thompson)
NastyFrog ist offline   Mit Zitat antworten
Antwort

Lesezeichen

Themen-Optionen
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks sind an
Pingbacks sind an
Refbacks sind an



Alle Zeitangaben in WEZ +1. Es ist jetzt 22:27 Uhr.

Domains, Webhosting & Vserver von Host Europe
Unterstützt das Flashforum!
Adobe User Group


Copyright ©1999 – 2012 Marc Thiele