Buttons in arrays - no action
I have 36 buttons I need action on. To avoid a lot of similar
commands, I am trying to assign the button names in an array using
a for loop. Tracing the array values, gives the correct button
names, but there is no action when I press the buttons. If anyone
can tell me the reason, I would really appreciate it. Thanks in
advance!
Here is the code:
var farge_btn_tbl:Array = new Array(4); // Array assigning
button instance names (works fine)
var farge_fr_tbl:Array = new Array(4); // Array assigning
frame label names (works fine)
for (var i:Number = 0; i < 4; i++) {
farge = "farge" + String(i+1); // The button instance names
are assigned
farge = "fargen" + String(i+1); // The frame label names are
assigned
farge_btn_tbl
= farge; // Placing the values in the button array
farge_fr_tbl = fargen; // Placing the values in the
frame array
farge.onRelease = function(){ // Trying to get action on the
buttons
gotoAndStop(fargen + String(i+1)); // it doesn't work
}
Thankyou!
That worked fine. First it didn't work on button 4, but when
I changed both the button instance names to start with 0 ending
with 3 (instead of starting with 1 ending with 4, and did the same
with the instance names, than it worked perfect! I have spend all
the day on this headache (it's 17 pm here in Norway), so I really
appreciate your help!
Anyway the buttons are inside a movie clip. The code I wrote
here, was just a test file, not my big project file. Is it possible
to put the movie clip instance name in front of this? Or after? ( I
am a newbee.)
Or should I put the code in the timeline of the
movieclip?
Similar Messages
-
Button to execute custom action(s)
I have created 3 custom actions which print, e-mail, and fax Opportunities when executed. These actions work perfect from the SAP GUI, but I am unable to execute them from PCUI CRM as there is no button which is linked to these actions. Please note that there is a button which prints the opprotunity, and a button which sends an e-mail, but these buttons do not execute the custom Actions which I have created!
I would like to add a button (custom or standard) to PCUI CRM which would execute my custom Actions.
I understand how to add buttons to PCUI CRM, but I do not know how to link that button to my custom actions. Is this even necessary? I see an "Actions" button, but am not sure if this will automatically link to the custom actions.
Thanks in advance for any and all responses to my post.Thanks for your your help but it was the same thing Timo said before and it didn´t work for me. But I found out what was wrong :) and you were both right.
I used a template that had a form and when I inserted a form on the page this form was inside the form in the template and that did so that it didn´t work.
Atlantic Viking -
Im trying to create a fading button with a fading action.
I can't figure out how to create a fading button with an additional action to it. I'll do my best to lay out how the actions should work: [red = not working]
Button > roll over> fade> (that part I have down perfectly) click button> button temporarily replaced with text> roll out of text > process repeated in reverse for smooth fading.
Every time I set up all these actions and get it the way I want, I run into a bunch of problems:
Text box holder and text can not be over the button. (Where I need them to sit) When they sit over the button it blocks it from doing any of its specified actions. So I'll make the text box and text a hidden item, then they lose their transition and start flickering when they are interacted with.
This is basically the last piece of my clients new site and I just need to figure this one little thing out. Please help if possible!Try to group the elements so they work together.
-
How do I use the button states in an action script?
In my Captivate 8 project I use smart shape as buttons. The buttons have different images presented dependent on the state of the button. I have also created a simple action script that shows what happens when the button is pressed. When the button has been pressed the normal state of the button appear. I, however, want the down state of the button to remain visible util the user presses another button. How do I accomplish this? Is there variables for the buttons different state or how can I create that?
BR,
MadeleineWhen you talk about 'actionscript' do you mean advanced or shared actions? You cannot write actionscript within Captivate, only Javascript. If you use advanced/shared actions they'll be converted on runtime to either Actionscript (for SWF output) or Javascript (for HTML5 output).
The states in shape buttons are the normal way buttons behave (not only in Flash). If you are indeed using shared/advanced actions, and you want the down state to remain until the next shape button is clicked, you'll have to go the way described by iFlashAppsToo. Create shapes that have the look of the down state, make them initially invisible and group all those shapes on one slide. Add two statements to the shared/advanced action (please do use shared actions, you'll save time):
Hide Group so that eventual down mimicked states on previously clicked buttons disappear
Show Im_Downx to show the down image for that button -
Problem setting a hidden item value when button clicked with dynamic action or pl/sql process
Apex 4.1
Oracle 11g
I have a page that consists of a main region and several sub regions. I have a pl/sql process in After Header SET_DISPLAY(:P400_DISPLAY :='MAIN';)
Three subregions have a contional display where P400_DISPLAY = STORE. This works in hiding the sub regions.
Now I want to change the P400_DISPLAY value to STORE to show the subregions when I hit a button.
I tried creating a dynamic action for on click of the add button but get the following error:
The selected button uses a 'Button Template' that does not contain the #BUTTON_ID# substitution string
I went to the templates and found:
Substitution Strings
Substitution strings are used within sub templates to reference component values. This report details substitution string usage for this template.
Substitution String
Referenced
From
Description
#LINK#
Yes
Template
To be used in an "href" attribute
#JAVASCRIPT#
No
To be used in an "onclick" attribute
#LABEL#
Yes
Template
Button Label
#BUTTON_ATTRIBUTES#
No
Button Attributes
#BUTTON_ID#
No
Generated button ID will be either the button's Static ID if defined, or if not will be an internally generated ID in the format 'B' || [Internal Button ID]
I then tried creating a page process, pl/sql, :P400_DISPLAY :='STORE'; when the appropriate button is pressed. The button action is submit page. However, it does not change the P400_DISPLAY value and the subregions stay hidden.
Suggestions please on how to fix the template or change the P400_DISPLAY value?The root issue is that, although you change the value of your page item, it isn't visible to other areas of the page until it is in the session. So, any other action based on the value of your page item; the visibility of a control, a report based on the item's value, etc. will all be unaffected by changing the value of the page item until it has been changed in the session. Even after this the items are stored in the session, you must thereafter do something to cause the value to be reevaluated. To see the effect of this, observe that your page loads and evaluates the value of your page item, it sees that is "MAIN" and hides the regions. However, it doesn't reevaluate them after this.
So; your choices to get this value set in the session are to either Submit the page, or use JavaScript to set the value in the session. If you use the latter of these, you'll have to do some further work to cause the visibility tests to be re-run, So, let's stick with with the submit method.
What you've done above sounds correct for this but, there are a lot of decisions you could have made that might have caused things not to happen in the correct sequence.
Firstly, let's confirm that what I describe above is your problem. From the development environment, load the page, click the button to change the value and submit. Now, click the link labelled Session. Is it still set to MAIN? If so; this is your issue.
Let's start with the your After Header computation. Did you set it to *only* run if the current value of your page item is NULL??? If not, that's your problem.
Load Page -> Item set to 'Main' by Computation -> Click Button -> Item set to STORE -> Submit -> Load Page -> Item set to 'Main' by Computation
See the problem?
Assuming this isn't the issue, you created a Branch to the same page, right? What is your process point for the Branch? Is it *After* Validation, Computation etc? Because if not, you aren't changing the value before the submit happens.
I bet it is the first issue but, take a look at these.
Cheers,
-Joe -
How can I create a "Next" button with Insert database action
Hello,
I want to create a "Next" button that will redirect to another page and at the same time to do an INSERT database action. I've searched on google but I didn't find nothing specific that could help me.
Below are some screenshots:
http://imagizer.imageshack.us/v2/800x600q90/22/2yqj.jpg
http://imagizer.imageshack.us/v2/800x600q90/585/wbn6.jpg
Thanks.DO NOT USE THIS CODE !!!!
Declare
-- Added by ramani 20-feb-2013
Seq_Val_ Number;
begin
if :P17_NWM_DOC_NO is null then
Select Nvl(count(NWM_DOC_NO),0) + 1 -- THIS IS VERY VERY WRONG !!! REPLACE WITH A SEQUENCE !!!!!!!!!!!!!!
into Seq_Val_
from DMS_NEW_MASTER;
-- ref number
return Seq_Val_ ;
--summa oru elsif irukku
end if;
end; -
Put the Button Script in the Actions Frame
When I click each button I want it to advance the play head
to the Frame Lable.
This code works but I need to change the state of the button.
If I change the button State to Graphic in the Key Frame
Lable it makes the code not work.
I would like to have all the code the the main timeline
Actions Layer.
ie: When Button1 is pressed it goes to "F1" and is now in the
Down State.
When Button 2 is press it goes to "F2" and is in the Down
State and Button 1 goes back to its' Up State.
Here's the code:
stop();
Button1.onRelease = function() {
gotoAndStop("F1");
trace ("Frame 1");
Button2.onRelease = function() {
gotoAndStop("F2");
trace ("Frame 2");
Button3.onRelease = function() {
gotoAndStop("F3");
trace ("Frame 3");OK, I put this code in the main timeline:
stop();
//root code:
function resetButtons() {
Button1.gotoAndStop(F1);
Button2.gotoAndStop(F2);
Button3.gotoAndStop(F3);
//and then I put this code on each button
//code to place on each button
on (release){
_root.resetButtons();
this.gotoAndStop(3); //go to pressed state
on (rollOver){
if (this._currentframe <> 3)
this.gotoAndStop(2); //go to roll over state.
on (rollOut, releaseOutside){
if (this._currentframe <> 3)
this.gotoAndStop(1); // reset button to it's original state
// Nothing happens???
What am I missing here? -
Button styles not updating actions
Hi there,
I've created a button style (in this case an exit button), which updates the appearance of all of the buttons defined by that style fine, however the action for that button does not.
Is there a way to make it do so, as I'd rather not having to update 70+ buttons every time I need to alter some minor? Or is that just the way it is in Captivate?
Thanks in advance for any help you can provide.Hi there
Button Styles are separate from actions. The style controls the visual aspects of the Button. Each Button will have its own action. Many folks would likely be very frustrated if the action were forced to be the same for all Buttons when you changed a style.
Perhaps you should submit a Wish Form to Adobe to ask for a feature that allows you to also specify actions if you want. Link is in my sig.
Cheers... Rick
Helpful and Handy Links
Begin learning Captivate 5 moments from now! $29.95
Captivate Wish Form/Bug Reporting Form
Adobe Certified Captivate Training
SorcererStone Blog
Captivate eBooks -
Use back button and clear advanced action and quiz answer..
OK, so I have made a quiz where the answer for each question is recorded and given in a list at the end. However, I would like the user to be able to go back and change their answer. At the moment if the user goes back, the answer is locked and they cannot chose a diiferent option.
Does anyone know if it is possible for them to go back, select a different and still have the advanced action part record the new answer?
Thanks for any help!Only way to reset the answers to a default question slides, during the same session, is to use the Retake button on the score slide (you need to have multiple attempts of course. But that will be done at Quiz level: all answers are reset.
Another option (in CP6 and later) is to use the Submit all option, then they will be able to go back and change answers. But... I suppose you are using the system variable cpQuizInfoAnswerChoice to populate user variables with those advanced actions? That system variable is not populated when Submit all is chosen.
Last option is to use remediation, but it will probably not suit you: then user can be sent to a content slide if a question is failed, be sent back to the question slide and can then change the answer. It is not just going back one or more slides.
Custom question slides will allow what you want, but they necessitate a lot more work and you will not be able to use question pools.
Lilybiri -
Auto position buttons under array on front panel
In my gui I have an array of clusters that I am auto-sizing based on number of rows property node. I have a delete and ok button under the indicator for the array and would like to position the buttons at the bottom of the array. The easy solution is to put the buttons to the side of the array, but I'd like to make this look nice and have them appear at the bottom of the array no matter how many rows are displayed. Any suggestions?
I've looked into position property nodes which give the option of top and left, and wanted to calculate the bottom from the height, but haven't figured out how to do this.Not sure what the difficulty you're having is. The Height property gives you the height of the array, in pixels. Perhaps you're having a race condition. I'd suggest posting your code.
Of course, one issue is: what happens if the array is set to display so many rows that it extends beyond the size of the panel's window height?
In general, I'm not a fan of user interfaces where buttons start moving on me. -
Captivate button with HTML form action
Hello,
How would I create a button in Captivate 6.0 that would perform the following action below?
<form method="post" action="https://suppliers.company.com/tracker/reg/CourseReg.cfm">
<input name="submit" type="submit" value="Receive Credit">
<input name="CourseId" type="hidden" value="TR001234">
</form>
I though it would be simple, but not sure what to use. If it should be vaiables, advance actions or javascript?
thanks!You havent closed these two tags
Sex :
<html:radio property="sex" value="M">Male
<html:radio property="sex" value="F">Female<br>ram. -
I'm looking for a way to use an ArrayField to display the status of several
business components. These components are the "mapped class" of the array
and as such all attributes can show up as columns in the array.
One of the status data is "on/off" and I'd like to be able to present this
as a picture button widget in an array column. The colour/picture will
indicate the current status, a click on it will take the other status.
I have not been able to pull this off using a button (or any other widget
that has no direct mapping to an attribute). It works if I use a
PictureField and map it to an ImageData attribute of the business component.
You can catch the ChildClick on the corresponding array widget and figure
out which row of the underlying data array was clicked.
I get the feeling that buttons and other un-map-able widgets cannot be used
for the purpose I had in mind by lack of the mapped 1-to-1 relation between
widget/arrayfield row and the corresponding data array row. Can someone
confirm this or prove me wrong?
Theo de Klerk
Professional Services
Compaq Computer Corp. - the NetherlandsGeorge
Thank you for your prompt reply. I deleted my previous post because I solved the problem by simply removing the button from the form. Once I did that the script runs perfectly.
Thanks! -
How to enable enter button on keyboard for action on jsp page with adf11g
hello,
i have a login page, when i press login button with mouse it is working.
But i want to click 'enter' button on the keyboard when inputbox is focused.
For example i entered user and i entered passsword and click 'enter' button on keyboard for login action. How can i do this easily with adf11g ?
thanks for interests.i tried but on af:form we have not defaultAction. i saw, there has defaultCommand i tried this but not acceptable by warning that about, "no id or naming containers". We has an id on command but what is naming containers.
Other question is,
How to write javascript on the adf tools? We have not any, "onClick, onPressed vs..".
Thanks for helps. -
Movie Clips as buttons – ignoring my stop actions and event listeners
Ok, so I think I am hear with the proper linked files to show you guys! Pretty much learning everything, so forgive my ignorance thus far!
Anyway, I am just trying to figure out movie clips as buttons, and have been following along on Lynda.com – however, I seem to be doing these things right, but when i test my movie, the button just loops regardless of rollovers or stop actions.
You can check this address www.midnyc.com to see the failed anim, and you should be able to import it as well. Here is my coding:
function rollover (e:EVENT){
myBtn.gotoAndPlay ("in");
myBtn.addEventListener (MouseEvent.MOUSE_OVER, rollover);
function rollout (e:EVENT){
myBtn.gotoAndPlay ("out");
myBtn.addEventListener (MouseEvent.MOUSE_OUT, rollout);
thank you in advance for your help. And to KGLAD, thanks for recommending how to post a bit better! Since I never had links etc... sorry about that.Do you get any kind of error messages? Normally if there's a coding error, movieclips and other things go haywire.
For you event handler functions, try specifying the event that matches the listener event...
function rollout (e:MouseEvent){
I think "EVENT" would be wrong anyways... "Event" would be correct -
Software demo with next buttons and auto-mouse actions is confusing to viewers
Hi,
I created presentation tools for my co-workers to do a road show type thing of our software. On some slides, they must click a next button to advance, but not on others- this is intentional. However, we got the feedback that users find it confusing to see two cursors- the auto-play one and the one for the computer the presenter is using (if that makes sense?)
I suggested using a different cursor for the demos, but what they would really prefer is that they could advance the demo through a keyboard action instead of clicking that next button (but I assume the next button would still be there, right?)
Does anyone know if this is possible with Captivate 3?
Thanks,
DeeHi Dee
You are able to turn off the mouse cursor if you want. This would perhaps eliminate the confusion. You could use a Click Box instead of a Button if you wanted to pause the slide. You may also configure either a Click Box or a Button with a Keyboard shortcut the user would press to move on.
Cheers... Rick
Helpful and Handy Links
Captivate Wish Form/Bug Reporting Form
Adobe Certified Captivate Training
SorcerStone Blog
Captivate eBooks
Maybe you are looking for
-
Edcess & Hcess amount not updated in Remittance challan document (Vendor)
Hi Gurus, I am working on ECC 6.0. Should any body tell me how can i get the ed-cess & higher cess amount in remittance challan document? i have got the Basis TDS & surcharge remitted amount on remittance challan but not get the edcess & higher cess
-
What happens when I try to install iTunes 9 upgrade
I tried to install the update for iTunes and it effed everything up; so, I've tried to uninstall iTunes and download it againand this is the error I get (a windows installer window pops up): "The feature you are trying to use is on a network resource
-
Hello Experts, Need to know How can I make the Field Profit Center in the line item level of the sales order to mandatory? Please help Regards,
-
Why wont the share to youtube videos work on other ipad or iphones
many of my projects that i share to youtube are not playable on other ipads or iphones, i thought they used to play fine, but recently none of my movies work on youtube...
-
How do I check what java I have and then how dow I download the newest version?
'''I signed up for wwe.com for my birthday and Christmas present to myself. There were some problems with the how it ran so I had to secure the services of OMNITECH (who I would never recommend to anyone again as I am finding out things have been rem