Ultrashock Forums > Community Essentials > Tutorials
Flash MX 2004 UI Components

You are currently viewing our website as a guest which gives you limited access to forums, files and other resources.

Click here to join now for free, and start interacting with our members, download files and much more!

Click here if you are looking for our Flash files and other professional assets.
 
Post Reply | View first unread | Rating: Thread Rating: 24 votes, 4.67 average. Search this Thread | Thread Tools | Display Modes
1|2|3|>|>> Page 1 of 4

#1
Bookmark and Share!
Flash MX 2004 UI Components
Old 2003-10-01

Flash MX 2004 now sports 21 UI Components, some of which may be familiar to you from before and others that are new. In this massive tutorial, we will take you through each of these components and show you how to use them.

Check out the tutorial here.

You're welcome to discuss the tutorial in this thread.
::: Are you ready for a creative power? ::: : : .
postbit arrow 147 comments | 22656 views postbit arrow Reply: with Quote   
nrg
¶ixë₤▪†w€@kê®™
nrg is offline Administrator
seperator
Posts: 5,406
1999-12-13
Age: 37
nrg lives in Belgium
11
nrg's Avatar
seperator

Ultrashock Member Comments:
nig nig is offline 2003-10-01 #2 Old  
DataGridColumn.headerText will set headers' text.. I'm not sure why you're using __header.
Also, to make a List or Tree scroll horizontally, try the following :
myList.hScrollPolicy = "on";
myList.maxHPosition = 200; // or whatever

Think you could amend these issues? I'd like to avoid misinformation spreading through your hard work.

thanks
nig
Reply With Quote  
nig nig is offline 2003-10-01 #3 Old  
Ack, more misinformation in the Menu tutorials. I'll explain further later.. I have bugs to fix. In general, though, the rule seems to be, when you start complaining in the tutorials, it means you're misunderstanding something. Not that the components are perfect, but there's some glaring stuff that's just wrong in here.

nig
Reply With Quote  
miko's Avatar miko miko is offline Administrator miko lives in United States a lot of Creative Assets 2003-10-01 #4 Old  
Welcome to Ultrashock nig. Please let us know if we can help.
Reply With Quote  
aral aral is offline 2003-10-02 #5 Old  
Last edited by aral : 2003-10-02 at 01:55.
Hi Nigel,

Thanks for taking the time to read through the tutorial, it's great to have your feedback. For those of you who don't know Nigel, he is responsible for the design and development of the v1 and v2 components at Macromedia so if there's one person who knows them inside out, it's him.

That said, I feel I need to address your concerns regarding perceived "misinformation" in the tutorials.

Regarding horizontal scrolling: We actually figured out that you could hard-code a horizontal scrollbar by setting the maxHPosition (thanks Tanja) but did not include that in the tutorial initially for two reasons: #1 The tutorial was already in production and #2 It is a *partial* workaround / hack. We will update the tutorial with a note alerting readers to this workaround, however, the original issue remains:

