Making A Button to make something happen....?!
Okay... Basically, what I'm trying to do is make it so that
when the user clicks a little arrow, some more text is revealed....
For example... the user might see..
"Bid starts at 15:00 GMT >"
Then the user can click the ">" and the following is
shown..
"Bid starts at 15:00 GMT (16:00 CET) <"
As the moment I've got a white area that moves across to the
right and uncovers the last bit of text - I'm pretty new to
Flash... so any help is much appreciated!!
Thanks!
is your "white area" a movie clip?
It's a button
I would make it a Movie Clip, and on frame 1 put a stop();
action, then on lets say frame 10, make it large as to reveal the
text and put stop(); and showwwhiteleft._visible = true; , then on
frame 20 make the white small again and add gotoAndStop(1);. Give
it an instance name, lets say reveal_mc... have reveal_mc mask your
text content.
showwhiteright._visible = true;
showwhiteright.onRelease = function(){
reveal_mc.play();
this._visible = false;
then your other arrow to make it go away, name it
showwhiteleft
showwhiteleft.onRelease = function()
this._visible = false;
reveal_mc.play();
This might seem confusing, so give me a minute, and I'll whip
up an example FLA
Similar Messages
-
How do I make something happen only once on a true condition in a loop
So I have a way of doing this, but it uses a dreaded local variable, and seems to me that it might be unreliable.
What I want to happen is to have something happen only once on a condition that will remain true. What I need is to set something after a given amount of time, but I only want to set it once after that time has been reached. Problem is, if I use a range, it could be true more than once, if I use a greater than, it'll be true every time after the set time, and if I use an equal, there's no way to know that the particular millisecond value will even appear in the loop.
Maybe I'm wrong in even using those comparison functions... Any ideas would be greatly appreciated. See the attached vi for a better look at what I'm trying to do... (v7.0)
Thanks,
Geoff
Attachments:
Question.vi 16 KBThe "Idle" state that the help file refers to is the "non-running"
state. The Top Level VI must end execution before any "First Time" VIs will
return TRUE after being called initially.
Therefore, if your application calls a subVI at the beginning of the
Test portion, on the next iteration of the loop it will return FALSE
from that subVI, since your main VI never stopped running, and received
a TRUE from the "First Time" on the initial test loop.
If you have code that you want to execute only on the first run of your
entire program, "First Time" should work fine. If you have code that
you only want to execute on the first iteration of just the Test loop,
the "First Time" VI is not ideal.
I think that shift registers are going to provide the best solution,
however you mentioned that for your particular application that is not
ideal. Could you describe a little bit more why shift registers are
problematic?
Thanks Geoff, let us know.
DWeiland
Applications Engineer
National Instruments
www.ni.com/support
Dan Weiland -
How to make something happen when an object touches another
In my game I'm making (actionscript 3.0), I need the game to gotoAndStop once a circle goes "out of bounds". Is there a syntax or something about on impact or something? Please help I'm a begginer.
that's working, but the problem is I only want it to be triggered when it hits the outline, not the fill. The circle is within a maze. How do I make it so that if part of the circle goes outside the inside area it triggers a gotoAndStop command?
-
How do I call create a public function to make something happen in another .swf
Hi guys,
I am trying to create a public function, i have a decument class with all of my variables in it, I have worked out how to bring in external .swf files, now I need a way to have an even trigger something on a separate .swf
So at the moment I have a flunction that works on the parent
stage.addEventListener(MouseEvent.MOUSE_MOVE, mousePosition);
function mousePosition(event:MouseEvent) {
if(mouseX>=125)
navigator.visible=false;
trace(mouseX);
So now how do I make this function public?
When I try to put it into my document class I get errors because the navigator MC is only on the main timeline. (not in the other swf's that I am opening)
I am trying to work out how to call the function using a string in my doc class
public var nav1:String="navigator";
Then the function
public function resetnav()
String(nav1+".visible=false;");
Which seemed like a good idea, but it doesn't work..
Can you guys help me out here?
Cheers
subHey sorry I spoke too soon, I thought my code was working but my mouse tracking code is actually working off the main timeline. I sill wan to be able to use your examples though, what is the go with psuedo code? SWF1ToSWF2Connection what is the correct dot syntax for this?
Cheers
sub -
Make something happen after 4 MCs Play
Hi,
I need to have 4 buttons that play 4 different MCs. I want a 5th MC to play after all 4 MCs have been played. Any ideas on how to do this in AS2?
Thanks.
Danvar n:Number = 0;
var btnNum:Number = 4;
// assign each button a property (eg, ivar) that's = 1 for your first button, 2 for your 2nd etc.
// each buttons mouse handler should call the function below and pass that property value
function buttonF(i:Number):Void{
n = Math.max(n,n ^ (1 << i));
if(n==Math.pow(2,btnNum+1)-2){
// do whatever. all buttons responded. -
Just got my new iPad Air and noticed that the screen calibration is off. For example if I select the circle to place something there I have to select outside of the circle to make it happen. I did not have this issue on my previous iPad.
Try this - Reset the iPad by holding down on the Sleep and Home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons. (This is equivalent to rebooting your computer.) No data/files will be erased.
If no fix, Take it to an Apple Store for evaluation.
Make a Genius Bar Reservation
http://www.apple.com/retail/geniusbar/
Cheers, Tom -
When I call someone using FaceTime from my mac, they can see me but not hear me. Is there something I need to do to make this happen? I also have an iPad 2 and FaceTime works great on it if I call somebody. Why no sound from my mac FaceTime using a mac pro and isight camera, mike combo.
If I use google it works. If I use Ichat, it works. If I use skype it works.This sounds like something similar to https://discussions.apple.com/thread/3388112?start=105&tstart=0.
Try turning down the speak volume (System Preferences->Sound->Output->Output Volume) or the microphone gain (System Preferences->Sound->Input->Input Volume). Do this on both sides of the call. -
I have thousands of photos on my Mac. If something happens to my Mac obviously, I don't want to lose the photos. I do Time Machine back ups to an external hard drive once a week. Is this good enough to make sure my pictures don't get lost?
tgs6164 wrote:
I have thousands of photos on my Mac. If something happens to my Mac obviously, I don't want to lose the photos. I do Time Machine back ups to an external hard drive once a week. Is this good enough to make sure my pictures don't get lost?
Purchase a couple of these when they go on sale.
Start burning all the photos onto DVDs.
At least you'll have all your photos if your computer, time machine or any other backup you use goes bonkers. -
If i am making an app, and copy something from a site that may is copyrighted and make money on it will that be illigal ?
Just like 10 best jokes etc.That would be a copyright violation.
If Apple requests it, you have to be able to show documentation that shows you have the right to use the content in your app. -
Making a button rollover change a movie clip's frame
Hi again everyone,
I knew how to do this in AS2 but now I am having problems
with making a button on the stage goto a frame in a movie clip on
the stage.
I've attached a sample of my code below, hopefully you'll see
the error and be able to point it out to me?
I have a movie clip on the stage that has different
information in different frames. I want to make it so that when
someone rolls over the button, the movie clip fades in and goes to
the correct frame to display the information.
With this setup the way it is below, I keep getting "Warning:
3590: void used where a Boolean value was expected. The expression
will be type coerced to Boolean.
I know where the problem is happening, "function
XXX(event:MouseEvent):void {navigateToURL(XXXweb)}"
How can I write this differently and eliminate this problem?
Thanks,
JeremiahI'll give that a shot, thanks!
A follow up question to that one, is there a way to make it
so that I can have one rolled over function applied to several
buttons / frames in the movie clip? This movie clip has 50+ frames
in it and if I could reduce my coding, it would make life a lot
easier.
Thanks,
Jeremiah -
Making a button on an imported PSD
Hi all... it seemed like a simple process but I cant seem to get this right... I got a button there, but the URL wont go, ie, the click does nothing.
I imported a PSD layered image to Flash CS3, into a new blank layer. I need basically an area of this PSD to be "image mapped" so what I did was create a rectangle with the rect tool, over the area I needed the hot spot.
Here I tried to do a transparent box and border (alpha 0) but the outline is still there even though the box is "empty." (any quickie on this would be appreciated, I did select the transparent box, no color, and tried alpha, both same result)
I made that into a symbol, then I double clicked into there to fill in the key pts for the over, hit, etc., states.... I dont have any effects here btw, as simple as we can get.
After that I right clicked on the buttonand entered the action script ("reserve" is the name of my button symbol)
reserve.onRelease=function(){
getURL("http://www.redeggnyc.com/menu2.htm");
which gave no errors on validation.
When I preview in Flash, everything looks good except the thin black border and the fact that when the button is pressed, nothing happens. I am assuming this is a little mistake somewhere, or maybe I am just tired! Thanks!I did my old fallback routine of going back to something that worked in the past even though it is old code:
on (release) {
getURL("h-t-t-p-:-/-/-w-w-w-.-redeggnyc-.-c-om/menu2-.-h-t-m");
and that works.
Now does anyone know what I did wrong with the first try?
Any downside in keeping this older code?
Thanks.
P.S. I made the alpha 0 after I made the button etc... then it worked fine. When you make it 0 before u make the button then I think u will have problems. -
I am using the big date calendar template in iPhoto. I am on Lion 10.7.2, macbook air. The names of the months are on each calendar page but something happens when I send the data to Apple. The names are part of the template. They are not text boxes. I lose two names on the calendar after it is sent to Apple. Apple suggested I make a pdf file of my calendar before sending it in and check to make sure every name shows. I did this with a calendar I just sent in. The calendar was correct. All names of the months were showing. After sending the data two month names disappeard because when it arrived by mail, it was incorrect. Apple looked at my calendar via a pdf file and it was incorrect. This is second time this has happened. I called Apple and they had me delete several folders in the Library folder, some preferences and do a complete reinstall of iPhoto. I have not yet remade the defective calendar. I am wondering if anyone else has had this problem?
kathyControl-click on the background of the view all pages window and select "Preview Calendar" from the contextual menu.
You can also save the pdf as a file to compare to the printed calendar. If the two names are visible in the pdf file then the printed copy should show them. Contact Apple for a refund. Apple Print Products - Apple Store (U.S.) -
Windows 8.1 something happened and windows 8.1 Pro couldn't be installed.
After the release of windows 8.1 preview I attempted the installation of 8.1 preview which failed. I decided it wasn't worth the bother until it was officially released so I left it uninstalled.
After the official release of 8.1 yesterday I opened the store on my windows 8 PC and I was presented with the Windows 8.1 download. I selected this and attempted to install. this failed with the message "Something happened and Windows 8.1 Preview
failed to install" Whoops!
I clearly hadn't done my windows updates to update the store so I ran these updates and in my windows store was the Official windows 8.1 download.
Once downloaded it then fails saying "Something happened and windows 8.1 Pro couldn't be installed Please try again Error Code 0x80070003"
now im stuck with that. is there a way I can clear the downloaded files and have the store re-download them? where are the stores downloads kept?
im really stuck with this one....Hi,
This error code means that the specified path couldn't be found.
To fix this issue, I suggest we try following steps and try to reinstall again:
Step 1: Clean update temp files:
1. Press Windows key + R, type service.msc and press enter.
2. Stop Windows update service.
3. Run following command lines one by one to clear update temp files:
cd %windir%
ren SoftwareDistribution SDTemp
exit
4. Restart Windows update service.
Step 2: Clear windows store catch:
Press the Windows + R keys on your keyboard to open the Run dialog.
Type WSReset.exe, and click/tap on OK.
The Store will now open, and state the following: The cache for the store was cleared. You can now browse the store for apps
Then, please try to update Windows 8.1 again.
Regards,
Kate Li
We
are trying to better understand customer views on social support experience, so your participation in this
interview project would be greatly appreciated if you have time.
Thanks for helping make community forums a great place. -
Radio Button to make other field Mandatory
I have two Radio Buttons that I want when clicked on (either one) to make a Number Field mandatory. I have viewed many websites on setting a mandatory field but the script I am using will not work. I have tried a couple ways of writing it but I seem to be missing something.
I have used this script in the Show of: click & change
Here is the script that I'm using right now.
if (this.rawValue==1)
AssemblyNu-1.mandatory ="error";
else
AssemblyNu-1.mandatory ="disabled";
And this one:
if (this.rawValue==2)
AssemblyNu-1.mandatory ="error";
else
AssemblyNu-1.mandatory ="disabled";
Thanks,
HHud5757So, I put a quick form together to test your code.
On the change event of the radio button list (not the radio button itself), I added:
if (this.rawValue == 1) tfTest.mandatory = "error";
else tfTest.mandatory = "disabled";
In my case, the radio button with the value of 1 is the one I want to make the field mandatory. If you want either button to make it mandatory, then use:
if (this.rawValue == 1 || this.rawValue == 2) tfTest.mandatory = "error"; -
Is there a way to create a button to make an entire page visible or hidden in an Acrobat XI form?
Note that Reader (11 or otherwise) cannot show/hide pages that are templates. Reader 11 can spawn new pages from templates and delete any spawned pages, however. It also supports spawning a template by overlaying it on an existing page.
The UI in Acrobat 11 for making a page a template and setting its visibility is found under: Tools > Document Processing > Page Templates
Here are some links to the JavaScript documentation: http://livedocs.adobe.com/acrobat_sdk/9.1/Acrobat9_1_HTMLHelp/JS_API_AcroJS.88.1216.html
http://livedocs.adobe.com/acrobat_sdk/9.1/Acrobat9_1_HTMLHelp/JS_Dev_Templates.80.2.html
Note that some of this information is outdated with respect to Reader 11.
Maybe you are looking for
-
Windows XP installation on Satellite L300 11G
Hello, I have a problem installing windows XP on my Toshiba Satellite L300 11G. It does not recognize the SATA HDD. SO I downloaded the files that were needed (Intel Storage....) and then I get an error: iaStor is corrupted. I am pretty new in comput
-
Hi One of my photos will not show in the screen save/desktop, I was wondering why. I did do a new version from master and then it showed, but what i would like to know is why? Ta
-
Authorization Control of Customer Master
Hi Experts, Is it possible to create a role with authorization restrict as follows ? The role is authorized to change both general level and company code level data of customer group A. For customer group B, however, it is authorized to change compan
-
How to number and message screening in nokia 5630?
hi can anyone tell me, how to use the number and message screening in nokia 5630. it is a mobile with s60 platform and has number and message screening mentioned as its built in specification. i cant figure it out how?
-
Hi... I am doing soap to JDBC to soap Scenario. In that, the request mapping is working fine. But the response mapping, i am having the error. The below is the response structure of the jdbc <?xml version="1.0" encoding="UTF-8"?> <ns0:MT_StoredPro