Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How to make Scrollbar invisible!!!  Problems!

Posted on 2008-06-24
16
Medium Priority
?
950 Views
Last Modified: 2013-11-11
Hello,

I am embarrassed to say I have spent a few hours on this already:  I have a scrollpane on my stage.  Once the user sees the scroll pane, then presses a button to continue, I would like the scrollpane to be invisible.  I have managed to make the target mc invisible but I still see the scrollbar and frame of the scrollpane.  I can't figure out what to do!!!!  (myScrollpane3 is actually an UltimateScroller, so it takes _visible as property and I believe the Flash 8 uses .visible).  I have been thinking of just drawing a box on the stage to hide it--not very efficient, but it might allow me to move forward.

Code below.

Many thanks for helping a frustrated person!
_root.mcMain._visible=false;
_root.myScrollpaneNew.visible=false;
_root.myScrollpane3._visible=false;

Open in new window

0
Comment
Question by:1Cougar
  • 7
  • 5
  • 4
16 Comments
 
LVL 12

Expert Comment

by:SamuelRostol
ID: 21854536
Hi there,

The scrollpane can be made invisible through the code:
scrollpanename._visible = false;

Take a look at the uploaded simple sample, and you will se that it works :)

Kindly,
Samuel
InvisibleComponent.zip
0
 

Author Comment

by:1Cougar
ID: 21854650
Hello and thank you.  I have been trying that, but am obviously doing something wrong.  However, I am unable to open your file, which appears to be a text file.....

Could you please upload it again?

Many thanks!


0
 
LVL 12

Expert Comment

by:SamuelRostol
ID: 21854800
Hi there,

My apologies; rename the file from InvisibleComponent.fla.txt to InvisibleComponent.fla, and you will be able to open it :)

Created in Flash CS3.

Kindly,
Samuel
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:1Cougar
ID: 21854825
Sadly, I already tried that and it says "failed to open document...".

??

0
 
LVL 12

Expert Comment

by:SamuelRostol
ID: 21854872
That probably means that you have Flash 8. Wait a second, I'll try to save for Flash 8 :)
0
 
LVL 12

Expert Comment

by:SamuelRostol
ID: 21854897
Here you go - any luck with this file?

In any case - I've posted the code as well so that you can recreate the example :)

Kindly,
Samuel
/*
Have a button named btnRemove on the Stage, as well as a normal 
scrollPane named mcScrollPane. Also, attach onto the scrollpane some content from the library.
*/
 
btnRemove.onRelease = function()
{
	mcScrollPane._visible = false;
}

Open in new window

InvisibleComponent.zip
0
 

Author Comment

by:1Cougar
ID: 21859093
I was finally able to open your file.  Yes, that works in a simple example, but I am loading things dynamically from XML and, for one, at the beginning of the  movie, I initialize the objects on the stage.  I have my statement as yours is above and it never makes my scrollpanes invisible, which is not great.  I am thinking about playing around with a white box to hide them---that's how desperate I am!

Any other ideas?


0
 
LVL 8

Expert Comment

by:Dreammonkey
ID: 21860417
try to trace this:
trace(mcScrollPane)

it should output something like :

_root.someMovieClip_mc.someOtherMovieClip_mc.mcScrollPane

if it does then copy the whole lot and paste it in the code,
just an idea...

Regards,
D
0
 

Author Comment

by:1Cougar
ID: 21860543
Hi,

Good idea--the trace is _level0.myScrollpane.  Have tried to make visible=false and it is still there!!!

Ugh.


0
 
LVL 8

Expert Comment

by:Dreammonkey
ID: 21860587
did you change the code into :

_level0.myScrollPane._visible = false;

?
0
 

Author Comment

by:1Cougar
ID: 21860690
Yes, I have changed the code and it is still there.  I am really baffled by this, but there are many objects on the stage, most of them invisible at the start of the movie, so maybe that is somehow the cause.  Every thing else is "invisible" but the scrollpanes.  Strange, no?



0
 
LVL 8

Expert Comment

by:Dreammonkey
ID: 21860721
There must be an explanation for this, but I cannot see it here, the only solution I see is that you upload your fla, so can have a look...
0
 

Author Comment

by:1Cougar
ID: 21860799
OK, will up load the file.  Please remember this is a work in progress and I am just learning....so, I'm afraid a lot of the code is not "optimized".  But, maybe you can see something I can't.

Thanks in advance!
TestTryJune08.fla.txt
0
 
LVL 8

Expert Comment

by:Dreammonkey
ID: 21861132
Man, I'm sorry to say this, but this file would drive even the Dalai Lama nuts....
YOur code is full with scrollpanes, it's like scrollpane's heaven,
and scrollpane n°3 is definitely God !

Allthough, I did found out that it isn't God that's still visible, it's just one of his (fallen) Angels...

when you trace :
trace(myScrollpane3._visible);

it traces:
false

... I think you lost track of one of your sheap, 1Cougar,

sorry for the all the irony, it's getting late,...

regards,
D
0
 
LVL 8

Accepted Solution

by:
Dreammonkey earned 2000 total points
ID: 21861410
Ok sorry for last post, I got a little carried away there...

I found a solution : replace line 40:
_level0.myScrollpane3._visible = false;
with:
_level0.myScrollpane3._alpha = 0;

I don't get this either....but this does the trick
0
 

Author Comment

by:1Cougar
ID: 21862925
Thanks--it worked and no offense taken--I am under a deadline to get something out and was planning on making the code pretty later.  There are only 2 scrollpanes really--I am trying to use the UltimateScroller component.  So, 2 of the scrollpanes are UltimateScroller components.  Since I have had trouble getting those to work properly, each of their targets is set to the respective scrollpanes.  Maybe I will solve the myScrollpane3._visible problem later when I sort those out.  Or, I may draw the scrollpanes dynamically when I need them.  But, for now, this is the solution!

Many thanks again for your patience and help!

Cheers,

0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
The last time I worked with Flash and Socket connections was in AS1. A recent project required flash connecting to a Socket, and sending receiving information - we figured it would be easy enough - we all know about the socket policy documents and c…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…
Suggested Courses

876 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question