By hardcoding the maxHPosition, you are create an inconsistent interface for the component by having an automatic vertical scrollbar that adjusts its thumb-size to the actual height of its content and an always-present horizontal scrollbar that does *not* adjust its thumb-size to the width of the available content. If I absolutely had to use the component, I would, of course, use it with the workaround to ensure at least the most basic usability but if I could possibly avoid using the component, I would do so until this issue is resolved in a consistent manner (i.e., I wouldn't use the component in its current form in a real-world application that required horizontal scrolling of the component.)

Regarding why I used the __header property: When I was writing that section of the tutorial, I did not have full documentation for the DataGrid component. I dived into the code (I don't remember whether I used ASV or not) just to make the thing work. If you'll remember, Flash MX 2004 and Pro were shipped *without* full documentation. Even today, the documentation is woefully incomplete. Take a look at the docs for the Tree Component (Tree Class page) -- according to the docs, PopUpManager.createPopUp "Adds a node to a tree instance" and Accordion.createSegment "Adds a node at a specific location in a tree instance." Confusing? You bet! That said, we will update the tutorial to reflect that you can use the .headerText property.

In general, I would argue, if I start complaining in the tutorials, Macromedia should take a good look at its documentation and see if it is complete. Not many people will dive into the code to find things out if its not documented properly. I don't claim to be beyond misunderstanding things -- quite the contrary, it happens all the time but I would urge you to try and see why so many people are misunderstanding so many things about Flash MX 2004 and why WTFM appears to be the catch phrase on the Flash lists I frequent.

Please don't misunderstand Nigel, these are not criticisms of your component framework per se. In fact, the architecture of the new framework is very impressive, as was that of the previous one. However, I'm sure you would agree that there are issues with the components and/or with the documentation for the components caused in no small part, I'm sure, by the mad rush to get the product out the door (have you guys fired your marketing department yet?) I am not the only one who has been running up against these problems. Peter Hall, who you could argue is not a dim man, was banging his head on the wall for days with data binding and Grant Skinner, the same with Forms. It appears that the problems become apparent the moment you try to move from demonstrating basic functionality to using some of these new features for real-world work. Again, perhaps a large part of the problem is in the lack or quality of the documentation. But this is an issue that needs to be understood and addressed. You can blame users all you want for "misunderstanding" but if enough people misunderstand the new features just won't get used and thus the product's adoption will suffer.

I would really like to hear about the "misinformation" in my Menu tutorial. Is there something with my MenuBarDecorator that does not work? The functionality added by the MenuBarDecorator is basic functionality that I was searching for from the outset when I first began using the component. I believe it is an elegant solution and makes the component much easier to use. I would definitely welcome your views to the contrary. After all, open debate is the only way we can hope to exchange ideas and thereby improve upon them.

This is why I would urge you to see these tutorials as a platform. None of them are etched in stone -- we can always add footnotes and callouts. Just remember that they were written by people with considerably more experience with Flash than someone just starting out and if something trips up our authors, I would suggest that we try to look beyond the "misunderstanding" and look for the cause of the misunderstanding and try to make it simpler to use. That said, it is also possible that an occasional technical error may creep up in a tutorial and we will definitely fix those as we are made aware of them.

Again, I welcome your comments and hope to hear more of them in the future. Your input on the tutorials will no doubt prove invaluable for the community and I thank you for taking the time to share it with us.
Reply With Quote  
jdecoster jdecoster is offline 2003-10-02 #6 Old  
preloading components
Hye !

I create a new document. A new keyFrame at frame 10. And drag-drop the combobox component. Then export and the swf have 54ko at the first frame!
I have a simple question : how preload the components ?

And if i'm right, the data components needs to be inserted at firt frame to work. So how preload thoses ?

Thanks a lot !
Reply With Quote  
emzic emzic is offline 2003-10-02 #7 Old  
hi, im new here and i have 2 questions:

why should i use the button-component and not a traditional button-symbol?

im really missing something like a slider component. you know something where you can set a numeric value by dragging a pointer up/down or left/right.
or have i just not found it yet?
Reply With Quote  
Peter-Hall Peter-Hall is offline 2003-10-02 #8 Old  
Peter Hall .... was banging his head on the wall for days with data binding...
Aral, I must protest at your misinformation. I wasn't "banging my head on the wall for days". It was my fist, the desk, and only one day.
Reply With Quote  
webRat's Avatar webRat webRat is offline Moderator webRat lives in United States 2003-10-02 #9 Old  
hehe
Reply With Quote  
nig nig is offline 2003-10-02 #10 Old  
Last edited by nig : 2003-10-02 at 09:54.
Re: the maxHPosition "hack", I guess there's not much I can say... It's not a hack. It's certainly a compromise, because there isn't really any way to resolve the issue you describe simply. I guess you won't be using the component... (?). There's no way to measure potentially thousands of lines of text without such a crippling slowdown that it becomes unusable. I don't see this as a huge usability issue though. Can you explain that aspect - I don't think it violates "the most basic usability".

Anyhow, Aral, I guess I wrote because in some instances your tone was just... well, you know, the Aral one, and it got to me. Kinda hyperbolic, editorializing, inflammatory, you know what I mean. This is certainly your right as someone who did as much work as you did, but in cases where you're incorrect, it's kind of a disservice to your readers, don't you think? Instead of dropping me a mail or posting to flashcoders, you kinda dismiss the thing you don't get right and begin editorializing. Which makes people think there *is* no way to do the thing you describe. And while I agree that there's *tons* of work left to be done on the documentation front (you don't even know the half of it), this kinda stuff actually makes our job harder and the situation worse. Again, this might be your right, but I kinda wish the tone had been a little more even. Maybe I'm just being oversensitive. But I hope you'll consider the effect it has on someone looking for information and finding a rant that tells them to give up looking for the right way to do something.

sincerely
nig
Reply With Quote  
markem99 markem99 is offline 2003-10-02 #11 Old  
Hi Aral,

Great work on these tutorials. One question about

"For one thing, you cannot use a single, correctly-formed XML file that contains all your various menus (e.g., Options, Help) and your Menu Bar structure (e.g., Options first, then Help). Instead, you need have one XML file per Menu object that you want to create. After having loaded these in, you have to go and add them to the MenuBar ..."

in the MenuBar tutorial. Why don't you use

myMenuBar.dataProvider = myMenuBarDP.firstChild;

then your problems above disappear? Then can use one well-formed xml file for all of menuBar - still need to set up listeners of course but your criticism disappears.

Note that the MX 2004 doc is wrong on this and attempts to use just myMenuBar.dataProvider = myMenuBarDP; which doesn't work.
Reply With Quote  
nig nig is offline 2003-10-02 #12 Old  
yeah, mark's got it right. Those docs really need to be updated.. I'm going to figure out how to get that done. Sadly, I was on vacation at the time the docs were being reviewed, so I think some stuff got lost.

Note to self : no more vacations.

nig
Reply With Quote  
nig nig is offline 2003-10-02 #13 Old  
Last edited by nig : 2003-10-02 at 14:12.
reading through some of my replies, I have to apologize for my tone as well. I think you just know how to get to me (this has happened before and I'm sure we'll clash again). I don't want to insult you at all Aral, and I admire the service you've done here. Let's figure out how I can get MM's docs updated *and* the tutorials updated so that the people around here actually have the right info from both sides.

Wow, let me update, I just looked over some of what you were talking about in the help Aral, and there's some really foul stuff in there. Looks like some HelpIDs are colliding... Who would have guessed that "Alert.cancelLabel Specifies an XML data source" for a Tree. Thanks for pointing that out.
Reply With Quote  
miko's Avatar miko miko is offline Administrator miko lives in United States a lot of Creative Assets 2003-10-02 #14 Old  
Originally posted by Peter Hall
Aral, I must protest at your misinformation. I wasn't "banging my head on the wall for days". It was my fist, the desk, and only one day.
I feel an edit coming on here

Thanks for your last post nig... it would be beneficial to everyone if we can make all of the info congruent.
Reply With Quote  
aral aral is offline 2003-10-03 #15 Old  
Originally posted by markem99
In the MenuBar tutorial. Why don't you use

myMenuBar.dataProvider = myMenuBarDP.firstChild;

then your problems above disappear? Then can use one well-formed xml file for all of menuBar - still need to set up listeners of course but your criticism disappears.
Hi markem99 -- take a look at the source for the MenuBarDecorator -- that's exactly what I'm doing! I don't think that the fact that there's a workaround makes the initial criticism invalid however. My remark was aimed at the documented method of using the menu and menu bar components.
Reply With Quote  
aral aral is offline 2003-10-03 #16 Old  
Last edited by aral : 2003-10-03 at 06:30.
Originally posted by nig
Re: the maxHPosition "hack", I guess there's not much I can say... It's not a hack. It's certainly a compromise, because there isn't really any way to resolve the issue you describe simply.
I haven't had the time to look at the source for the tree but isn't it possible to get the _width of the movieclip that contains the tree structure? (I'm assuming there is a parent movie clip that the scrollbars affect.)


I don't see this as a huge usability issue though. Can you explain that aspect - I don't think it violates "the most basic usability".
Nigel, I really have to disagree on this. Take a look at Outlook (the Folder List). Both the vertical scrollbar and the horizontal scrollbar work correctly. By using the maxHPosition hack, we're turning the horizontal scrollbar into a non-proportional scrollbar. In other words, the thumb-size no longer displays the amount of the whole width that is currently visible.

Anyhow, Aral, I guess I wrote because in some instances your tone was just... well, you know, the Aral one, and it got to me. Kinda hyperbolic, editorializing, inflammatory, you know what I mean.
I'd agree with the comment on editorializing -- after all, I was the editor of the series however, I don't see how hyperbole enters into the picture. Regarding inflammation -- well, that happens when it happens

in cases where you're incorrect, it's kind of a disservice to your readers, don't you think?
Again, please let me know which information in the tutorial is incorrect and I will fix it. I have updated the example regarding __header and headerText. I do not see anything else here that needs updating. Please let me know what you would like to see changed and I will consider it.

Instead of dropping me a mail or posting to flashcoders, you kinda dismiss the thing you don't get right and begin editorializing. Which makes people think there *is* no way to do the thing you describe.
I believe we're still on the issue of the horizontal scrollbar with the tree component. If so, please let me know:

Is there any way to get a *proportional* horizontal scrollbar working correctly (i.e., displaying the correct proportion of the displayed content to the total content width) with the tree component?

If you can show me how to do this, I will update the tutorial and provide our readers with this new information. The workaround you stated earlier, does *not* do this. It creates a hard-coded non-proportional horizontal scrollbar that is (1) misleads user expectations by appearing visually as a proportional scrollbar and (2) is inconsistent in function with the vertical, proportional scrollbar of the same component.

If I am wrong in my two observations, above, please let me know.

And while I agree that there's *tons* of work left to be done on the documentation front (you don't even know the half of it), this kinda stuff actually makes our job harder and the situation worse.
Do you mean that perhaps someone who can load in a complete MenuBar and have their listeners registered automatically using the MenuBarDecorator is somehow worse off than someone who has to grapple with the out-of-the-box functionality? If so, I have to disagree. I believe that this tutorial series contains an amazing amount of information on how to use the new functionality present in Flash MX 2004 and Flash MX 2004 Pro and is an invaluable resource to the community. Something that would really make all our lives easier, however, is documentation befitting an application like Flash.

Again, this might be your right, but I kinda wish the tone had been a little more even. Maybe I'm just being oversensitive. But I hope you'll consider the effect it has on someone looking for information and finding a rant that tells them to give up looking for the right way to do something.
Again, if there is any instance in which I have told readers that they cannot do something that they can, please point it out to me and I will update it with the information you provide (I don't care if the said information was ever in the documentation or only known internally at Macromedia -- what's important is that people know it.)

In the one instance that you have provided this information, I have updated the tutorial (to use headerText instead of the private __header property). And, as I had stated earlier, I had only used the private property because I had been forced to look into the code due to a lack of documentation and that is what I found there.

Finally, thanks again for taking the time to post here and to share your thoughts with us. I'm sorry you found the tone to be uneven but that is probably because keeping an even tone was never one of the criteria for this series. Quite the contrary, all our authors were told to "tell it like it is" and call an "apple an apple" (I've seen too many publications where even the term "bug" gets rewritten as a "hiccup" to make it seem less than what it is -- I don't believe that this benefits anyone as it leads to the glossing over of issues which then remain unfixed.) Please remember that we're all in the same boat here. Flash is an amazing tool and an ever-expanding canvas and we all want it to be the best that it can be. If we're a little harsh sometimes, it's only because we care (or have just spent the last four hours hitting our heads on the wall -- or in the case of Peter, his *fist*)
Reply With Quote  
aral aral is offline 2003-10-03 #17 Old  
Originally posted by nig
reading through some of my replies, I have to apologize for my tone as well.
No apology necessary, we're not robots here. I don't think the world would be a better place if we were all detached, unemotional individuals.

I think you just know how to get to me
I'm really not trying to if its any consolation!

I don't want to insult you at all Aral, and I admire the service you've done here.
Thanks Nigel -- the same here. I've mentioned several times already that the component architecture is quite amazing. That's why it annoys me all the more when it's blemished by missing/faulty docs and/or slight inconsistencies.

Let's figure out how I can get MM's docs updated *and* the tutorials updated so that the people around here actually have the right info from both sides.
I'm definitely ready to help out any way I can. Just let me know what you need from this end.

Wow, let me update, I just looked over some of what you were talking about in the help Aral, and there's some really foul stuff in there. Looks like some HelpIDs are colliding... Who would have guessed that "Alert.cancelLabel Specifies an XML data source" for a Tree. Thanks for pointing that out.
Np, glad to hear you guys are on it
Reply With Quote  
markem99 markem99 is offline 2003-10-03 #18 Old  
Aral,

I've looked at MenuBarDecorator.as - you are looping thru the firstChild.childNodes array to build menus and eventListeners. But if you used MenuBarRef.dataProvider = menuStructure.firstChild the menuBar is built for you. No need to build your own menus and then addMenu them to the menuBar. Must still build the eventListeners of course but I think this code could be significantly shortened. I know it works because I'm looking at it right now - i used your xml file (changed "name" atts back to "label") and loaded it into a menuBar with simply

var myMenuBarDP = new XML();
myMenuBarDP.ignoreWhite = true;

myMenuBarDP.load("menubar.xml");

myMenuBarDP.onLoad = function(success){

if(success){

myMenuBar.labelField = "label"; // just to be safe

myMenuBar.dataProvider = myMenuBarDP.firstChild;

} else {
trace("error loading XML file");
}
};

with no MenuBarDecorator.as Now I would still use a modified MenuBarDecorator to set up the eventListeners (I like the way you have incorporated that into the XML file) but that uses only some of the code. If I have time I will rewrite MBD.as and send to you. Crossing lines somewhere.
Reply With Quote  
Peter-Hall Peter-Hall is offline 2003-10-03 #19 Old  
Originally posted by Aral:
Nigel, I really have to disagree on this. Take a look at Outlook (the Folder List). Both the vertical scrollbar and the horizontal scrollbar work correctly. By using the maxHPosition hack, we're turning the horizontal scrollbar into a non-proportional scrollbar. In other words, the thumb-size no longer displays the amount of the whole width that is currently visible.
I have to disagree with that observation. The outlook tree's horizontal scrollbar is proportional to the width of the widest open node - even if it is not in view. In Flash MX I built a horizontal scroll for Listbox, which was proportional to visible items - and it was weird and confusing to use.
Reply With Quote  
nig nig is offline 2003-10-03 #20 Old  
I'm agreeing with Peter here (wow, big surprise, I know). The thing is, a solution that's forced to measure data that has a potential to scale up to 1000s of records just won't work. And you can't just measure what's in view, because then as you scroll, the bloody hscrollbar is dancing all over hell and the user really thinks something's gone wrong (I've tried this as well). I'm working on a project now where this issue has come up yet again, and a team of like 10 MM engineers haven't solved it in any good way... we're reverting to hardcoded solutions again. So I've had this same argument a few times now and am starting to feel pretty confident my end is holding up.

Aral, I think your main complaints are a little on the abstract side. So, one scroller is content-proportional and one isn't... I'm missing the huge impact on usability. Essentially the maxHPosition *feature* gives us 2 options :

a) figure out the size you think your content is yourself, adjust maxH to fit. Use textField's getPreferredWidth if you want to.

b) Just add a good couple of hundred pixels of buffer space.. make an educated guess as to the longest width you'll need, and stick to it. This is almost always going to be a "good enough" solution. And given the choice between a "good enough" and a solution that really could cripple the performance of the control, you can guess what I'll do.

