contribute to creating simple equation in applescript

Hi all

Can someone help me create a script for a simple mathematical equation.

(A) variable = figure with a 'total plate height' prompt before entering the figure

then

SUBTRACT the variable number (B) with a 'total height of jobs' command prompt before entering the figure

then

the result is divided by 2.

then

Guest to say "is the result of your.

in essence (A - B) / 2

Thank you

Launch the Script Editor (Launchpad: others: Script Editor). Copy and paste the following AppleScript in it. Click the hammer (compilation), then on the button ▸ to run it. Save your script as the file format: text and then option-file menu: Save slot for one of the Format (script, script or Application bundle) to your desktop. Double click to run.

Try

display the dialog box "The sheet height" default response «»

the value A text to return to result

display the dialog box "Working height" default response «»

the value B to text returned of result

we errnbr error error message number

my error_handler (errnbr, errmsg)

return

end try

ignorant digital channels

the value answer to (A - B) / 2

end ignorant

display the dialog box "Your result is" & response as text

return

on error_handler (nbr, msg)

Display alert «["& nbr &"] "& msg as critical leave after 10"»

return

end error_handler

TR

Tags: Mac OS & System Software

Similar Questions

  • I would like my year 10 students design and create simple mobile Web sites

    I would like my year 10 students design and create simple mobile suitable sites that can be used on mobile devices. The idea is that they design the site for their chosen idea and then be able to test this on their own mobile phones or their friends. Ultimately I would like that they can create a site for important events for example, camps sports carnivals etc which could be hosted on our school site. I use BusinessCatalyst for that. I tested a few sites of model by export html and then try to send the file to my phone, but the site is not resize in the phone and most of the media does not work for example sounds. What would be the best way to do this?

    Thank you

    They can use any third-party widget or plugins or use the features of BC for the creation of events, etc.

    Thank you

    Sanjit

  • Hello, I'm testing creative cloud, I really need help to know which module to install to create simple web pages

    Hello, I'm testing creative cloud, I really need help to know which module to install to create simple web pages

    Hi Cyril,.

    It depends on what you want to do. If you have experience with coding, you can download Dreamweaver to create Web sites by using the two code + design of knowledge.

    With Muse, you can design beautiful Web pages and Muse will generate the code for you.

    I hope this helps!

    -Emily

  • Need help creating an equation

    I am trying to create a field that calulates within a range of numbers according to another field.

    For example,.

    If "Text1" is 0 to 125 ml = "Text2" will fill to 1 HR

    'Text1' 126-175 ml = "Text2" 01:30 hr

    "Text1" > 176 ml = "Text2" 2 h.

    So if "Text1" was 132 ml 'Text2' would be filling then at 1:30 hr. I am able to connect fields but I'm unable to create an equation for "Text2".

    Any help would be greatly appreciated.

    Thank you

    Use this code in the Custom Text2 calculation script:

    Event.Value = "";

    var s = this.getField("Text1").value;

    Si (s ! = » ») {}

    var v = number (s);

    If (v > = 0 & v)<=125) event.value="1 hr">

    else if (v > 125 & v)<=175) event.value="1:30 hr">

    else if (v > 175) event.value = "2 h";

    }

  • Flex can be used to create simple games?

    Hello. I think to create simple games for children 6-10 years. Games can be things such as drag-and - drop and multiple choice questions. I would like to save the results to a database. Can I use Flex Builder to do this, or do you advise me to Flash? Can you point me to a resource on this?

    The reason why I ask is that I have built web applications using Flex and have some experience with Flash Basic. Building games will be very difficult if I have to use the Flash? The project will begin in January and should be completed by the end of March 2010. Thank you.

    According to your description for games Flex should be fine. It also depends on the skills and experience you have in the technology.

  • Main calculator HP cannot solve simple equation

    Hello

    I am trying to solve

    solve ((2) ^ (x) = x ^ 2, x)

    But the calculator cannot solve, or I do something wrong?

    I lost my TI Nspire CX and I have HP 1, is from a recent modern version, have been able to resolve something simple that I'm wrong. (TI Nspire resolved).

    How to solve the above equation using the first HP? I seriusly thinking to return it back.

    Thank you

    After that I played with the calculator, I found there in the CASE of the environment so that the Solver to work, if the fsolve is used in the home environment, it won't work:

    fsolve (2 ^ x = x ^ 2, x,-10.. 10)-> [-.76664695962 2 1.8]

    nSolve works too, but it does not have an interval.

    So the solution is that these commands should be used in environmental CASES.

    Thank you

  • Windows 7 disk management utility does not allow for creating simple volume: maximum number of partitions exceeded error

    I am trying to create a new partition in Win7 using the disk management utility. Shrank lecteurC existing to create unallocated space. Am not able to create a simple volume with this space unallocated due to the following error message.

    "You cannot create a new volume in this unallocated space because the disk already contains the maximum number of partitions".

    How to fix this or go around with another method to create partitions?

    Hello

    You will need to convert the dynamic disk before creating the extra partition. To do this in disk management:

    -Right-click the disk 0 (gray area) which indicates the total size of your hard drive

    -Select 'convert to dynamic disk.

    Once you have converted to dynamic disk, you will be able to go and create the new simple partition.

    I hope this helps.

    Best regards, Damian

    Damian Coverly

  • How to create simple SCM application for shopee material forms of oracle 10g

    Hi all
    I want to create a simple application of the SCM for material shopee.
    I want to know the whole idea behind it, to reset all of the concepts, the required tables, etc.

    This forum focuses on Oracle EBS. You can get a better response in the Oracle Forms forum.
    Forms

    Sandeep Gandhi

  • Creating simple shapes without the wizard

    Hi all.

    I've been hitting my head against the proverbial wall for days trying to find a way to do something that is probably very simple.

    First of all, my features. I work in Acrobat X on a Windows 7 PC. My forms were created in InDesign CS5.5.

    I'm working on the creation of a couple of forms for our sales team to deliver to our customers. We would like to see the forms digitally to fill, recordable and printable for users with reader. I know it's all doable with extended rights. No biggie.

    My problem is I want to use the submission tools automatically integrated in the Acrobat forms Wizard. I'm not at all a "submit" button. Our workflow desired is that our customers complete the form and then either print sign and deliver via mail or by fax (a form requires a signature, and our customers aren't saavy enough to use digital signatures) or for forms that do not require signatures, fill, save, and email back to us manually. All is well with the form design process, except that as soon as I use the forms tools in Acrobat to fine-tune my form, it adds functionality to submit the form to my PDF (the dreaded purple bar). I don't even have to distribute the form for this purpose. It seems to be applied as soon as I use all forms of editing tools.

    So my question is how can I change my form so that it is functional without the button submit the form applied? I did several searches on these forums and related issues found, but have not found a solution that will help me here. I have LC and am ready to dive in there, if that's what is required, but it would take a bit of research on my part because I've never used.

    Any thoughts would be appreciated.

    Michelle

    I see what you're saying. Note the Send button in the document message bar purple forms should appear for a form not distributed when you image previewed in form editing mode. It will appear not for users who fill out your form, or when you exit the form editing mode.

  • Create Simple expandable Menu Vertical

    I'm in the middle of an update on a project.
    I need to create a menu of extendable/retractable text.
    I have a picture of what I have a train to do here:
    http://www.isointeractive.com/temp/menu.gif

    So when you click on a category from the menu grows vertically and the other elements move down as well.

    The menus will be by eventrally driven by a database for heights will change.

    I was experamenting with layers, but the layers superimposed.

    So if anyone has examples of code from a text only extendable/retractable menu please let me know.

    Thanks for any help

    It works very well!

    Property worth $ 90

    I use the extension of the tree and it is quite simple to incorporate database menus!

  • How to create an equation average. If looking for a range of time?

    Let's get this out of the way: numbers 3.6.1 on a MacBook Pro of retina.

    I have run activities which start time randomly all day, at various periods of 15 minutes (10:00, 10:15, 10:30, etc.)  Every day have sessions starting at different times, according to needs.

    I would like to create a graph that follows the average size of the groups, based on the ranges of time, so I can see when we have the presence of best (and lowest).

    An example of development plan...

    I more or less understood how to make a choice when it comes to numbers, but not over time.  I'd appreciate any help that anyone could have.

    You could do something like this:

    The main in the second table B2, full formula down is:

    = AVERAGEIFS(Log::C,Log::D,">="&E2,Log::D,"<"&F2)

    The formula in column D of the table of the journal is:

    = TIMEVALUE (B)

    The formula in the second table E2, full of worms the down and right, is:

    = TIMEVALUE (C)

    I selected the columns A and B of the second table to insert a 2-d column chart.  (Column A is defined as a column heading.)

    Once the calculations work with headers italic columns can be hidden if desired.

    More on what TIMEVALUE can be found here.  AVERAGEIF is here.

    Use COUNTIFS if you want to calculate how many sessions you have had in a specific time block.

    SG

  • Create simple DVDs of several

    I have the DVD of my in-laws birthday, as well as each of their memorial services, each of the three events is on a separate DVD.

    All together, they come to less than 2 GB, so we want to copy the three files in one DVD for each of our sons, so that each would have a DVD with all three events on it.

    Each of the three DVD has the same file structure:
    VIDEO_TS\
    VIDEO_TS\VIDEO_TS. BUP
    VIDEO_TS\VIDEO_TS. IFO
    VIDEO_TS\VIDEO_TS. VOB
    VIDEO_TS\VTS_01_0.BUP
    VIDEO_TS\VTS_01_0.IFO
    VIDEO_TS\VTS_01_1.VOB
    VIDEO_TS\VTS_01_0.VOB

    I appreciate any help you can give me!

    Deina

    VOB files are video files.

    If you're running Vista Home Premium or Ultimate
    You may be able to import the VOB files in Windows
    DVD Maker just as they are. If they will matter not as
    VOB files... you might try to rename their. MSGM if this
    also fails, you will need to convert them to the. WMV
    format.

    See the following articles:

    Windows Vista - Windows DVD Maker - burn video disc
    http://Windows.Microsoft.com/en-us/Windows-Vista/burn-a-DVD-video-disc

    Windows Vista - Windows DVD Maker
    http://www.windowsvistauserguide.com/windows_dvd_maker.htm

    How to burn DVDs with Windows DVD Maker
    http://www.7tutorials.com/how-burn-DVDs-Windows-DVD-Maker

    (1) creating video DVD with Windows DVD Maker (part 1)
    http://allcomputers.us/Windows_7/creating-video-DVDs-with-Windows-DVD-Maker-(part-1).aspx

    (2) creating video DVD with Windows DVD Maker (part 2)-
    Add your photos and videos, and definition of the order of play
    (part-2)---Adding-Your-Pictures-and-Videos,-and-Setting-the-Play-Order.aspx http://allcomputers.us/Windows_7/creating-video-DVDs-with-Windows-DVD-Maker-

    (3) creating video DVD with Windows DVD Maker (part 3)-
    Set playback and DVD burning & DVD Menu Customization Options
    (part-3)---Setting-the-DVD-Burning-and-Playback-Options---Customizing-the-DVD-Menu.aspx http://allcomputers.us/Windows_7/creating-video-DVDs-with-Windows-DVD-Maker-

    (4) creation of video DVD with Windows DVD Maker (part 4)
    http://allcomputers.us/Windows_7/creating-video-DVDs-with-Windows-DVD-Maker-(part-4).aspx

  • Need help creating simple Gradient image sequence

    New to After Effects program. I am trying to create a radial gradient that I can export as jpg or png image sequence to use as a mask to run my animation in 3D Modo. I can hand paint that the sequence of images in Modo, but painting handmade 450 executives will make me lose my mind. I know there is a way to put 1 black frame of kew and 1 final frame of the large circle and have AE interpolate all inbetween then convert each frame to make the image sequence.

    tried searching and reading online, but couldn't find a clear tutorial. Any help is greatly appreciated.

    The photo is just a quick sketch to show what I'm after.

    THX

    brand1.png

    I thought that I have would illustrate method of Rick, but because I don't know what background you use I also illustrated the ways to use a collar of material or feathered masks to make the edges of a solid or gradient white transparent.

    A: this is what looks like a radial shape with a ramp layer.  The edges will be solid on a transperent background, but you can add Matt neck if you want to soften the edges.

    B: a solid white with a mask elliptical may simply be feathers so that edges are transperent.  Draw the circle with the elliptical mask tool all holding the shift to create a perfectly round circle.

    C: it's the same shape layer with a ramp radial as shown in the figure A only shown on a black background, a background.

    D: this is the same white solid as shown in image D only with edges to feathers on a black background.  An upside to do this way is that you don't have to animate the departure and arrival of the ramp if you decide to animate the position of the circle.

  • create simple xml...

    Hi dear flash community!

    I want to create an XML file dynamically in flash and store it on your hard drive.
    for example, it should look like this:

    <song>
     <title>titlename</title>
     <artist>artistname</artist>
    </song>

    first of all, I tried this code:

    var my_xml = new XML();
    
    var node = my_xml.createElement("song");
    my_xml.appendChild(node);
    
    node = my_xml.createElement("title");
    my_xml.firstChild.appendChild(node);
    
    node = my_xml.createTextNode("titlename");
    my_xml.firstChild.firstChild.firstChild.appendChild( node);
    
    node = my_xml.createElement("artist");
    my_xml.firstChild.appendChild(node);
    
    node = my_xml.createTextNode("artistname");
    my_xml.firstChild.firstChild.firstChild.appendChild( node);
    

    but then I get this:
    "the < title > song > < titlenameartistname < / title > < artist / > < / song >.
    of course, that is not correct.

    2)
    then I tried this one

    var my_xml = new XML("<song><title></title><artist></artist></song>");
    my_xml.firstChild.firstChild.firstChild.nodeValue = "TEXT";
    trace (my_xml);

    result of trace: <song><title /><artist /></song>

    so I try to change the nodeValue then to the 'TEXT', which is not possible.

    I would like to be able to define the overall structure (only the elements but no text inside the tags) and insert the text inside the tags (and add items) later dynamically.

    I hope someone can help me.
    welcome Peter

    Try:

    var my_xml = new XML();

    var node = my_xml.createElement ("song");
    my_xml. AppendChild (Node);

    node = my_xml.createElement ("title");
    my_xml.FirstChild.appendChild (Node);

    node = my_xml.createTextNode ("titlename");
    my_xml.FirstChild.FirstChild.appendChild (Node);

    node = my_xml.createElement ("artist").
    my_xml.FirstChild.appendChild (Node);

    node = my_xml.createTextNode ("artistname");
    my_xml.FirstChild.FirstChild.NextSibling.appendChild (Node);

  • create simple popup messages

    Hi all

    I searched this form and google, but can't find solutions (tutorials) complexes.

    I want only a window with the message that the order was successful, when the record hits.
    Preferably with a simple OK button on it.

    Thank you

    PIM

    Hello Pim,

    Ensure in the properties of the button SAVE, you choose URL and no page in the application and in the URL target - enter the following code:

    javascript:showAlert();
    

    It then calls the showAlert() function, you also added at the top of the page in the HTML header located under the heading 'Page' above 'Regions '.

    Sorry, instead of doSubmit("SUBMIT") - change that to doSubmit("SAVE") within the showAlert() function.

    Tony.

Maybe you are looking for

  • Satellite Pro A300 PSAJ1E: Touchpad not recognized using Win XP SP2

    Hi all I just got a Satellite Pro A300 PSAJ1E, which is preloaded with Vista. It is also comes with a 'product' XP SP2 recovery CD I had to use because of some software work with Vista compatibility issues. Unfortunately, everything works well except

  • 15 - f233wm: bios password

    I think my kid put a bios password, but he does not remember to do.  I get a black screen with a blue box asking me password administrator or power on password.  When I answer incorrectly 3 times, I get a message indicating the deactivation of the sy

  • Problem installing LAN USB adapter in a new copy of windows 2000

    After having reformatted my hard drive and install a new copy of window 2000, I'm having a problem installing device drivers.  When I enter the correct inf file path, it reports that this window has not found a driver for the device.  Whithout the po

  • I have a HP 3210 all in one photosmart printer.

    Changed the black cartridge as he was exhausted - new cartridge would not work properly came out in blue. Thought it was defective returned if she got one, same thing new, tried putting in a cartridge that I knew worked in my brother's computer - sam

  • How long blackBerry Smartphones to rom for BlackBerry 9900?

    Can you help me? I have test rom 9900 Rogers. One day I got up three times!