Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Centering Several Cast Members In One Go



A very simple question that I'm sure has a vary simple answer; I'm importing a number of images as a sequence (200 of them, in fact) straight to the stage, but when I do so, they're off center.

Obviously, I could go through each one and change the coordinates, but is there any way to either select each of the frames on the timeline and change their position together, or specify that I want them in the centre of the stage before I import them?

Many thanks.



FlashKit > Flash Help > Flash MX
Posted on: 04-01-2005, 12:28 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Direct 8.5 Help Dynamic Cast Members
May I ask a Director (Shockwave) question?

I need to put an XML feed into a simulated grid. Each row of the grid should be clickable and upon click advance to a specific frame. Frame May be different for each row. Each row will contain graphics and text. How do I dynamically put this on the stage?

If I could get the functionality of the example live XML feed from

http://www.crackconspiracy.com/~davem/

I'd be in heaven.

I'm using Director 8.5.

If this is not the proper forum to use, can someone point me to the proper forum.

Thanks
Mike Cassidy

Odd Cast
Can somebody please tell me how those guys do that? Isn't that amazing? Doesn't another company offer similar products?

Cast An FLA [OOP AS2]
Hi,

I'm dusting off my AS2 for a project and I'm having a bit of a hiccup. Basically I want to have a base.swf load a view.swf. There are a number of different view swfs and the base needs to be as light as possible (it's for a banner). The base swf will deal with all the data and loading issues.

I've done lots of OOP AS2, but I've never been in the position where I need to load a swf and then cast it to a class so I can interact with it.

Here's what I want to do -

I want the base swf to load a view swf which implements the Interface IView. On the base swf after the classes have been loaded there is a call

this = New Base();

the code in the Base class is


ActionScript Code:
class BaseLoader extends MovieClip {

   
    public function BaseLoader() {
                trace("Base Instantiated");
        loadModule();
    }
   
    public function loadModule():Void
    {
                trace("Loading module");
        var holder_mc:MovieClip = new MovieClip();
        holder_mc = _root.createEmptyMovieClip("holder",_root.getNextHighestDepth());
        var mcLoader:MovieClipLoader = new MovieClipLoader();
 
       
        var listener:Object = new Object();
        listener.onLoadComplete = Delegate.create(this, completeLoad);
        listener.onLoadInit = Delegate.create(this, loadInit);
        mcLoader.addListener(listener);
       
        mcLoader.loadClip("ToLoad.swf",holder_mc);
 
    }
   
    public function loadInit(target:MovieClip):Void
    {
        var o:Object = new Object();
        o.test = "This is a test";
        var view:IView = IView(test);
                view.setData(o,this);
    }

IView has two required methods, setData(o:Object,parent:MovieClip) and display();

OK - this doesn't work. So I have a work around. I can load a view swf and place on the timeline a function called init. The init function then creates the view class and parses in the data. The new call from the Base swf looks like this


ActionScript Code:
public function loadInit(target:MovieClip):Void
    {
        trace("Clip Inited : " + target);
       
        var o:Object = new Object();
        o.test = "This is a test";
        target.init(o,this);
    }

On the loaded swf the init function does this


ActionScript Code:
function init(o:Object,bl:BaseLoader)
{
    this = new ToLoad(o,bl);
}

Where ToLoad is a class I've created. This all works, but I'd really like to do it the first way.

Apols for taking so long to get to the point, but i wanted to make it clear that I'd tried the way that was logical for me and have a work around. But is there a way where I can load a clip and then cast it to a class and then call methods on it?

Cheers,

t

Strings To Number Cast
I'm having a brain fart and I can't think of a way to change a string "6" that I loaded off XML into a number that I can process. Can someone throw me a line, while I go get some caffeine?

Cast String To Function
I have xml data that I am reading in for some dynamic Tweens. I am reading in the function as a string from the XML but when I try to use it in my Tween it doesn't work. I am trying to cast it to Function() but that doesn't seem to work. Does anybody know what I need to do?

Here is my code:

ActionScript Code:
new Tween(mc, String(oTween.property), Function(oTween.tween), Number(oTween.start), Number(oTween.end), Number(oTween.duration), true);

This same thing works if I do this:

ActionScript Code:
//change Function(oTween.tween) to null
new Tween(mc, String(oTween.property), null, Number(oTween.start), Number(oTween.end), Number(oTween.duration), true);

A little more data on this: oTween.tween = "mx.transitions.easing.Strong.easeOut";

Cast Datatype As String
Well...

I have an application that loads different classes on runtime. But since runtime instanciation isn't really well implemented I still have to declare the class in some way prior to using it (correct me if i am wrong). The minimum I need to do is declare a variable of the class' type. I.e I have a class called "topmenu", so i instanciate an empty variable -
Code:
private var _TM_:topmenu;
and the rest runs smoothly.

Now my question is if load up an array with all my classnames
Code:
typesToCast:Array = new Array("topmenu","mainmenu","whatever",...)
could I then instanciate a set of empty variables i that holds all my types


Code:
var a:Array = new Array();
for(blah.....){
var tmp:(typesToCast[i] )// how would I do this
a.push( {ref:tmp,name:typesToCast[i] });
}
its a bit far fetched, but this would give me a reference to the class that I could use with getQualifiedClassName( ) when instanciating classes runtime, and a name to identify it.

Aiith. This was messy. As my head at this point, question still remains, can you cast a datatype as a string??????

B

Cast Java Vector
What is the best ActionScript type to cast a vector from Java? I am using remote objects, in particular, an object that returns a vector which i am not able to pass into ActionScript. When i try to dump to an array, i get the following error when attempting to access the length of the array.

TypeError: Error #1009: Cannot access a property or method of a null object reference.

Any ideas?

Can't Cast Event.target
I'm writing a gallery and I have writen custom Tumbnail class that extends Sprite. Each tumbnail has an ID property so I can determine which one is clicked.

I've added event listeners to all of them and in handler function tried:


Code:
var target:Tumbnail = Tumbnail(event.targer);
so I can get:


Code:
target.ID
but I get this error:


Code:
TypeError: Error #1034: Type Coercion failed: cannot convert flash.display::Sprite@33ce241 to Tumbnail.
at TumbContainer/::onClick()
Anyone know what am I doing wrong?

Cannot Cast Custom Class
This is driving me nuts!

I'm using a for loop to create several objects of a custom class I've created (extends Sprite). Those objects are then passed in to an array, and event listeners are placed on them listening for a mouse over. When a mouse is over, the function it calls is trying to subsequently call a function inside that object, but I can't get it to work! It keeps giving me a runtime error saying that it cannot access a property or method of a null object reference. Can anybody help me out???

Menu Class:

Code:
public var menuItems:Array = new Array();
public var numberOfMenuItems:Number;

public function Menu(rowNumber:Number)
{
numberOfMenuItems = rowNumber;

for (var i:Number = 1; i<(numberOfMenuItems+1); i++)
{
var menuItem:RollOutMenu = new RollOutMenu();
menuItem.x = 100;
menuItem.y = (500/numberOfMenuItems * i) - (500/(numberOfMenuItems*2))
menuItems.push(menuItem);
menuItems[i-1].addEventListener(MouseEvent.MOUSE_OVER, onMouseOver);
menuItems[i-1].addEventListener(MouseEvent.ROLL_OUT, onMouseOut);
this.addChild(menuItem);
}
}
private function onMouseOver(e:MouseEvent):void
{
var newMC:RollOutMenu = e.target as RollOutMenu;

newMC.scaleHit();
}
RollOutMenu Class:

Code:
package
{
import flash.display.Sprite;

public class RollOutMenu extends Sprite
{
public var hitSpace:Sprite = createHitSpace();

public function RollOutMenu()
{
addChild(hitSpace);
}

private function createHitSpace():Sprite
{
var rect:Sprite = new Sprite();
rect.graphics.beginFill(0xFF0000, .5);
rect.graphics.drawRect(0, -15, 30, 30);
rect.graphics.endFill();
return rect;
}

public function scaleHit():void
{
hitSpace.width = 500;
}
}
}

Wheather Cast In Flash
Hey there, im trying to puta wheather cast in one flash website im making, since is about tennis, the client just asked me to put the wheather cast so that the people know if they can play. i found something to do it, bue i just having some trouble personalizing it. does anybody ever done something like this?:S tanx

Write A Director Cast From Flash
OK, I think I know the answer but can I just run it past some of you guys?

I would ideally like to write a flash app that can effectively write a director cast as the output.

As I am writing I am thinking could the output be a text file? And then a seperate director app pulls in the text file to convert it to a cast.

Anyone got any ideas on this?

Trying To Cast A Member With Delegate - Need A Hand
Hi Guys,

Check this out.
Ive got a class that I call using the following.
This line moves my menu up.
button.addEventListener('release', Delegate.create(this, toggling.menuUp));
Works fine.

I want to move my menu up into a certain position hence I write
button.addEventListener('release', Delegate.create(this, toggling.menuUp(3)));

and it never works when I try to cast something in this way. All my vars and members are accessible. Let me know if you need more code for explanation on this. Just want to know is it possible to cast using this process?

Changing A Cast Member/sprite
Before I begin, forgive my lack of knowledge on this, my background is Lingo so Im not familar with actionscript or flash terminology at all. Here gos anyways-

Im essentialy tasked with having an animation clip loop (xmas snowing scene) with 'season greetings' in several languages automatically rollingover everytime the movie-loops. My question is- how do I change the 'season greetings' member from one to another each time the movie loops at say frame 50? Any clues to the correct syntax would help me on my way.

DisplayObject Won't Cast To MovieClip, Halp Please
Hi everyone, im new to this forums. I will have time for a more proper introduction later today :p.

Im in a bit of a trouble. I have a quite a few hours of programming experience in other OOP languages but im pretty new to AS3 and there's one thing that wont work, one that should be easy because i've done it countless times in Java and its now being a pain in the *** . I have the next code:

Code:
private function handleCompleteLoad(e:Event):void{

var loadedObject:DisplayObject = loader.getChildAt(0);
var loadedMovieClip:MovieClip= loadedObject as MovieClip;
this.addChild(loadedMovieClip);
}

And it turns out that the casting fails and it always returns null. I would like to have the loaded swf as a MovieClip because i need control over it (needs to play once, and needs to be changed once it has finished), but if i can't do the casting im afraid i wont be able to have the control i need. DisplayObject doesnt have the methods nor the properties that i require .

Any halp?

Thanks for reading!

Porting Director Cast/score To Flash
I would like to port Director cast members and ideally simple score animations from Director to Flash. Of course, copy and paste from a Dir score to a Flash score doesn't work -it was fun trying try it though Any ideas?

The SpriTec Xtra for Director lets me export cast members (sequentially) as PICT or BMP files. Score data (left, top, etc) for individual frames is also output to a text file but reassembling this in Flash will be a headache that I'd like to avoid.

Trying To Cast A Member Twith Delegate - Need A Hand
Hi Guys,

Check this out.
Ive got a class that I call using the following.
This line moves my menu up.
button.addEventListener('release', Delegate.create(this, toggling.menuUp));
Works fine.

I want to move my menu up into a certain position hence I write
button.addEventListener('release', Delegate.create(this, toggling.menuUp(3)));

and it never works when I try to cast something in this way. All my vars and members are accessible. Let me know if you need more code for explanation on this. Just want to know is it possible to cast using this process?

Type/transparencies Creating Color Cast On Background
I recently upgraded to Flash 8 and have noticed that when I have a colored background (purple, for example), and I import a graphic with a transparent background or create a white/lighter color type input, then the image or text will have a "box" around it that is a slightly lighter shade than the background. I have not encountered this before. I have tried importing different types of graphics to no avail. Any suggestions/answers are appreciated.

Director - Executing Some Lingo When A Button Is Clicked In A Flash Cast Member
Hi Hi,

Here's the story...

I've created a store locator flash movie that displays some details of some different stores depending on what post code is entered by the user.... the user simply enters the postcode and presses a button and the details of the store are displayed. this is working fine.

the second thing i want to happen is, i want an image to appear of the store manager of each store depending on which postcode the user enters.... i know that flash is capable of dynamically loading in images.... although for this assignment i need to show some extended knowledge of director, and want director to load the image (not load the image into the flash cast member, but just load the image elsewhere in the director movie.

basically, what i need to know is, how do i setup some code, such that when the user clicks on the "submit" button that is in the flash movie, director is made aware of this, and can then execute it's lingo in order to load in the appropriate image.

also, what lingo code would i use to retrieve a variable value from the flash movie cast member when the submit button is pressed, such that i can use that variable as a string for the file path of the image i plan on dynamically displaying in director?

if anyone is able to help me out with either of these two questions, it would be much appreciated,

thanks in advance folks.

Reminder To New Members
A quote from the webmaster...

[quote]Talk of Warez or posting Warez site links is strictly forbidden by the user registration and we will ban any member that does so.
Sites that swap mp3s or any other copyrighted or licensed material without respect for the rights and royalties of their owners are also in this category.[quote]

please consider this before you post here.
thanks,
david p.

Members Login
i must admit i am relatively new to FLASH,
thanks to anyone who can help me further...

I have 2 input boxes, 1 for username and 1 for password..
I have named them according and entered those same details in the variables field...

I have drawn a submit button, (as i dont want to use FLASH MX's push button components due to combatibility issues with FLASH 5) and turned that to a 'button symbol'. I assigned an actionscript to that button

on (release) {
getURL("http://myserver.com/verify.asp", "", "POST");
}

that didnt work, it only linked me to my registration page...

i applied
loadVariables("http://myserver.com/verify.asp", "this", "POST");
to my login button, now the button is not working...

Please i really do need help with this, can someone tell me what im doing wrong or what i should be doing or where to apply that loadVariables function?????????

Much appreciated in advance

For The Senior Members
hi all, i need an example for how to achieve what this site does with regards 2 how the different scenes are preloaded only when called on.

http://www.interactive.co.za

If any1 could help that would be gr8.

cya

PrOtOcOl > dOmInAtE > CoNtRoL

Any WebWasp Members?
Anyone have a webwasp.co.uk account? There's a flash file I would desperately like to acquire: 605a

http://www.webwasp.co.uk/tutorials/c...sive/index.php

Protected Members
Is it possible to do a protected statment in AS classes?

I did try to do it:

Example.as:

class Example {
protected var iInteg:Number;
}



SecondExample.as:

import Example;

class SecondExample extends Example {
public function Example () {
iInteg = 10;
}
}


when I instanciate my class:
var ex1:SecondExample = new SecondExample();

This error is generated:

Example.as: Line 2: Syntax error.
protected var iInteg:Number;

I did find some protected functions stated in some examples of this forum. Isn't it possible to do with the attributes/variables?

Thanks in advance

But na

Members Section?
hello

does anyone know of a Flash based username/password system, that uses a PHP/MySQL backend? im currently working on adding a members 'VIP' section to a clients website and trying to work out the best way to handle the transactions, membership etc. users will pay £1, which gains them access to the members section for one month. im thinking paypal for the transaction side of things, but would prefer some sort of Flash version instead!

anyone had any experience with this sort of thing?

tom

Class Members
What security is provided by the private variables in flash. I know it provides encapsulation, but how exactly. When a user uses a class, that means he has the class .as file. He can simply open it up and see the code. When we load a movie clip that uses a class into another movieclip, the parent movie clip can access the private variables of the class used in child movieclip. For components, yes they are useful, but what i wanted is a scenario (other than components) where private variables provide security to our code in the class.

Moreover I can access private variables if i dont use strict data typing. Use can also access private variables if u've imported a class in first frame and try and access its private variables in another frame. A person (not the author)can use any of these things to gain access to private variables. Please help me in understanding the concept of private variables.

Members Only Area
im making a flash site and i need to know how to make a members spot in the website can anyone help me and also how to make a pop up when you first enter the site without clicking on a button

thanks

Hello Kirupa Members.
Hello to all Kirupa members.

I was a member from this community for a wile two years ago.
But them I lost My PC content and had to create a new membership, so I'm now my real name.

I have this site, and it worked OK till just now.
It seems that I may have a problem caused by the recent flash tecnology due to the new flashplayer 9 "ADOBE".
Before, al my scroll text areas appeared and ran just fine. But now the text just disapeared, anyone with same problem.
You can check the site at http://www.imoholding.pt check the english version, the first project and information button for an example.

thanks for any Ideas on this.

Greatings from Portugal.
AlípioSequeira

Members Only Area
im making a flash site and i need to know how to make a members spot in the website can anyone help me and also how to make a pop up when you first enter the site without clicking on a button

thanks

My Thanks To The Members Of Ultrashock
I just got my grade results from my Flash class in college, 1.25 points from perfect (158.75 out of 160). I think the main reason I did so well are because of folks like Codemonkey and Nutrox (I know there are others, but these two especially came to mind) who willingly take the time to explain both the How? and Why? questions nubies like me come up with (only been doing Flash since September, never touched it before then). One aspect that totally set me apart from my peers in my class was the fact that I used mainly AS in my project, dynamically loaded swf's (Flv, text and stuff at runtime) and a nice array menu (tsunami style). Everyone else did the more animating way using many frames and tons of layers. I had 14 swfs that loaded as needed ranging in size from 2k to 135k with most in the 60-80k range. With the exception of the streaming (progressive downloading) flv's, my final project was all told (with HTML and sound) less than 800k. I got the A+ on the final project, the next highest grade was an A-. The truly funny thing though, his project was the next smallest at 14 mb and one single swf.

Just goes to show the power of AS. My project can run on dialup whereas every other person in the class needed broadband or run off a CD (or even DVD for one guy, he had to use a dual-layer disk for his project, he animated 11,000 frames for his project) for any real use of their projects.

(done tooting my horn, just wanted to say thanks!)

Kevin

**It might only be live for another week, but my final project can be found here.**

How Can I Know When Members Are Online?
Hi, is any section here where I can see which members are online???
Thanx!!

Members Login Difficulties
i must admit i am relatively new to FLASH,
thanks to anyone who can help me further...

I have 2 input boxes, 1 for username and 1 for password..
I have named them according and entered those same details in the variables field...

I have drawn a submit button, (as i dont want to use FLASH MX's push button components due to combatibility issues with FLASH 5) and turned that to a 'button symbol'. I assigned an actionscript to that button

on (release) {
getURL("http://myserver.com/verify.asp", "", "POST");
}

that didnt work, it only linked me to my registration page...

i applied
loadVariables("http://myserver.com/verify.asp", "this", "POST");
to my login button, now the button is not working...

Please i really do need help with this, can someone tell me what im doing wrong or what i should be doing or where to apply that loadVariables function?????????

Much appreciated in advance

Creating A Members Area In MX
Hi is there any online refernce guide to creating a members area in flash. Or if you know yourself on how to go about it please let me know.
Thanks

Join Members(urgent)
I wanna know how to let people sign up for mysite without having to send me an email for a user name and password, if anyone knows how to do this, can they message me or something> cause it's really driving me crazy!!!

this is urgent!

Thank You Flashkit&registered Members
hey ,
in short i just want to express my feelings for flashkit and all of its members for making me feel right at home here in the flash forums ..if it werent for a few special people ,that have helped me out a lot. i wouldnt have been able to accomplish what i have with flash (it may not be much to some ,but its the world to me ).to name a few people off the top of my head .

Pellepiano
oldnewbie
hp3
iaskwhy
senocular
there are so many more i would like to say thanks to .but this post is just in the moment
also i hit my 1,000 th post yesterday ->LOL
thanks again for the help and thanks everyone ..
cheers
timo

Members On A Site Using Flash
hey

Can you have a "Register" type thing using flash? I want to design a flash application that allows visitors to sign up to my site and login when they visit my site again but i want to do it in flash. Is there any tutorial that covers this and would it be possible... I really need the help for my website cause all of it is pretty much done in flash.

Thanks

TedTLogan

Senior Members Etc Choose MX
How come most of you use MX as opposed to 2004? Usually people flock to new versions of software yet people seem to tiptoe around 2004. I've started trying to use 2004 and with the lack of normal mode (on AS) i've been struggling. Is MX better to use? Your opinions please!

Thanks

[CS3] OOP: MCs And Buttons As Class Members
I've been working on a signage project for our new office building that will let users see floor plans and tell who is in which office and what their Gtalk status is. So far I've got a working concept (test movie) but as you can see, it doesn't load all the statuses at the start. It's working off of one LoadVars object and the script executes too fast for the variables to be loaded for the other offices. However, the problem is corrected when an individual office is rolled over.

My intention is to create an object called office that will hold a background MC (the part that changes color), a button (the part that initiates actions), an offices number string, and a LoadVars for each office. Ideally I'd like to be able to instantiate the offices once and then just have the code in the class definition handle the actions so I don't have to define actions for every single office (code for 100 buttons? I don't think so...).

Here's what I have so far (working with Action Script 2.0):

Code:
class office{
var officeNumber:String;
var backgroundMC:MovieClip;
var officeButton:Button;
var officeLoadVars:LoadVars;

function office(n,mc,button,dx,dy){
officeNumber = n;
backgroundMC = mc;
officeButton = button;

//initialize positioning
backgroundMC._x = dx;
backgroundMC._y = dy;
officeButton._x = dx;
officeButton._y = dy;

//set the displayed office number
backgroundMC.number.text = officeNumber;

setStatus();
}

offcVars.onData = function(success){
if(success){
//process the data and put it in the tooltip window
// exe- tooltip.name.text = officeLoadVars.name
// tooltip.message.text = officeLoadVars.message
}
}

function changeBGColor(code){
//change the bg color of the office bgMC
//either use setTranform or change the _currentframe
}

function setOfficeStatus(){
//php file takes an office number and returns:
//Occupant name or use (person vs storage vs training room)
//Gtalk status (already externally coded for; available, busy, idle, ect.)
// Gtalk status message (exe- Out to lunch; Working from Home)
officeLoadVars.load("getOfficeStatus.php?room="+officeNumber);
changeBGColor(officeLoadVars.statusCode);
}

officeButton.onRollOver = function(){
revealToolTip();
setOfficeStatus();
}

officeButton.onRelease = function(){
revealToolTip();
setOfficeStatus();
}

officeButton.onRollOut = function(){
hideToolTip();
}
}
The idea is to pass in a movie clip and a button already on the stage and have the actions inside the class handle everything that I was typing out manually before. The problem is I'm getting stuck at errors for the button functions I'm trying to define.

Is it even possible to do what I'm attempting? (If something doesn't make sense, PLEASE let me know).

[CS3] [AS2] Accessing Private Members
I've got a class called Group that has a has-a relationship with another class, Item, in that it holds an array of Item instances.
I'd like to be able to select several items at once, and then perform the same function on all the selected items. to do this, I'll need an private array in Group that has pointers to all selected instances of Item.

To add to a selection, I have a selectItem function defined in Item. But I need to update the array in Group.

Long story short, is there a way to grant only a specific classes access to another class's functions/members, while maintaining that it is still private to everything else? Keep in mind that there is no inheritance going on here.

Members Post Fade In And Out
I'm attempting to create a website that will have people register. Once they register they can post stories about themselves. This will be on the back end.
On the front end I would like the stories (quick view) to appear when one rolls over the image that I will create. Here is an example of what I am looking for:
http://www.keyshiacole.com/_assets/f.../kc_widget.swf

Thanks. Once this is complete I will repost the end result.

Can't See Any Text Members When I Use Flash 8.
I'm using flash 8 and some of my users are having trouble seeing my site because they can't see any of the text!!! In some computers it works ok but some users can't see any text member even if they upgrade the flash player to 8 version. How do I correct this!

I had had problems with this when I ran a swf directly, I couldn't see any text; but when I put the swf into a html file I can see the text members that the web page has. Why is this happening!!! This did'nt happend with version mx. How can I correct this problem!

Please help!

Thanks a lot!

Brenda Sanchez.

Dear Members Need Badely Help
Dear member
i am searching for a flash script for my site the scripts is for "make us your homepage" and favorite" these some links we can find it in some websites so could you give me the scripts in flash
thanks dany

Show Part Of Movie Only To Members
I have a movie with 3 frames:
First - Preloader
Seccond - Guest Screen
Third - Member Screen

I have an cookie.asp script that checks the viewers this way:

<%@ Language=VBScript %>
<% cookienickname=Request.Cookies("thenick") %>
<%if cookienickname ="" then
response.write "usr=guest" %>
<%else
response.write "usr=member" %>
<% End If%>

I load the cookie.asp at the first frame this way
loadVariablesNum("cookie.asp", 0);

The Movie loads and plays to the seccond frame and stops.
Then I add something like this:

if (usr = "member") {
gotoAndStop(3);
} else {
stop();
}

But if I log as a member or not the movie awlays stops at the Seccond frame The ASP is OK because when I load it it shows the line guest or member. Can someone see what is wrong ?

Thanks!

Show Part Of Movie Only To Members
I have a movie with 3 frames:
First - Preloader
Seccond - Guest Screen
Third - Member Screen

I have an cookie.asp script that checks the viewers this way:

<%@ Language=VBScript %>
<% cookienickname=Request.Cookies("thenick") %>
<%if cookienickname ="" then
response.write "usr=guest" %>
<%else
response.write "usr=member" %>
<% End If%>

I load the cookie.asp at the first frame this way
loadVariablesNum("cookie.asp", 0);

The Movie loads and plays to the seccond frame and stops.
Then I add something like this:

if (usr = "member") {
gotoAndStop(3);
} else {
stop();
}

But if I log as a member or not the movie awlays stops at the Seccond frame The ASP is OK because when I load it it shows the line guest or member. Can someone see what is wrong ?

Thanks!

Access To Class Members In OnLoadInit?
Hi

I'm trying to throw together an image loader class for reuse. Everything seems to work except for one thing: once the image is loaded, I can't set the loaded image's position or size. I want to set the _x, _y, _width, & _height properties in onLoadInit from the containing class' members, but inside my event handler, those members are considered "undefined". I'm sure this has come up in this forum before, but I couldn't find a thread specific to this problem. My code is below.

- O8

in VideoImage.as


Code:
class VideoImage
{
private var mContainer : MovieClip;
private var mX : Number;
private var mY : Number;
private var mWidth : Number;
private var mHeight : Number;
private var mSourceUrl : String;
private var mLoader : MovieClipLoader;
private var mListener : Object;

public function VideoImage( pContainer : MovieClip,
pX : Number,
pY : Number,
pWidth : Number,
pHeight : Number,
pSourceUrl : String )
{
mContainer = pContainer;
mX = pX;
mY = pY;
mWidth = pWidth;
mHeight = pHeight;
mSourceUrl = pSourceUrl;

LoadImage();
}

private function LoadImage() : Void
{
mContainer.createEmptyMovieClip( "mcVideoImage", mContainer.getNextHighestDepth() );
mLoader = new MovieClipLoader();
mListener = new Object();
mListener.onLoadInit = function( image : MovieClip )
{
image._x = mX;
image._y = mY;
image._width = mWidth;
image._height = mHeight;
}
mLoader.addListener( mListener );
mLoader.loadClip( mSourceUrl, mContainer.mcVideoImage );

return;
}
}

in the fla on frame 1


Code:
var image:VideoImage = new VideoImage( this, 0, 0, 60, 70, "http://northport.k12.ny.us/~enms/ahern/budda2/orionpic.jpg" );

Access Private Members At Runtime?
Hi,

Is it possible to do this with AS3?

With AS2 the Flash player doesn't know about access permissions but of course with AS3, this information is available at runtime and enforced.

Is there a way around it? With C# one can use reflection.

Cheers, CN.

Problems In Some Computers With Text Members, HELP
I created a project on Flash MX 2004 and I created a .exe but my end user can't see text members in some computers. I tried it it several computers and it worked fine but in some others I have this problem. I really don't have any idea what is wrong. Can anyone give me some ideas of what on earth it could be? Do I need to install a special plugin or what. I'm running the program I created on a cd-rom.

Thanks for any help received.

Brenda S.

Where Do Members Submit Their Own Flash Guide?
is there a place where members can submit their own guide in kirupa forum?
that would spice things up abit ^^

Members Page Loading Info Via Xml
Hi all

Can anybody help me on how make such a page, I have a members page with 17 Dynamic text box's for the members infomation to be shown in, i also have a list component which will display the members name's.

When you click on a members name it will load the members infomation into the appropirate dynamic text box's.

here is the page [url=http://www.theoaps.co.uk/Support%20Files/Members.swf[HERE]


Code:
var mList:XML = new XML();
mList.ignoreWhite = true;

var members:Array = new Array
mList.onLoad = function(){
members = this.firstChild.childNodes;
for (i=0;i<members.length;i++){
ML.addItem(members[i].attributes.member,members[i].attributes.CMPN);
//mList.onLoad = function(){
//var members:Array = this.firstChild.childNodes;
//for(i=0;i<members.length;i++){
//ML.addItem(members[i].attributes.member,members[i].attributes.CMPN);
}
}
var MemberListLObject = new Object();
MemberList.change = function(){
CMPN.text = members[CL.selectedIndex].attributes.CMPN;
}
mList.load("members2.xml");

Any ideas guys as this is driving me to drink

Cheers

Dunkyb123

UserComponents Public Data / Members?
When using flash userControl or flash Component is there any easy way to see the methods on that component through the flash IDE?

Or would someone interested in knowing how to use a certain component have to go online to find documentation?


- hoping there is some cast that can be done to get tooltips to pop up

Copyright © 2005-08 www.BigResource.com, All rights reserved