JavaScript and Authorware

Hello

I know a little JavaScript and a bit of Authorware and I try to use Javascript in Authorware. I'm stuck on something and can't seem to find how to get the value of an icon of interaction using Javascript...

I know with Authorware is: valueToRound: = EntryText

My problem is that I'm trying to round a decimal value ou.5 IE 2.3 becomes 2 and 2.4 becomes 2.5 I can do it with Javascript code, I don't know how to do it with Authorware (only to a whole number).

If you know how to round a number integer ou.5 in Authorware that would be a huge bonus, if I am simply happy to discover how to get the value of an icon of interaction using Javascript

Help in both directions would be very grateful!

Thank you

"SudsMalone" wrote in message
News:gbhj6c$PFL$1@forums. Macromedia.com...
> If you know how to round a number integer ou.5 in Authorware that would be
> be a huge bonus.

Something like:

roundedvalue: = Round(2*value)/2

should do it.

(no doubt you would like 2.3 2.5 rounded and not 2.0 if...)

Chris Forecast

Tags: Authorware

Similar Questions

  • Proposals feature: possibility to add the button to enable/disable JavaScript and Flash easily? The lack of horizontal navigation.

    It is very useful and safe to disable JavaScript and Flash is not needed. But sometimes they must be used.

    It's too frustrating toggle JS menu, and No-Script add-on is not very practical. It would be better if it had the button toggle to enable or disable JavaScript. Also necessary for Flash. You could implement this simple feature for the next update.

    Also: Ealier, it was possible to navigate horizontally rss-buttons and tabs of arrows. Later, this feature has been removed. Could get it back you.

    This module includes a button to toggle JavaScript market / stop.

    https://addons.Mozilla.org/en-us/Firefox/addon/QuickJava/

  • Help. Window opens on the Firefox browser that says Application JavaScript and according to what he says 101. There is an OK bitton. When I click on OK, place just the window again and again.

    Help. Window opens on the Firefox browser that says Application JavaScript and according to what he says 101. There is an OK bitton. When I click on OK, place back the window. Then once again hit OK and box disappears when I move my mouse the same Monte box again. I even called Apple support. They tried things; got me well maybe some ting setbold textin Firefox preferences. It started right after the installation of update of Mac at the close. Any help, please. My browser is completely blocked (obviously) in this loop! [email protected] jason

    Hello

    Please check if this happens in Safe Mode.

    Extensions of the issues

    Troubleshooting Extensions and themes

    Uninstalling the modules

    Uninstalling toolbars

    Safe mode disables the installed Extensionsand themes (appearance) in (Alt + T) Tools > Add-ons. Hardware acceleration is also temporarily disabled - manual setting is Tools > Options > Advanced > general > use hardware acceleration when available. Options > Advanced. All these parameters/additional custom modules can also be individually or collectively disabled/enabled/changed to normal mode of Firefox to check if an extension, theme or hardware acceleration is causing issues.

  • I was told that Web Developer had buttons that enabled me to disable JavaScript and CSS (Cascading Style Sheets), but I do not see these keys on Firefox version 10. How can I access these two functions? So how can I activate JavaScript later? Thank you.

    I need the way to points that allows to disable JavaScript (and then to turn it on) and allows to turn off CSS.

    These access points do not appear on the Web Developer (v.10)

    Thank you.

    Are you sure that whoever told you that was not referring to the add-on Web Developer?

    https://addons.Mozilla.org/en-us/Firefox/addon/Web-Developer/?src=SS

    It has features allowing disabling of Javascript and style sheets.

  • Defective JavaScript and cannot be removed or reinstalled, get «fatal error during installation»

    As a result of an error indicating that javascript has not been installed (Internet options/security/scripting is set correctly) I tried to remove the Javascript (before a new installation) but which have resulted in a message: fatal error during installation (probably installshield). I'm so stuck without Javascript and cannot update or delete it.

    I have version 6 update 27 Javascript, Windows XP and Internet explorer 8

    Any help will be greatly appreciated

    Barry

    Hello

    You can run solve this link and try to uninstall java and check if the problem persists:

    http://support.Microsoft.com/mats/Program_Install_and_Uninstall

  • We write plain HTML5, JavaScript and CSS in the development of webworks BB 10.

    Hi all

    We write plain HTML5, JavaScript and CSS in the development of webworks BB 10.

    Thank you all

    Yes.

    Here is an example of an application named BrickBreaker which was written entirely in HTML5, JavaScript and CSS.  It can be pacakged in BlackBerry 10 application using SDK WebWorks:

    https://github.com/BlackBerry/BB10-WebWorks-community-samples/tree/master/BrickBreaker

  • plugin JavaScript and css file does not load in Apex 5.0 in certain circumstances

    Hello

    I have a strange problem. I've migrated a 4.2 application and its plugins to version 5.0.

    On my test server that everything works perfectly, plugins properly load css and javascript libraries.

    On the server to the client, even if the configuration is identical (Oracle 11 g, ADR 3.0, Glassfish), any plugin loading fails and triggers an error like:

    http://W2k3-Theos-t-AP/ords/i3std/r/2105/files/plugin/32865463423023705/v1/Select2.CSS

    Method: GET

    Status: 404 not found

    Currently the Plugin files (javascript and css) are stored in Oracle. Does it mean that I have muss stores as static files?

    Thanks for help

    Frédéric

    Kiran,

    Unlock APEX_LISTENER and APEX_REST_PUBLIC_USER and everything works perfectly.

    Thanks to Peter and Kiran, Apex is an excellent product thanks to its fantastic team

    Best regards

    Frédéric

  • How can I compress javascript and CSS files in my export of Muse?

    How can I compress javascript and CSS files in my export of Muse? When I test my Web site with website speed test in pingdom (http://tools.pingdom.com/fpt/)

    the site has a low rating in the category of the number of CSS and javascript files because there is so much of... Is there a way to reduce the number of CSS files

    that are generated?

    In addition, the code we can place in Muse to tell Javascript to load last so it won't slow down the site are there?

    Thank you

    Theresa

    Regarding your first question. There is no way to compress the code CSS or javascript in files of Muse.

    When Muse exports a site it generates the CSS code for each page. There is no way to combine code similar to a lot of pages on a site by using Muse. (it is not the same process that build you using Dreamweaver or php coding)

  • Database update issue with JavaScript and local storage

    Hi all

    I come from a PHP background and a newbie with HTML5 and JavaScript, and local storage


    Currently I'm building a mobile web application that uses a remote database.

    I have a question about the update database.

    Currently, I set it up so that when the user logs on successfully - Local Storage fields are loaded from the remote database query using a jQuery.Get. This seems to work well.

    When it's time to update the data, I fill the form in local storage, allow the user edit fields, then:

    -a form post to send data to the remote php page that updates the database...

    Here is where I have a question: How can I make sure the edit went through good - what is better to do it now?

    -Can I set up a json response to say whether or not the update was successful

    or

    -Query the database once more and recover the fields to compare the edit results

    or

    -Another technique to do of course change it went through OK

    - then if successful, I can update the local storage

    Q: what is the best way to ensure that the database has been correctly updated (and also not lose time with Access database useless)?

    Is there a recommended for this?

    In addition, if possible this beginner can use a clear example...

    Why not to use jquery get () callback status where if the success is returned then to update local storage?

    best,

    Shocker

  • How to eliminate the cutters of rendering JavaScript and CSS in content above both

    Google suggests to increase the speed of loading my page www.oldeworldelace.com/index.htm I should 'eliminate cutters of JavaScript and CSS rendering in the above content both'. How I do the PCOC?  I would like your advice.

    Markup (HTML) and style (CSS) rules are needed for a page. Most of the client scripts (JS) are not required to display a page. So JS files should only be included at the end of the page where loading the same will not impede rendering page.

  • How can I use external CSS, JavaScript and Images in the PeopleSoft Portal?

    I develop a website and I need to put my CSS, JavaScript and IMG files in a folder on the server that can be used by the objects of my HTML.

    Where should I put the images? How can I get the HTML code of the objects can read these images?

    I tried several things like:

    < link rel = "stylesheet" href = "" < % = psCtxPath % > < % = psHome % > \MyStyleSheet.css "rel ="stylesheet"type =" text/css">"

    "< link rel ="stylesheet"href="\portal\MyStyleSheet.css "rel ="stylesheet"type =" text/css">

    "< link rel ="stylesheet"href="\ps\images\portal_pa\MyStyleSheet.css "rel ="stylesheet"type =" text/css">

    By "Object HTML" do you mean HTML definitions in App Designer? If so, how you use these HTML definitions? You use the PeopleCode GetHTMLText? You want to store your images and CSS in the database where it won't delete whenever you regenerate PIA (Tools fixes and upgrades)? If the answer to all these is Yes, use %Bind(:1) (or: 2: 3, etc.) for your images, JavaScript and CSS. In your PeopleCode, use % Response.GetImageURL (IMAGE.NAME_OF_YOUR_IMAGE), Response.GetJavaScriptURL (HTML.NAME_OF_YOUR_JS_DEFN), %Response.GetStylesheetURL(STYLESHEET.) YOUR_CSS_NAME) to obtain the URL of the item stored in the cache. Pass this URL to the GetHTMLText function as the value for one of bind variables in the HTML code.

    If you put images in the folder root (PORTAL.war) of your web server, and reference to ' / '. If you put them in a folder under PORTAL.war, for example, a folder named ps, use/ps/nameoffile.png. Always use ' / ', not '-' for internet URLS.

  • How to get the value of the outputtext in javascript and send it to backing bean

    Hi Experts ADF,

    JDev Version 11.1.1.7.0

    I have the following: the value of the outputtext must be treated in javascript and the serverlistener method has the same value. I founded this value returns a string that wshould see the mouseover NIJ.

    Help, please. Thanks in advance.

    < af:column sortProperty = "#{bindings." OrderProposalReadClient.hints.exceptions.name}.

    filterable = "true" sortable = "true".

    headerText = "#{suiviewBundle.EXCEPTIONS} '"

    ID = "c16" >

    < af:outputText value = "#{row.exceptions}" id = "ot32" clientComponent = "true" > "

    < af:clientListener type = "mouseOver".

    method = "customJsFunction" / >

    < af:serverListener type = "mycustomserverEvent".

    Method="#{pageFlowScope.ChangeOrderProposalBean.handleServerEvent}"/ >

    < / af:outputText >

    < / af:column >

    JavaScript

    < af:resource type = "javascript" >

    var customJsFunction = function (event)

    {

    var exceptiondata = AdfPage.PAGE.findComponentByAbsoluteId ('ot32');

    AdfCustomEvent.queue ();

    Returns true;

    }

    < / af:resource >

    BackingBean

    public String handleServerEvent(EC ClientEvent)

    {

    Please let me know how to get the value that javascript code sends here.

    Let's say javascript sends the value of outputtext as "001".

    So, I have to check "001" in my list and return a value that appears on mouseover.

    }

    Kind regards
    Roy

    Hello, Roy.

    To use the value on another component of the user interface, I shows an example:

    -code of the page

    shortDesc = "shortDesc" >

    method = "customJsFunction" / >


    -the javascript code

    var customJsFunction = function (event)

    {

    var exceptiondata = event.getSource ().findComponent("ot32").getValue ();

    AdfCustomEvent.queue (event.getSource (),

    "mycustomserverEvent,"

    {param1:exceptiondata},

    (true);

    Returns true;

    }

    -OutputTextCase11.java

    public void handleServerEvent (EC ClientEvent)

    {

    String param = (String) ce.getParameters () .get ("param1");

    RichOutputText outputText = (RichOutputText) ce.getComponent () .findComponent ("ot1");

    outputText.setShortDesc (param);

    outputText.setValue (param);

    AdfFacesContext.getCurrentInstance () .addPartialTarget (outputText);

    }

    I hope this helps you.

    RFH.

  • Option 4.2 "includes Standard JavaScript and CSS" deleted?

    Hello

    APEX 4.2, Oracle 11 g r2.

    I've been using the option * 'Include Standard JavaScript and CSS' * starting from page attributes. It has been set on * 'No' * in all the pages that I manage my own JQuery versions.
    We went to 4.2 yesterday, and I see that the option is always there on the 4.2.

    I just tried to put it on 'Yes' to a test, but now the option disappeared! I can't set it to 'no '...
    On each page, if I set to 'Yes' and apply the changes, the option isn't here when I return to the page attributes.

    Bug?
    Or maybe that this option has been removed from the 4.2?

    Hello

    Yes, this has been intentionally removed for applications / pages that do not use the feature. As you said yourself, and what we saw other customers is that someone wants not just to exclude a single page and like rather than control it for the application. That makes a little heavier, because a developer had to define for each new page.

    That's why we created a placeholder to the template page for * #APEX_JAVASCRIPT #* and * #APEX_CSS #* give control you allowing to load libraries of the APEX and if you don't want to load them, simply remove them from the already stressed page as Vikram model.

    Concerning
    Patrick
    -----------
    My Blog: http://www.inside-oracle-apex.com
    APEX Plug-Ins: http://apex.oracle.com/plugins
    Twitter: http://www.twitter.com/patrickwolf

  • JavaScript and advanced Actions

    I try to do the following in Captivate 6.0:

    1. Display an animated gif of the dice on a slide in Captivate [work]
    2. When you click on:
      1. Generate a number 1-6 as a result of "the launch" and assign it to a variable [of work]
      2. Show / hide items on the page so that the user can see the result of their deployment and a next button so they can continue to [does not]

    I tried to reach the Show / Hide by:

    • Jump to the current slide, using JavaScript and
    • Advanced action on enter to the slide, which checks if the value of the dice has been set and then show / hide objects as you wish.

    Unfortunately, it seems that when I jump to the same slide using JavaScript, enter it event is not called. If I click back, and then forward on the playback bar, I see the desired result.

    I have included the JavaScript and the tip Action (fixed on enter to the slide) below.

    Is there a way to:

    1. Update the JavaScript so that when I jump to the current slide, enter to be executed? OR
    2. Call my action advanced directly from JavaScript? OR
    3. Get the desired result in a different way... I'm not particularly fussed I used JavaScript or advanced Actions to achieve this!

    Here are the details:

    Variable (set through project-> Variables...)


    Dice_Value = - 1

    Fast action (in between)

    If Dice_Value is greater than or equal to 1

    Hide Dice_Animation

    Hide Dice_Click_Box

    See the Dice_Value_Text

    See the Dice_Next

    See the Dice_Next_Caption

    On the other

    See the Dice_Animation
    See the Dice_Click_Box
    Hide Dice_Value_Text
    Hide Dice_Next
    Hide Dice_Next_Caption

    JavaScript (called when the user clicks on the animation of dice)

    function rollTheDice() {}

    cpObj = document var. Captivate;
    var diceValue = 1;
    currentTime var = cpObj.cpEIGetValue ('cpInfoCurrentTime');
    var lastDigit = parseInt (currentTime.charAt (7));
    {Switch (lastDigit)}

    case 7:

    diceValue = 1;
    break;

    case 8:

    diceValue = 2;
    break;

    case 9:

    diceValue = 4;
    break;

    case 0:

    diceValue = 5;
    break;

    by default:

    diceValue = lastDigit;
    break;

    }
    cpObj.cpEISetValue ('m_VarHandle.Dice_Value', diceValue);
    cpObj.cpEISetValue ('cpCmndGotoSlide', cpObj.cpEIGetValue ('rdinfoCurrentSlide'));
    cpObj.cpEISetValue('rdcmndResume',1);

    }

    rollTheDice();

    If you return to the first image of a slide, the action that is triggered by the event progress on enter is not executed. I'm an advanced user action, Javascript is still just a mystery to me. If I want to enter action to repeat itself, I will return to the slide before the slide that contains a conditional action (slide has already been visited, so setting a variable and checking that one) get immediately to the next slide. This way subsequently enter event repeats. Haven't checked it yet, but maybe browse the framework before the first frame of the current slide will be work as well (micro-navigation), something I have to try it because maybe you need to get a couple of frames further back.

    Lilybiri

  • I know only Javascript and I would like to convert a large number of documents scanned in layers to get on white a4 canvas

    I had more than 400 scanned documents of A4 format. But they are not of uniform size. Fortunately, they are all 300 dpi. They were created on a scanner. When opened in photoshop, they contain random patches that are transparent, although there seems to be no difficulty watching a player adobe themon.

    My laptop had "GB of RAM and does not accept CS4 I have Photoshop CS3.» My javascript and photoshop are both restricted to the basic skills.

    I want to set up each document on a white A4 format photoshop background of300dpi, as a layer, flatten it out and save it as a desired page.

    As it is quite tedious, I have a script that will perform this task on a single file.

    I would like to run this script on each file manually.

    If possible, I would also like to put the individual pages in a folder and run the factual script on all the files in the folder.

    Inmates or suggestions will be appreciated with gratitude

    Thank you, peter

    The script will process all files jpg, tif or psd, which are located in the selected folder. What format are the documents that you use?

Maybe you are looking for