Adding Horizontal Scroll Functionality To ListBox Component
how can i add a horizontall scroll bar to ListBox Component, so that when the item width is greater than the original width of the ListBox, the ListBox show a horizontal scroll at bottom.
I came to know that i can extend the class to provide this functionality but dont know the code to do it. any body knows this how to do it please.
FlashKit > Flash Help > Flash ActionScript
Posted on: 02-01-2006, 11:58 AM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Having Horizontal Scroll In The ListBox Component
Is it possible to have a horizontal scroll in the listbox component. I do not want to use text boxes with the scroll components because i am not able to get the selection feature that listbox provides.
Any help would be appreciated.
Thanks
San
Listbox Horizontal Scroll
Hi all:
I am working with a listbox that shows data from a database. I would like to know if is it possible to have a horizontal scrollbar that aloms me to see the long fields. I cannot make the listbox as big as the long fields sizes that´s why i want to scroll it.
Thanks in advance.
Adding Some Scroll Functionality
Anyone know how to add keyboard (up and down arrows) functionality to move the scroll up and down? And clicking the scroll bar area to move the scroll?
ScrollBar Component - Adding Keyboard Functionality
Is there a way to add keyboard commands to the ScrollBar Component? For example, I would like my text to scroll down, when I press the 'Down Arrow' key. I would like to give people the option to use both the mouse...and keyboard to scroll through text...is this possible? Any ideas or help would be appreciated...thanks!
Scroll Bar Ui Component Horizontal How-to
in flash MX....
How does the scroll bar UI Component work horizontaly and what would one use it for?
I cannot get it to work horizontal true.
I drag the scroll bar into the lower portion of a dynamic text box and the scroll bar snaps to the bottom horizontaly set to true but when I test movie it does not work.
I have a text field that I want to scroll, but I do not have enough room on the side. So I am trying to put a scroll bar at the bottom and if it works, I then plan on changing the skin of the arrows to point up and down.
Am I on the right track?????
Please help!!
Scroll Bar UI Component Horizontal How-to
in flash MX....
How does the scroll bar UI Component work horizontaly and what would one use it for?
I cannot get it to work horizontal true.
I drag the scroll bar into the lower portion of a dynamic text box and the scroll bar snaps to the bottom horizontaly set to true but when I test movie it does not work.
I have a text field that I want to scroll, but I do not have enough room on the side. So I am trying to put a scroll bar at the bottom and if it works, I then plan on changing the skin of the arrows to point up and down.
Am I on the right track?????
Please help!!
Horizontal Scroll In List Component?
Is there an option to turn on the horizontal scroll for the list component? I have some list entries that are longer than the list is wide, so they get cut off at the end...can this be done?
Horizontal Scroll In List Component?
Is there an option to turn on the horizontal scroll for the list component? I have some list entries that are longer than the list is wide, so they get cut off at the end...can this be done?
Horizontal Scroll In List Component?
Is there an option to turn on the horizontal scroll for the list component? I have some list entries that are longer than the list is wide, so they get cut off at the end...can this be done?
List Component Horizontal Scroll Problem.
This one is strange,
I just add a Flash CS3 List Component on stage and fill it's data provider with very long labels. When I run movie, no horizontal scroll appears in list component. Even if I set it's horizontalScrollPolicy property to ON, it just displays a disabled scrollbar.
Does anybody know the reason?
Thanks.
List Component - Auto-Adjust Horizontal Scroll
I am trying to implement an auto adjust horizontal scroll in a list that changes based on the users choices...
I am currently adjusting the hscroll by checking the length of the string that makes up the label...this however doesn't give me an accurate measurement when it comes to lower case and upper case letters...because two strings may be the same length but visually appear quite different in length...
each of the following strings has 10 characters
1234567890
HHHHHHHHHH
hhhhhhhhhh
So this is not a good way of doing this since the lower case strings fit in the list but yet are longer than my max char length and therefore enable the horizontal scroll...
Is there any way to get the width of the label or the pixel width of a string?
List Component - Auto-Adjust Horizontal Scroll
I am trying to implement an auto adjust horizontal scroll in a list that changes based on the users choices...
I am currently adjusting the hscroll by checking the length of the string that makes up the label...this however doesn't give me an accurate measurement when it comes to lower case and upper case letters...because two strings may be the same length but visually appear quite different in length...
each of the following strings has 10 characters
1234567890
HHHHHHHHHH
hhhhhhhhhh
So this is not a good way of doing this since the lower case strings fit in the list but yet are longer than my max char length and therefore enable the horizontal scroll...
Is there any way to get the width of the label or the pixel width of a string?
Adding Scrollbar Functionality
Anyone know how to add keyboard (up and down arrows) functionality to move the scroll up and down? And clicking the scroll bar area to move the scroll?
Adding Wait Functionality
I have an application in which there is a class that reads an XML file into an array. This array contains a number of strings that are sent when the user performs an action. Some of the strings, however, are also special instructions to the application to do something like displaying a popup. Now, I'm trying to add a wait functionality where I can place a "wait:#" step into the XML file and have the app wait # seconds. I have been trying to work with the class to add this in, but it doesn't seem to be working.
Here's what I have for the code:
Code:
class images.classes.StepListMgr {
...
...variables here
...
function checkFp(fp:String) {
if (fp==stepArray[0]) {
removeArrElmt(steArray, 0);
checkSpecSteps();
checkWaitStep();
}
}
function checkSpecSteps() {
//Check special step strings
if (waitInt) {
clearInterval(waitInt);
waitInt = null;
}
check4Popup();
check4EsdStartEnd();
checkDone();
}
private function checkDone() {
if (stepArray.length == 0) {
_global.modDone();
}
}
private function check4Popup() {
if (stepArray[0].length == 1) {
var step = stepArray[0][0].val;
if (step.substr(0, 6) == "popup:") {
var msgBox = step.substr(6);
var popUpParams = msgBox.split(":");
removeArrElmt(stepArray, 0);
_global.CallPopUp(popUpParams[0], popUpParams[1]);
}
}
}
private function check4EsdStartEnd() {
if (stepArray[0].length == 1) {
var step = stepArray[0][0].val;
if (step.substr(0,3)=="esd") {
if (step.substr(3)=="Start") {
_global.esdNow = true;
} else if (step.substr(3)=="End") {
_global.esdNow = false;
}
removeArrElmt(stepArray, 0);
}
}
}
function checkWaitStep() {
var step = stepArray[0][0].val;
if (step.substr(0,5)=="wait:") {
numSecs = Number(step.substr(5))*1000;
waitInt = setInterval(checkSpecSteps,numSecs);
}
}
}
It seems like the interval waitInt is clearing before I want it to. Does anyone see what I'm doing wrong here?
Chris
Adding Visual Assorting Functionality
I'm building an interactive catalog for a large textile company and would like my users to be able to select items as they go through the "catalog" and save their selections to a visual/virtual workspace so that they may later view their assortment before they place their order. I'm not actually looking for a shopping cart, but the functionality might be similar. I would just like them to be able to click a graphic and save the same graphic to another scene in the project if possible.
Scroll Bar Component Question: Adding "tick Marks" To ScrollThumb Graphic?
I am trying to add "tick marks" to the middle of a component scroll bar, like the scroll bars in Windows XP. I have added the tick mark graphics to the scrollThumb graphics, which adds the tick mark to the scroll bar, but here's the problem:
when the scroll bar scales to fit different amounts of text, the tick marks scale with it.
Has anyone else dealt with this?
Any suggestions?
Thanks in advance.
PS- I've attached a jpeg of the problem
Adding File Upload Functionality To An Application
Hi guys,
i trying to do an application that can let user uploads their own images into the application and edit.
i tried the tutorial in flash help> Actionscript 2.0> Learning Actionscript 2.0 in Adobe Flash > Adding file upload functionality to an application
It doesnt work. any one tried it before?
or any one knows how to do this?
Adding HTML Functionality To Billy T's Dynamic Scroller
I've been working with the dynamic scroller Billy T created.
I've created scrollers in the past that use a txt file and have ability to underline, href, etc but I believe this code doesn't allow that because of textFormat code. Could somebody take a peek and let me know if its possible.
Thank you the code is below:
ActionScript Code:
// code by Billy T
// initialise some positions
textBwidth = 348;
textBheight = 200;
theMask._height = 100;
// set this to whatever you want
theMask._width = 348;
theMask._x = 0;
theMask._y = 0;
dragger._x = Math.round(theMask._width);
dragger._y = 0;
theText._x = 0;
theText._y = 0;
border._width = theMask._width+dragger._width;
border._height = theMask._height;
border._x = 0;
border._y = 0;
// set a variable
targY = 0;
// set the drag action of the dragger
// drag is restricted to the height of the mask
dragger.onPress = function() {
startDrag(this, false, this._x, 0, this._x, theMask._height-this._height);
};
// stop the drag
dragger.onRelease = dragger.onReleaseOutside=function () { stopDrag();};
// set the mask for the text
theText.setMask(theMask);
// the scrolling animation
theText.onEnterFrame = function() {
// set a variable
// this variable basically stores info regarding what fraction of the total text
// is being displayed through the mask and ensures that dragging the dragger
// from top to bottom will reveal all the text.
// this allows you to change the amount of text and the scroller will update itself
//
scrollAmount = (theText._height-(theMask._height/1.3))/(theMask._height-dragger._height);
// adjust the height of the dragger to reflect the amount of content available to see
dragger._height = theMask._height/scrollAmount;
// set a new target y position
targY = -dragger._y*scrollAmount;
// set the y of the text to 1/5 of the distance between its current y and the target y
// change the 5 to a lower number for faster scrolling or a higher number for slower scrolling
// Math.round() keeps it on a whole pixel number - good for pixel fonts
this._y -= Math.round((this._y-targY)/5);
};
The code which formats the text is:
ActionScript Code:
this.createTextField("theTextBox", 1, 0, 0, _parent.textBwidth, _parent.textBheight);
theTextBox.textColor = "0x000000";
theTextBox.selectable = false;
theTextBox.wordWrap = true;
myTextFormat = new TextFormat();
myTextFormat.font = "thaFont";
myTextFormat.size = 8;
theTextBox.embedFonts = true;
loadData = new LoadVars();
loadData.load("content.txt");
loadData.onLoad = function(success) {
if (success) {
theTextBox.text = loadData.theText;
theTextBox.setTextFormat(myTextFormat);
theTextBox.autosize ="center";
} else {
trace("failed");
}
};
Adding More Functionality To Border Resizer Photo Gallery
This is my first post thanks to the aweosme Resizing border photo gallery thread. I want to expand it but I need some help understanding it.
Here is my working example using the sample photos -> http://russellheimlich.com/del/FlashPhotoGallery.swf
I started off with the V3 Thumbs Scrolled Version by Stalker. I've rearranged some items on the stage in order to accomodate the bigger images I hope to use when this is done.
I've added the preloader for each image myself.
My Code
Code:
MovieClip.prototype.loadPic = function(pic, id) {
info.text = "";
this._alpha = 0;
this.loadMovie(pic);
temp = this._parent.createEmptyMovieClip("temp2", 998);
temp.onEnterFrame = function() {
var t = container.getBytesTotal(), l = container.getBytesLoaded();
bar._visible = 1;
per = Math.round((l/t)*100);
if (per == "Nan"){
per = 0
}
if (Math.round(l/t) == 1 && container._width != 0 && container._height != 0) {
var w = container._width+spacing, h = container._height+spacing;
border.resizeMe(w, h, id);
bar._visible = 0;
loadText.text = "";
delete this.onEnterFrame;
}
else {
bar._width = per;//gives the bar a max width 100
loadText.text = per+" % loaded";
}
};
};
I have this annoying problem that the loader bar is visible while the thumbs load. And when I click a thumbnail, the % text briefly displays NaN. How can I fix these inconveniences?
From here I want to add stationary Next and Previous buttons at the top. I looked at the code in the massive post but this version is cryptic.
So far I have just managed to get this:
Code:
nextb.onRelease = function() {
cur++;
if (cur > pArray.length-1) {
container.loadPic(pArray[0], iArray[0]);
} else {
container.loadPic(pArray[0], iArray[0]);
}
};
Which just loads the first image in the array. How do I make the button advance to the next pic?
Other things I am looking to improve upon are:
1) A display indicating the number of thumbs that have been loaded i.e. # of thumbs loaded / total # of thumbs.
2) Modifying the XML file so I can include a path variable for each gallery. This way I can list just the image filenames, making it much easier to change directories. An example would look like this:
Code:
<gallery name="Holiday" picturePath="Pics/Holiday">
<image source="pic1.jpg" thumb="th1.jpg" title="Earth"/>
</gallery>
<gallery name="Juniper" picturePath="Pics/Juniper">
<image source="pic1.jpg" thumb="th1.jpg" title="flower"/>
</gallery>
That is about it for now. If anyone has a heavily commented .fla of this version I would love to read through it. Right now this stuff is a little over my head. Thanks!
Here is my full source code for anyone who wishes to read through it.
Code:
var tnNr;
spacing = 10;
container._alpha = 0;
var curLength;
MovieClip.prototype.loadPic = function(pic, id) {
info.text = "";
this._alpha = 0;
this.loadMovie(pic);
temp = this._parent.createEmptyMovieClip("temp2", 998);
temp.onEnterFrame = function() {
var t = container.getBytesTotal(), l = container.getBytesLoaded();
bar._visible = 1;
per = Math.round((l/t)*100);
if (per == "Nan"){
per = 0
}
if (Math.round(l/t) == 1 && container._width != 0 && container._height != 0) {
var w = container._width+spacing, h = container._height+spacing;
border.resizeMe(w, h, id);
bar._visible = 0;
loadText.text = "";
delete this.onEnterFrame;
}
else {
bar._width = per;//gives the bar a max width 100
loadText.text = per+" % loaded";
}
};
};
MovieClip.prototype.resizeMe = function(w, h, id) {
var speed = 3;
container._alpha = 0;
this.onEnterFrame = function() {
this._width += (w-this._width)/speed;
this._height += (h-this._height)/speed;
if (Math.abs(this._width-w)<1 && Math.abs(this._height-h)<1) {
this._width = w;
this._height = h;
container._x = this._x-this._width/2+spacing/2;
container._y = this._y-this._height/2+spacing/2;
info._y = Math.round(this._y+this._height/2+spacing/2);
container._alpha += 5;
if (container._alpha>90) {
info.text = id;
container._alpha = 100;
delete this.onEnterFrame;
}
}
};
};
function galleryChoice(q) {
pArray = new Array();
tArray = new Array();
iArray = new Array();
my_xml = new XML();
for (var j = 0; j<curLength; j++) {
this.scroll.th_nav["thmb"+j].removeMovieClip();
}
my_xml.ignoreWhite = true;
my_xml.onLoad = function(loaded) {
if (loaded) {
gallery = this.firstChild.childNodes[q];
curLength = gallery.childNodes.length;
for (var i = 0; i<gallery.childNodes.length; i++) {
pArray.push(gallery.childNodes[i].attributes.source);
tArray.push(gallery.childNodes[i].attributes.thumb);
iArray.push(gallery.childNodes[i].attributes.title);
}
}
delay = setInterval(makeButtons, 50);
};
my_xml.load("gallery.xml");
}
prevb.onRelease = function() {
cur--;
if (cur<0) {
containerMC.loadPic(pArray.length-1);
} else {
containerMC.loadPic(cur);
}
};
nextb.onRelease = function() {
cur++;
if (cur > pArray.length-1) {
container.loadPic(pArray[0], iArray[0]);
} else {
container.loadPic(pArray[0], iArray[0]);
}
};
function makeButtons() {
tnNr = 0;
clearInterval(delay);
for (var i = 0; i<tArray.length; i++) {
var thb = scroll.th_nav.thmb.duplicateMovieClip("thmb"+i, 1000+i);
thb.id = i;
thb._x = i%3*50;
thb._y = Math.floor(i/3)*50;
}
loadButtons();
}
function loadButtons() {
var tbox = scroll.th_nav["thmb"+tnNr].box;
tbox.loadMovie(tArray[tnNr]);
temp = this.createEmptyMovieClip("tmp"+tnNr, 999);
temp.onEnterFrame = function() {
bt = tbox.getBytesTotal();
bl = tbox.getBytesLoaded();
if (bt == bl && bt>4) {
nextButton();
delete this.onEnterFrame;
}
};
}
function nextButton() {
if (tnNr<tArray.length-1) {
tnNr++;
loadButtons();
} else {
activateButtons();
}
}
function activateButtons() {
mainButtons();
for (var i = 0; i<pArray.length; i++) {
var but = scroll.th_nav["thmb"+i];
but.id = i;
but.onRelease = function() {
container.loadPic(pArray[this.id], iArray[this.id]);
disButtons2(this.id);
};
}
container.loadPic(pArray[0], iArray[0]);
disButtons2(0);
}
butArray = new Array();
butArray = ["gal1_btn", "gal2_btn", "gal3_btn", "gal4_btn"];
function mainButtons() {
for (var i = 0; i<butArray.length; i++) {
this[butArray[i]].id = i;
this[butArray[i]].onRelease = function() {
galleryChoice(this.id);
disButtons(this.id);
};
}
}
function disButtons2(d) {
for (var i = 0; i<tArray.length; i++) {
if (i != d) {
this.scroll.th_nav["thmb"+i].enabled = 1;
this.scroll.th_nav["thmb"+i].box._alpha = 100;
} else {
this.scroll.th_nav["thmb"+i].enabled = 0;
this.scroll.th_nav["thmb"+i].box._alpha = 50;
}
}
}
function disButtons(d) {
for (var i = 0; i<butArray.length; i++) {
if (i != d) {
this[butArray[i]].enabled = 1;
this[butArray[i]].gotoAndStop(1);
} else {
this[butArray[i]].enabled = 0;
this[butArray[i]].gotoAndStop(2);
}
}
}
disButtons(0);
galleryChoice(0);
Scroll Wheel Functionality
How do I include scroll wheel functionality on my scrollbars in my website whenever you rollover the mask for the text?
There is a mc called mask that masks out the txt mc then on the side there is a mc called scrollbar on top of a mc called scrollbarBG which is the scrollbar.
Here is my code:
ActionScript Code:
txt.setMask(mask)
scrollbar.onMouseDown = function() {
if (this.hitTest(_root._xmouse, _root._ymouse) && txt._height>mask._height) {
this.startDrag(false, scrollbarBG._x, scrollbarBG._y, scrollbarBG._x, scrollbarBG._height-this._height)
txt.onEnterFrame = scrollThumbs;
dragging = true
}
};
scrollbar.onMouseUp = function() {
stopDrag()
dragging = false
delete this.onEnterFrame;
};
function scrollThumbs() {
var funkyVar = -this._parent.scrollbar._y*(((this._height-this._parent.scrollbar._height)/(this._parent.scrollbarBG._height-this._parent.scrollbar._height))-1)
this.Y = (funkyVar-this._y)*.2;
this._y += this.Y;
if(Math.abs(funkyVar-this._y)<1 && !dragging){
delete this.onEnterFrame
}
}
I have seen it done before I just dont know how.
If you would like to see my .fla please let me know.
Thanks!
Austin
Change Horizontal Scroll To Vertical Scroll
Hi,
I've flash source code that is having a horizontal scrolling. Anybody can help me to change this to a vertical scroll.
Pls check the attached file.
thanks in advance...
Adding Save/Open/Print Functionality To A Dynamic Text Box (offline)
Is it possible to add open/save/save as../print functionality to a flash dynamic text box. Something like a word processor. I would like to do this is CS3 but don't really know how to go about it.
I was looking at the ContextMenu Class and thought that could be of some use...
Thanks for any help
Ben
Adding To Listbox Dynamically
Hi, i am trying to add items to a list box dynamically. I am using PHP to post variables to flash. The output is like this :-
total=3&name1=jules&name2=harry&name3=phil&
I am trying make a loop that adds the varibles of name1, name2 ect until it reaches the total. When i try to do this it just enters name1, name2 and name3 into the listbox not the actual names? It works if add it like :
List.addItem(name1); The adds the item 'jules' to the listbox.
But wont work if i add it like :
x = 1;
List.addItem("name" add x);
It just adds 'name1' to the listbox?
Very wierd and frustrating! If anyone can help with the 3 lines of code that is needed to make the loop and add the items i would very grateful as i have tried everything!!!
Many thanks in advance.
Jules
Jules@hungrybear.co.uk
Adding Item To A ListBox
Hi,
i am tring to add items to a list box and it gets added shows everything in reverse order. what i mean is , if i add image1,image2,....image10, it lists image10,image9,....image1. How do I solve this? Any help appreciated. Thanks in advance.
Nesamani.E
Component Functionality Lost
I'm finding that when an external swf that uses v2 Components is loaded into a movie clip on another swf, the component loses it's functionality (unless the hosting swf already contains the component, which in my case defeats the purpose.)
I'm trying to load a swf that has a comboBox into an mc on a different swf, but after it loads the comboBox no longer works; it has focus, but doesn't drop down.
Thank you.
Adding Sound To Listbox On Rollover?
Hello,
Is it possible to have a sound triggered when you rollover listbox menu items? Either with an action or by editing the box itself perhaps? I'm using Flash MX
Thanks!
Jason
Wrapping Functionality In Custom Component
I would like to wrap some form functionality in custom component so that i could easily reuse it. The Form item right now has a text, input, and checkbox per row. It is populated by an XML. Any user change of the text or checkbox gets reflected back to the XML. The functionality works, but does require lots of typing and therefore I would like to wrap it into a custom component.
Here's my code:
Code:
private function updateMetaItem(p:XMLList, attr:String, key:String, val:String){
var res:XMLList;
var md:XMLList = p.Metadata;
if (md.length() == 0)
p.appendChild(<Metadata></Metadata>);
res = p.Metadata.MetaItem.(attribute("attribute") == attr).(attribute("key") == key);
if (res.length() == 0)
p.Metadata.appendChild(<MetaItem attribute={attr} key={key} value={val}/>);
else
p.Metadata.MetaItem.(attribute("attribute") == attr).(attribute("key") == key).@value = val;
}
<mx:FormItem label="Address" direction="horizontal" >
<mx:TextInput id="addrTxt" toolTip="Property address" editable="{editable}" text="{selectedProperty.Address.@abbreviatedAddress}"
change="selectedProperty.Address.@abbreviatedPropertyAddress = addrTxt.text" width="200"
/>
<mx:CheckBox id="addrCHK" enabled="{editable}" toolTip="Make address field public or private."
selected="{toBoolean(selectedProperty.Address.Metadata.MetaItem.(@attribute == 'abbreviatedAddress').(@key == 'public').@value)}"
change="updateMetaItem(selectedProperty.Address, 'abbreviatedAddress', 'valid', addrCHK.selected.toString() );"
/>
</mx:FormItem>
What would be an elegant solution for that?
[F8] Adding Items To A Listbox Embedded In A Movieclip
Hi all,
The movie clip I'm attaching has a text field (called module) and a listbox (called issuesBox) in it.
On stage I have a button with the following code:
Code:
on(click){
for (i=0;i<=5;i++) {
var newClip:MovieClip = _root.attachMovie("mc", "mc"+i, i,{_x:50,_y:yval});
newClip.module.text="title";
for (j=0;j<=10;j++) {
newClip.issuesBox.addItem("hi");
}
}
}
At runtime I get 5 movie clips with the text field filled with "title," like I hoped for. However, the listbox isn't getting filled 10 times like I thought it would. Any suggestions?
Thanks!
FSlider Component Dual Functionality Problem
I'm using the FSlider component from the Flash UI Components 5 group. In addition to what I have coded (below), I would also like the user to be able to drag the thumb symbol to the desired place during audio playback. Thanks for your help!
this.onEnterFrame = function() {
if (lessonAudio.playing) {
var pPos = lessonAudio.position/1000;
var pDur = lessonAudio.duration/1000;
var pBarSet = Math.round((pPos/pDur)*100);
newPosition = pBarSet;
_root.audioHolderMax.audioWinMax.progressBar.setVa lue(pBarSet);
_root.audioHolderMax.audioWinMax.progressSts.text = (pBarSet+"%");
}
};
Retaining Component Functionality In Nested Movieclip
I have a movieclip which is created at runtime using Actionscript which through XML loads inside it an image or FLV. When there is an image the movieclips acts as a button so when the user clicks on it another function executes opening a larger version of the picture.
In contrast, when an FLV is present I want the user to be able to use the media player controls to navigate the video clip. However, and heres the crux of the matter, no matter what I try the button behaviours attached to the movieclip always override the nested component. An easy way of rectifying the problem would be to get the video component to automatically play but because its part of a slideshow this is not suitable.
Any suggestions would be gratefully received.
Listbox Scroll Width
Hi There,
I am working with listbox components and am trying to adjust the width of the scrollbar. Has anyone else been able to do this? I am having a spot of bother with it.
I have found that using a scrollbar component it is possible to set the width like this:
Code:
myScrollInstance._width = 5;
But I am unsure of how to reach the scrollbar inside of a listbox
I did find this in the listbox actionscript:
Code:
this.permaScrollBar = true;
and tried to set its width property but without any luck.
If anyone can help I'd be grateful.
Matt
Linked ListBox Scroll With ScrollPlane
Hi guys:
I am trying to make an horizontal scroll to a listbox by putting it into a ScrollPlane disabling the Vertical Scroll.
I have linked the Listbox and tried with the linkage name with this sort of code:
Code:
myScrollPane.setScrollContent(Linked_Listbox)
But I cannot populate data in it dont know why. It should be something like this I think.
Code:
for (i=0; i<10, i++) {
_root.ScrollPlane_Instance.Listvuew_Instance.addItem(data);
}
Please let me know if I am doing something wrong.
Thans a lot again.
Custom Buttons For Listbox Scroll
Hi Folks
I was trying to create 2 custom buttons for the Listbox component
The up button scrolls the list up and the Down button scrolls the list down by 1 visible list screen length
Any help would be appreciated
Thanks
RG
Listbox Component?
I have a listbox on the stage named "lst_amenities". I'm tring to trace out an array of selected items from a multiple selection listBox. Problem is that i am getting an output of [objectObject] throughout the array. Below is the code that i used. Anyone have any ideas?
Code:
lst_amenities.setChangeHandler("select_amenities");
ary_amenities = ["string 1", "string 2", "string 3", "string 4"];
create_amenities(ary_amenities);
function create_amenities(ary) {
for (i=0; i<ary.length; i++) {
lst_amenities.addItem(ary[i]);
}
lst_amenities.setSelectMultiple(true);
lst_amenities.sortItemsBy("label", "ASC");
}
function select_amenities() {
ary_amenities = lst_amenities.getSelectedItems();
trace(ary_amenities);
}
Help With Listbox Component
I need to use a listbox component to set a variable in the root movie. I've input my labels and data, but am perplexed as to how to go about getting the selected item to be the variable value. The name of my listbox menu is "CampusValue" and the name of my variable in the root movie is called "campus". How do I use the Change Handler in the Property Inspector? Do I call a function there or something? I couldn't get much from the Help section on this. Thanks.
Listbox Component
I am having a problem with the listbox compnent. Can anyone tell me how to get the listbox labels to display text in a text box when clicked?
thanks
Tab Component And Listbox
i'm loading a movie when i push a tab
this movie has a combobox in it, the problem is that the rows of the combobox isn't appearing
the first row does, all others not. the dataprovider is full???
in the same movie that the combobox is located is a datagrid.
the same thing happend when i placed the datagrid direct in the movie where the tab is located, the dataprovider was full, the layout of the grid was made but the rows where empty.?????
has someone had the same problem and probably a solution???
thx
marcel
Help With The Component (listbox)
Hello i have a problem with the listbox, when i putted it in a movieclip in frame 10, and i want to add a item in my _root.
it doesnt display in the listbox.
When i put in this code:
_root.mainmenu.itemc.addItem("Potion", 50);
it wont add the item but it does add the item if the listbox is on frame1 in my movieclip, how can i solve this so it adds when on frame 10 too?
sorry but my english sucks atm
Ui Component Help: ListBox
Hello all,
I am having some difficulty setting up a listbox that when a label is selected it loads an external .txt file into a dynamic text field.
EXAMPLE:
_listbox- instance name "letters" ,contains letters a-j
_dynamic text- instance name "dynaText", has a scrollbar attacthed
_external .txt files are labeled a.txt - j.txt
_all .txt files are in the same folder as the .swf
_all instances and script are placed on frame 1 of layer 1 in scene 1
_Here is a portion of the script i was trying (and failing) to use-
if (letters == "a") {
dynaText = dynaText.load("a.txt");
}
I am almost too embarassed to post that crappy script but I am desperate for help. If I can find or be shown the solution I'll make a tutorial (if there isn't one and of course giving full credit to whomever assisted me ^^) so this question never has to come up again. Thank you in advance.
p-spiddy
EDIT: I forgot to mention that I am using Flash 6.
Listbox Component
How do I add a whole list of items to the Listbox component which all load different parts of a movieclip? There must be a really simple way to do it but i've never used one before. I can add the items, but just need to know how i can make each one goto a different part of the MC.
Cheers
ListBox Component
I am having a problem getting my down arrow on my keyboard to recognize the listbox component upon loading. I always have to press the down arrow 2 times the first time instead of once to get the highlight in the listbox to move to the next item? i'm not sure if it is a focus problem or not. the listbox component loads into the main movie on a seperate level.
thanks in advance,
Mike
ListBox Component
Code:
on(click){
formData = new LoadVars();
receiveData = new LoadVars();
cObjectArray = c.selectedItems();
for (var i = 0; i < cObjectArray.length; i++)
{
currentC = cObjectArray[i];
formData.country[i] = currentC.label;
}
formData.sendAndLoad("http://localhost/file.php", receiveData, "post");
}
I'm trying to get an array of the selected items of 'c' (an instanse of the List component named c), and then send those selected variables to the php, well the php stuff works ok, but I can't get the multiple selected variables
i've tried diferent stuff like sending a var like formData.tmp = c.selectedIndiced(); and other but all only shows 'undefined' as value.
Any example of how to manage selected values of list box?
thnkx in advance
ListBox Component
Does anyone know how to make the listbox component display so that only one option displays at a time?
Thanks.
Listbox Component
HI there...
I know that this must be basic --- When I use the List component
and added some labeles eg: Start movie 1, Start movie 2, Start Movie 3,,,,
How do I them apply the _root.pictures1. gogotoAndPlay("go");
_root.pictures2. gogotoAndPlay("go");
_root.pictures3. gogotoAndPlay("go");
Its quite simple but can someone help, didnt have luck finding
some tutors
Have a nice day:-)
Flemmming
[MX] ListBox Component
Hello,
I'm using this code to put an array into a listbox component in Flash MX
Code:
stop;
campbellAry = new Array("charlie","chris","kate","kara","jack","kathy","kim","fiona","liam",
"cesar","kaylee","john","ken","sarah","reykah");
campbellAry.sort();
for (i=0; i<campbellAry.length; i++) {
testListBox.addItem(campbellAry[i] /* + " campbell" */ );
}
I'm wondering how to give each item in the list a function? For example I'd like charlie to do something associated with the name of that item (ie loadMovie charlie.swf). How do I dynamically control each item's onRelease method's ?
Also, can I give the text a different look in the listBox somehow?
Thanks
Listbox Component?
I am wondering if someone could please tell me how I can put names into a listbox component. Thanks in advance.
ListBox Component : Need Serious Help
Hi,
I know this is going to sound as if I'm a beginner in Flash which I am not but, for some reason, my listbox component in Flash MX is not allowing me to scroll down its contents. It's loading the data from a database and doing the job just fine. Everything is loading correctly and I can see the items added, but again, it doesn't recognize the fact that it should allow me to scroll the contents and click them.
Can anyone help?
Thank you
Barzalou
Listbox Component
i would like to add a listbox full of links to something i am working on. does anyone know where i could find some info on how to customize the listbox component?
|