I am using Adobe Captivate to create an online learning course.
An abbreviation is broken down into 6 buttons, each with an action to bring you to their respective slides. Once the slide is complete, you are brought back to the original.
The ask: the original slide with the abbreviation should only display a 'continue' button once the user has visited all 6 slides.
Is there a way to do this with ActionScript?
You can hide or show buttons in Captivate. You can also change whether or not they are shown using Advanced Actions (you'd probably need to use the conditional actions).
I'm not familiar with ActionScript, but there's an easy way to do this using the Advanced Actions in Captivate. Here's how I would approach it. First, create six variables, one for each of the six respective slides, so you could create variables called v_slide1_viewed, v_slide2_viewed, v_slide3_viewed, v_slide4_viewed, v_slide5_viewed, and v_slide6_viewed. Set their default values equal to 0 (I usually prefix my variables with v_ to distinguish from the inbuilt Captivate variables).
Now on slide 1, set an On Enter property to assign the value 1 to the variable v_slide1_viewed. This means, that when slide 1 loads, the variable 'v_slide1_viewed' will be set to 1. Similarly do this for each of the six respective slides.
Now on the abbreviation slide, create a SmartShape (Continue) button and uncheck the 'Visible in Output' so that by default this button is not displayed. Now you can write an advanced actions (conditional) script that says if
v_slide1_viewed = 1 AND
v_slide1_viewed = 2 AND
v_slide1_viewed = 3 AND
v_slide1_viewed = 4 AND
v_slide1_viewed = 5 AND
v_slide1_viewed = 6
Then Show and select the smartshape ID or whatever you named that object.
Hope this is what you were looking for.
-Sean
Related
is it possible to change to a specific interior page on the wizard?
lets say I'm on page 2 and I want to move to 5 directly without the user clicking next button 3 times.
thanks!
I am trying a lot of code and it's nothing is working for me. I need to make four radio buttons with swift when I show the question for the user to choose one of radio buttons.
Sadly, there's not a built in way to do this with Swift, but it's easy enough to code out. I'd personally recommend using this Git project, as I've heard good things about it.
If you'd like to built a radio button from scratch, I'd suggest looking a making a check button by using a regular button with a UIControlStateSelected triggering a check img, and then set the layer.cornerRadius (after setting the clipsToBounds = true of course) of your button to half its width to produce a circle!
You can create your own login by using a mutabledictionary with button tag as key for dictionary. Add green/selected image for selcted button & set "yes" value for key (button tag) in dictionary for selected button & "no" value for other button's tag.
I have an example for the same but in Objective -C
The UIControl that offers the closest behavior from radio button in swift iOS is the UISegmentedControl, take a look at the reference.
Here's apple's guidelines for mobile controls.
Some quotes from this article :
Use a segmented control to offer choices that are closely related but mutually exclusive.
A segmented control:
Consists of two or more segments whose widths are proportional, based on the total number of segments
Can display text or images
I am learning Xcode(objective C). I want to make simple calculator.
I started by adding four simple buttons and one label. Two buttons are for numbers(1 and 2), and I added variables into .m file:
int *one = 1;
int *two = 2;
Next step what I've done is that I made action on button clicked and said that label take value from that button:
self.firstLabel.text=[NSString stringWithFormat:#"%d", one);
And I made same action for another button.
Everything is fine until this step, what I want to do next is when I click on number button to add value to that label, then when I click to divide(/) button to add / sign and when I click to another button to add another value.
I want to be something like this in label: 2 / 1, and when i click = button to divide them and show result. Thanks.
EDIT:
I also added label proper into .h, and when I click on button it shows me only one value in label.
Since you are just starting to learn obj C you may want to keep your calculator simple, building a fully functional calc. can get surprisingly complex. You should consider using an RPN approach, it will make things much easier, you can just push the numbers to a stack and perform operations one at a time.
Something like: 2, enter, 1, enter + enter.
You may also want to have a look at Stanford's iOS course on Apple University, the course is in Swift but the class project was a calculator so it should give you a good reference point. Hope that helps and good luck!
you should add a custom target for each button, i.e.,
- (IBAction)addDivide:(id)sender {
self.firstLabel.text = [[NSString alloc] initWithFormat:#"%# /", self.firstLabel.text];
}
Any action will update your label.
Just a further advice for you, don't name the label as "firstLabel", try to give it a name tied to its semantics.
You are only setting the int value to the label. You need to append the value maintaining the previous text so that it appears as "2 / 1".
I'll suggest using tags for the buttons and use a common method for number buttons in your calculator.
This is more sort of logical thing rather than specific to iOS and Xcode.
Similarly when "=" is pressed use a method to calculate the result.
Advanced Installer 8.9
I have 9 check-box on a selection dialog ,on which i need to allow maximum selection of any three check-boxes.
We can show a message box displaying that only three can be selected or disable next button .
Trying to do permutation and combination will be a filthy task,is there any way where i can set a counter which increments on selection of check-boxes.
The easiest way is to create a very simple custom action in C# that checks the value of each property attached with your checkboxes. You need to call this DLL using a published event, from each checkbox, so when a user tries to select it, first the custom action checks to see if other checkboxes are not selected. If there are already 3 checkboxes selected then you need to delete the property of the new checkbox, like this:
session["CHECKBOX_PROP_1"] = "[~]";
Of course you can also use a C++ custom action if you prefer this language.
I have an asp.net MVC project with multiple pages.
For each page I must set the TAB key to go only among some controls. I know I can set:
tabIndex=x , x > 0 //to enable
tabIndex=-1, //to disable
The problem is that I have 5 controls for which the TAB key should work and 50 controls for which it should not work (the numbers are just to understand the proportions). So I was wondering if there is a way to disable the TAB key for an entire page (from *.css or a manager) and than make it enable just for the few specific controls that need it.
As far as I know this cannot be done as directly as you probably hope. What you can consider doing is executing a JS function on all elements where the tab index not set, setting it to less than zero:
var elements = document.querySelectorAll("input:not([tabindex])");
for (var i = 0; i < elements.length; i++) {
elements[i].tabindex = -1;
}
Keep in mind that depending on the number of elements that you have, this could be a drag on performance so you will want to consider benchmarking.
The other option that you could consider would be to create an HTML helper server-side which disables the tab index of the element. You can do helpers locally using the Razor #helper syntax, or globally using an extension method on the HtmlHelper class. This would perform significantly better than JS but may be a bit heavy handed depending on your scenario.
Since there were so many elements that should not be tabbed, instead or disabling TAB key for them, I changed the default behavior for the elements that had tabIndex, onkey pressed:
1) I took all elements that have tabIndex bigger than 0:
var tabbables = document.querySelectorAll("input[tabindex], textarea[tabindex]");
this is a simplified version, you should do visibility checks and select also other types of elements (e.g. buttons, etc.)
2) I replaced the default behavior in 2 cases: TAB presssed and the last element with tab index is selected or SHIFT+TAB is pressed and first element is selected. For these cases I forced the focus on the first element, respectively on the last element.
A similar question with a very good answer (not the accepted answer, the answer with most votes) is here: "Focus Next Element In Tab Index"