For this good enough case of adding a buffer, the worst thing I can imagine happening is that someone *might* think that there's something way off to the right in the scrollable region, scroll over to look for it, see that there's nothing, be mildly disappointed, and scroll back to the left. In general, I've found that users really only start caring about the hScrollBar (as long as it stays still) once they see some content is cut off, and we've covered that case.

One of the more prominent examples I can think of right now for the static buffer approach is SciteFlash, which I've been pretty pleased with.. It just has a scrollBar that lets you scroll a fixed number of pixels to the right. And something tells me it's faster than average editors in some small part because of it. Once in a long while I run into a situation where I wish it would scroll a little more to fit my content, but it's definitely acceptable for me using it constantly in my day to day life.

anyhow, I think I've rambled enough for another day!

nig
Reply With Quote  
slyone slyone is offline slyone lives in United States 2003-10-03 #21 Old  
Can someone explain why one would use the Loader Component when the MovieClipLoader Class seems more flexible and just as easy to code?
Reply With Quote  
pkerman pkerman is offline 2003-10-03 #22 Old  
All I can say is I'm glad I wrote the article on video!

Thanks,
Phillip
Reply With Quote  
slyone slyone is offline slyone lives in United States 2003-10-04 #23 Old  
Phillip- Your book "Actionscripting in FlashMX" is always on my desk. Will there be an update for MX04?
Reply With Quote  
markem99 markem99 is offline 2003-10-04 #24 Old  
Aral and others interested,

Please have a look at a modified and simplified MenuBarDecorator class at:

http://www.tc.umn.edu/~mulho005/test...arDecorator.as

Don't forget to change your "name" attributes back to "label" for the two menu nodes in the menubar.xml
Reply With Quote  
pkerman pkerman is offline 2003-10-04 #25 Old  
Originally posted by slyone
Phillip- Your book "Actionscripting in FlashMX" is always on my desk. Will there be an update for MX04?
No. It just didn't sell enough compared to the work involved. I might post a self-published "update" to the book. But I can't compete with my publisher.

However, I do have a book that's nearly the same as an update--it's at the printers so will be available any day. Called: Flash MX 2004 for Rich Internet Applications. It's similar to ASIFMX but doesn't cover much basic programming fundamentals. I'm real happy with it so check it out.

I appreciate you keeping my book around!

Thanks,
Phillip
Reply With Quote  
miko's Avatar miko miko is offline Administrator miko lives in United States a lot of Creative Assets 2003-10-04 #26 Old  
Originally posted by pkerman
All I can say is I'm glad I wrote the article on video!

Thanks,
Phillip
Thanks for such a superb and in-depth tutorial pkerman
Reply With Quote  
eyezberg eyezberg is offline 2003-10-05 #27 Old  
Aral,
thank you for this very complete run-down on the usage of the new components. As X-mas is still 2 months away, I haven't upgraded to 2004 yet (and I am a little bit hesitant after reading lots of posts about all the bugs in the new version.. example: http://64.207.155.38/forums/showthre...threadid=34107 ), so I'm gathering infos at the moment to get me up & running as quick as possible once/if a make the upgrade. These tutorials are really a good intro, it was weird opening the demo, dragging a push button on stage, and no click handler in the component parameters..now what.. you explained all of them, some of the new ones look really nice, but some look as if they requiere 2004 Pro as you are using forms? (accordeon)

You might want to change the example for the radio buttons, as it still says (from the checkboxes one) "select all.." and you can only select ONE radio...

What I really miss here (did I miss the link?) is a link to a printable version and another to a complete document with all the components in it, I had to copy/paste 16 tut's into word, would make this refernce a lot easier to read/keep on the desk ...

Thanks anyway... and Flash Documentation got worse and worse since v5 where at least you got the manuals.. hope they will be doing something about that soon!
Reply With Quote  
gfxTwin gfxTwin is offline 2003-10-05 #28 Old  
I agree with eyezberg, A printable version would really help the tutorials to be more useful for us. I've gone through one ink cartridge already and filled a folder completely full with tidbits and info on FMX04, and I'm probably not going to stop until I can get a printed manual from Macromedia (or others). My screen real estate is at a higher premium than my desktop real estate. I also like to read in my hammock.

Thanks!
Reply With Quote  
luar luar is offline 2003-10-06 #29 Old  
for tree component horizontal scroll bar issue, why flash mx tree component can do so, flash mx2004 tree component cannot, what difference behind?
Reply With Quote  
jaiatpm jaiatpm is offline 2003-10-09 #30 Old  
Hi Aral,

Subject:Menu Component
Issue: Listening to submenu change event

I need to create a menu structure like the one below.

+File
+New
-New 1
-New 2
+Open
-Open 1
-Open 2
-Open 3


Then content of the File->New Menu will be dynamic. I tried to create this structure in a lot of ways. I succeeded using the below code.



dp = new XML();

mnuFile = dp.addMenuItem("File");

mnuFileNew = mnuFile.addMenuItem("New");
mnuFile.addMenuItem("Open");

mnuFileNew.addMenuItem("New 1");
mnuFileNew.addMenuItem("New 2");
mnuFileNew.addMenuItem("New 3");

menuBar.dataProvider = xml;

menuBar.addEventListener("change", this);


It shows the proper hierarchy. But I am not able to register for the "change" event. I need to listen for the change event of "New 1", "New 2", ... items.

When I tried creating single level menus the change listener worked perfectly. At that time I have used menuBar.createMenu() to create the File Menu and used menu.addEventListener().


Am I doing the right thing to create sub-menus?


Thanks
Jai
Reply With Quote  
wolfie75 wolfie75 is offline 2003-10-14 #31 Old  
Last edited by wolfie75 : 2003-10-15 at 06:21.
Question about the menubar. How do u trap a click in the menubar when there is no menuitems attatched to it. Or is it required width a menuitem.

ps: love ure tutorials and sorry for bad English, not my native language.

Never mind I found the solution

Didn´t see any documentations on it though.The labels in the menubar is reffered to mbItem200,mbItem201 and so forth. So I just added a onPress function to these objects.

have a nice day!
Reply With Quote  
FinnFlash FinnFlash is offline 2003-10-20 #32 Old  
Question about the loader/progressbar tutorial: I did everything according to the tutorial but when I try to view it, I get an error message saying that it can´t open the loader contents (the cat&meow). The file is there and opens nicely when I open it with 'open file' command. I'm a newbie to Flash trying to learn it so I may have made some basic mistake or something...any ideas?
Reply With Quote  
FinnFlash FinnFlash is offline 2003-10-20 #33 Old  
Problem solved, I told you it could be a stupid mistake from a beginner, and it was! I imported the .fla file not the .swf that the program was looking for. Well, well, you live, you learn
Reply With Quote  
imanru imanru is offline 2003-10-24 #34 Old  
Can someone tell me in a DataGrid Component how to trace out multiple selections? My data grids supports multi selections, but it only traces one of them out! Anyone got an idea on how to get it to trace multiple selections?

Imanru
Reply With Quote  
slieb17 slieb17 is offline 2003-11-01 #35 Old  
Question re Accordion component
Great tutorials, but one quick (and hopefully easy) question. The Accordion component uses three separate forms in your example, each of which display a static text field. If, however, I wanted them to be dynamic text fields and, more importantly, I wanted to dynamically change the values, how would I reference them from ActionScript? I've tried all combinations but can't seem to get it to work. Thanks for your help.
Reply With Quote  
cancerinfo cancerinfo is offline 2003-11-01 #36 Old  
Last edited by cancerinfo : 2003-11-01 at 14:45.
Great tutorials! Helped me a lot. Here is an addition to the List component. I am developing XML based search engine for which I needed the new List component. There are two parameters from the search which are important: "itName" for the names of items to be listed and "itDescription" for the description when users click the names in the list. Here is the script for the listbox, which i worked out when these parameters are passed on:

ActionScript Code:
  1. //function for the listbox
  2. function chooseItem  (itName,itDescription) {
  3.     myItem = [{data:itDescription}];      //create array for listitems, use "data"
  4.     myList.addItem(itName,itDescription);
  5.     myListBoxListener = new Object();
  6.     myListBoxListener.change = function ( myItem ){
  7.         var eventSource = myItem.target;           
  8.         var theSelectedItem = eventSource.selectedItem;
  9.         var theSelectedItemData = theSelectedItem.data;
  10.         myField.htmlText = theSelectedItemData;  //textfield to print the text from itDescription
  11. }
  12. }

This may help others with similar problems.
Reply With Quote  
godowsky godowsky is offline 2003-11-03 #37 Old  
using the menu component, not the menubar componen
Hi, - just read the tutorial on the menubar component, - I wonder what I have to do to change the code to work with the menu component...

Or do you know of any other tutorials regarding the menu component?

Best regards

Godowsky
Reply With Quote  
vontiger vontiger is offline 2003-11-10 #38 Old  
Gaaaah, Button Component.
I'm working on an video presentation.
And I want a button in frame 1 that
takes me to frame 2.
Aslo the button should set the variable
"movie_toplay" to "ultrashock1.flv".

Does any one know how to do this ?

I can't get it to work. The variable gets stuck in
frame 1.

I use:
ActionScript Code:
  1. myButtonListener = new Object();
  2.            myButtonListener.click = function ()
  3.            {
  4.              var movie_toplay = "ultrashock1.flv";
  5.              nextFrame();
  6.            }
  7. myButton.addEventListener("click", myButtonListener);


In frame 2 it's says that it's "undefined"
with the code:
ActionScript Code:
  1. trace(movie_toplay);



!! I'm really !!
Reply With Quote  
demon3d2 demon3d2 is offline 2003-11-11 #39 Old  
treeview - open/close branch
I'm studying the tree component..
I have a fairly large xml displayed in the tree - and i thought of making a method for closing a branch when another is opened.

Though i've got problems with it closing a branch when i click a branch inside a branch etc.

Any ideas/suggestions?!?

// Demon3D
Reply With Quote  
jefferis jefferis is offline 2003-11-11 #40 Old  
Text Area = a loss of functionality?
First, let me say, THANK YOU for your tutorials. This is a great site. I'm delving into 2004 Pro and sometimes I feel like I'm back in grade school. Nothing I learned seems to work anymore; or at least it doesn't work the way it did, and the info is lacking to make a successful transition.

On a side note, the Menubar tutorial reveals what I think is the deficit of the new architexture. Rather than visually creating the buttons, you have to create everything by long hand coding. That may give more control later, but for setup, it is neither simple, nor intuitive - it is a drag and step backwards. That is the kind of thing a component should handle with a Dreamweaver or FW like popup interface.

On the TextArea, I am completely lost. All I want is to regain the functionality of Flash 5 where I can import html text files. I feel I may be seriously missing something, but I can't seem to use url relative info in the text field. I FEAR I may not be missing something. Controlling background, text color, etc, seems only to be available through frame AS globals, and html tagging only is available through raw files pasted into the text field, vs. imported via a url link and interchangeable. Since I'm unsure about the viability of using the older Text components {MX AS1} in my new creations, I feel stuck with the incapacity of the current resources. I'm hoping I'm completely missing it and someone can set me straight.
You'd think that handling text content would be the easiest, rather than the hardest thing to do.
Maybe the textinput field is the way to go, but again, there isn't a Scroll component that fits well with that component if I read things correctly.
Any help dearly appreciated.
Thanks
Jeff
Reply With Quote  
1|2|3|>|>> Page 1 of 4
Thread Tools
Display Modes Rate This Thread
Rate This Thread: