Creating a clickable scale button

Hi all,
I am creating a survey in flash to survey people's opinion about the temperature in a building. What I am hoping to do is have a scale which the surveyee can click on (see attached image) with 5 options from Too warm, warm, just right, cool, and too cold, and record where on the scale they click.
For example, if "Just Right" were correlated to an answer of 3 and "Warm" was correlated to an answer of 2, and a user were to click halfway between the two, I would want the recorded value to be 2.5. If they click closer to "Just Right" I want the recoded answer to be 2.8, etc.
It seems that the quick and dirty way I can think of doing this is to create a serious of invisible buttons over my scale which can then tell me where they click, but then I am limited in the granularity of the answer and it would just be a pain to create that many buttons.
Any ideas of more elegant ways of programing this?
Thanks!

You can probably just read the scale.mousePosition value to get an accurate translation of where someone clicked on the scale.

Similar Messages

  • ADF & JSF : how can I create a clickable  image

    Hi,
    How can I create a clickable object with an image property and have an action, I want to use it instead of a command button.
    thanks,
    Ahmad Esbita

    Hi Ahmad
    One way is to drop an objectImage tag inside a commandLink tag without a text attribute as follows:
    <af:commandLink actionListener="#{backingBean.someMethod}">
      <af:objectImage source="/someimage.gif"/>
    </af:commandLink>The image is clickable raising the actionListener event.
    Hope this helps.
    Regards,
    CM.

  • How to create an grid of buttons.

    Im trying to create a grid of buttons but for some reason i can see only 2 of them at the same time, but i know they are 9 on stage cause i trace numChildren
    Currently i have this:
    public class Main extends MovieClip
                        private var myBtn:SimpleButton = new SimpleButton();
                        private var img1:Bitmap=new Bitmap(new active_MouseOut());
                        private var img2:Bitmap=new Bitmap(new active_MouseOver());
                        private var img3:Bitmap=new Bitmap(new notActive_MouseOut());
                        private var img4:Bitmap=new Bitmap(new notActive_MouseOver());
                        private var myArrayContainer:Array = new Array();
                        public function Main()
                                  for (var i :int = 0; i < 3; i++)
                                            for (var j:int = 0; j < 3; j++)
                                                      myArrayContainer[j] = new MyButton(img1, img2, img3, img4)
                                                      myArrayContainer[j].x = 0 + i * (myArrayContainer[j].width + 10)
                                                      myArrayContainer[j].y = 0 + j * (myArrayContainer[j].height + 10)
                                                      this.addChild(myArrayContainer[j])
                                  trace(numChildren)
    active_MouseOut, active_MouseOver, notActive_MouseOut and notActive_MouseOver are simple bitmap Images that have AS linkage
    And MyButton class is this
    package
              import flash.display.Bitmap;
              import flash.display.MovieClip;
              import flash.display.SimpleButton;
              import flash.events.MouseEvent;
              import flash.utils.getDefinitionByName;
              public class MyButton extends MovieClip
                        private var myBtn:SimpleButton = new SimpleButton();
                        private var image1:Bitmap
                        private var image2:Bitmap
                        private var image3:Bitmap
                        private var image4:Bitmap
                        public function MyButton(active_OutState:Bitmap, active_OverState:Bitmap, notActive_OutState:Bitmap, notActive_OverState:Bitmap)
                                  image1 = active_OutState;
                                  image2 = active_OverState;
                                  image3 = notActive_OutState;
                                  image4 = notActive_OverState
                                  myBtn.upState = image1;
                                  myBtn.overState = image2;
                                  myBtn.downState = myBtn.upState;
                                  myBtn.hitTestState = myBtn.overState;
                                  addChild( myBtn );
                                  myBtn.addEventListener(MouseEvent.CLICK, onClick);
                        private function onClick( ev:MouseEvent ):void
                                  myBtn.upState = image3;
                                  myBtn.overState = image4;
    I also want to ask : Can I get the bitmapData to load in the MyButton class with this
    private var image1:Bitmap
    public function MyButton(mouseState:String)
                                   image1_Data = Class(getDefinitionByName( mouseState ));
                                  image1 = new Bitmap( image1_Data() )
    and in the Main Class to send the name of the image in the library
    myArrayContainer[j] = new MyButton( "notActive_MouseOver" )
    or I can do this only in/from the Document Class
    cause Im trying and it is giving me this
    Error #1065: Variable notActive_MouseOver() is not defined.

    well Im doing the button-making in the MyButton class cause im trying to create 9 buttons(and every button has a different image and that image has 4 states(clickable-Up, clickable-Over, notClickable-Up, notClickable-Over  )).
    And this is the only way i figured out how to do it without writing alot of code ()

  • Is there a way to create a log-in button with a password protected section of a site?

    I have a client that needs a log-in section and a way to create a customer account. Is there a widget or workaround that allows me to create a log-in button and create a customer account where they specify a username and password? Muse is terrific for simple sites, but without having access to the code, I can't operate the way I used to. When I'd need custom work done like this, I'd hire a programmer to create the code, then simply paste it into the code of the site. I can't do this with Muse and it's a huge barrier. Anyone have any ideas or solutions? Please call me directly if you have a solution: 727-466-6888 (Florida).

    You can fairly easy do it with Business Catalyst hosting's webMarketing plan. With a little Business Catalyst knowledge it can be achieved quite easily.
    Other than that you would need to create your login forms and secure pages outside of your site and then add the login form and secure content to the site with iFrames. A more tedious and not ideal way of doing it.

  • How can I set a value in a field before create when a New button is clicked

    Hi,
    I am using
    JDeveloper 10.1.3.1.0.3984 and
    JHeadstart 10.1.3.1 release 10.1.3.1.26
    I have one group and there is a detail group under that group.
    From main group to detail group there are 3 field relating those groups.
    field1
    field2
    fieldSEQ (auto-generated by database trigger)
    These 3 fields are PK.
    In the detail group, there is a New button. So, when the New button is clicked, it tries to create the record with those 3 fields value as those are coming from main group. As a result it's giving the duplicate error as that record already exists in the table.
    But I don't want to create the record with that SEQ as that will be created in the trigger.
    How can I set the SEQ temporarily any no. (-1) before create when the New button is clicked?
    Can anybody help?
    Thanks
    Syed Jabbar
    University of Windsor
    Windsor, ON, Canada

    Hello Syad,
    What I would suggest is setting the sequence number at the creation of the entity object (so in the create() method) by using the database sequence. This way it will always be unique.
    So something like:
    protected void create(AttributeList AttributeList) {
    super.create(AttributeList);
    SequenceImpl sequence =
    new SequenceImpl("KCP_SEQ", getDBTransaction());
    setFieldSeq( sequence.getSequenceNumber());
    If this still does not solve it: please go to the ADF Forum since this problem is an ADF problem, not a JHeadstart problem.
    Regards,
    Evert-Jan de Bruin
    JHeadstart Team.

  • How to create subpicture for a button?

    Hello!
    I have really tried to find the answer to this rather silly problem on my own, but without result. Please help someone!
    The situation:
    I have a menu with three choices: "Play Movie", "Scene Selection" and "Subtitles". Now, the text presenting these choices are part of the background image, created in Premiere (the program I know best). They are written with an old typewriter to get that gritty feeling.
    I want the user to scroll between these "menu items". The currently selected item should be indicated by a black circle/spot/dot before the text of the item. By default, when the menu appears, there is a black circle in front of (to the immediate left of) the item "Play Movie". The user should now be able to step with his/her remote to the other items, thereby making the black circle in front of "Play Movie" disappear and appearing instead before some of the other items. In short: the black circle is always showing before the currently selected item. OK, I got a bit verbose there, but the idea got across hopefully. One more thing: the background color is 100% white.
    Up to this point, my solution was this: I placed black circles (small images with gradation and all, very nice looking) in front of ALL THREE ITEMS. Then I convert these into buttons. Then I choose the color set for the menu so that the unselected state is 100% white, plain and simple, with 100% opacity, thereby covering the black circles that should not show. Only in the selected and activated states does opacity for the button subpicture drop to 0%, thereby revealing the black circle that should be seen.
    The problem? Well, on some DVD-players (not on the XBOX 360 though), when an item is activated, all three circles show for a brief moment before the selected action starts (for example playing the movie). It also happens in Encore Preview. This is not logical at all and looks amateurish. I don't know why it happens, but my guess is that it wouldn't if I did this the "correct" way: by creating subpictures fo the buttons in the shape of circles. I understand the nice looking gradations must go out the window but that is a price I'm willing to pay.
    But now I run into an unexpected problem: I don't understand how to create a subpicture for the button that is a black circle. It seems the documentation in Encore and on forums in general takes for granted that you know how to do this.
    What I tried ws this: I created a monochrome, small image in bmp format - a black circle on white background. But this image just shows up as a black rectangle in Encore.
    What should I do? I should add that I have no real experience with Photoshop, so go slow if you go there.
    Regards,
    Nikolaj

    Basically, when one realizes the limitations of the Sub-picture Highlights, as set by the DVD-specs., it's easy to see the "workaround."
    A couple of the aspects of Sub-picture Highlights are:
    1.) 2-bit color (either ON, or OFF), from a limited color palette, with degrees of Transparency (the opposite of PS's Opacity).
    2.) they will appear on top of anything else on the Menu, including things like Button text/graphics.
    By constructing your Sub-picture Highlight in PS, you can use Masking to define where it will be, and where it will not be. In the case that prompted my article, the poster had a series of Text Buttons, and the Sub-picture Highlights were formed from that Text. The poster did not like the look of those 2-bit jagged blocks of color overlying the Text in the Button. The workaround is to "punch a hole" in the Sub-picture Highlight, so that it is hollow, where the Button's Text appears. This is done in PS, by using the "outline" of that Text to create a Mask for the Sub-picture Highlight. The jagged aspect can be adjusted a bit, by using a degree of Transparency (set in the non-Auto Color Set back in Encore). We still have a 2-bit color Sub-picture Highlight, and it still overlays the Button's Text, but now there is a hole in it, right where the Button's Text is located, and it is seen through that hole. The introduction of Transparency has the visual effect of "softening" the look of the 2-bit color, even though the jagged edges are still there - they just look softer. I went on to show how one could even use a second Sub-picture Highlight, that is just a bit larger than the first, and with more Transparency to simulate a "glow." Now, we cannot have a real "glow," because we are limited to that 2-bit color for the Sub-picture Highlight, but we can simulate it.
    Much of what a designer does is really slight of hand - illusion. They all have to work within the limitations of the DVD (or BD) specs., but with a bit of creativity, planning and some work in PS and Encore, they can create enough smoke and use enough mirrors to fool the user into believing that what they think they see skirt the DVD-specs. They do not, but that's where the illusion comes in.
    We get a lot of questions from people, who claim that one commercial DVD, or another, has full-color Sub-picture Highlights and they complain that Encore cannot do that - only 2-bit Sub-picture Highlights. What they are seeing, but do not realize it, is a dupe Menu, with a full-color graphic, and no real Sub-picture Highlight visible. Jeff gives full details on doing this. Same for those who have seen a Button with a duo-tone thumbnail, that turns full-color, when the Button is navigated to. Wow, how did they do that, and why can't Adobe Encore do that? Well, what they saw was a dupe Menu, with a full-color thumbnail and no visible real Sub-picture Highlight.
    Jeff shows how to create what appears to be at least a 3-color Sub-picture Highlight. It's really just 3 regular 2-bit color Sub-picture Highlights, with Masking to create the illusion that he beat the DVD-specs. Neat! [Being from the USA, I also liked that he used the US flag, but he could have chosen the French "Tri-color," or any other flag, without artwork.]
    These are all just tricks, but if the user buys into the illusion, who's to know?
    Enjoy,
    Hunt
    PS - though many of the great, older posts were lost, when the forum changeover happened, I strongly suggest reading the posts here. You can bypass ones that do not offer you anything, but almost every possible illusion has been discussed at least one time, and likely many, with some different workflows offered by those, who replied. Great reading.

  • How to create a clickable hyperlink in iCloud Numbers?

    How to create a clickable hyperlink in iCloud Numbers?

    There is no such thing. All you could do is create an HTML e-mail, but many users won't even view it in that mode for security reasons and it may get filtered. Similarly, Flash-based content may get removed/ not show up. So at best, if you really want to get a clickable document, you could use a PDF file containing a link. but did i mention that the user can suppress those, too? Well, sorry, but you are SOL. You want something that for a million reasons nobodyy can give you. The best you can do, as always, is host your content on a proper website and send peopel a link to it...
    Mylenium

  • Help to create a Lucky Dip button, please?

    have developed a Football Pools competition to raise funds
    for various Good Causes and found a programmer to create the
    attached Flash file. Unfortunately he was involved in a serious car
    crash and will be hospitalised for many weeks.
    I apologise in advance - this may be a very inappropriate
    request ... I am not a programmer, just trying to find someone to
    help
    The last 2 parts he was undertaking were to
    1. create a "Lucky Dip" button that filled in randomly each
    of the required 15 choices .... to make life easy for non-fans, a
    button to press for a Lucky Dip selection BUT with the option to
    still change any individual choice they did not like
    2. Create a pop-up "warning" if anyone tried to submit an
    incomplete "entry" - forecasts are required for ALL 15 matches.
    I would be happy to pay a reasonable fee if this is again,
    not breeching etiquette.
    Thanks in advance for any help which will be much
    appreciated.
    My main email is [email protected]
    LINKS to files:
    SoccerBingo
    SWF
    fla file
    flp
    file

    have developed a Football Pools competition to raise funds
    for various Good Causes and found a programmer to create the
    attached Flash file. Unfortunately he was involved in a serious car
    crash and will be hospitalised for many weeks.
    I apologise in advance - this may be a very inappropriate
    request ... I am not a programmer, just trying to find someone to
    help
    The last 2 parts he was undertaking were to
    1. create a "Lucky Dip" button that filled in randomly each
    of the required 15 choices .... to make life easy for non-fans, a
    button to press for a Lucky Dip selection BUT with the option to
    still change any individual choice they did not like
    2. Create a pop-up "warning" if anyone tried to submit an
    incomplete "entry" - forecasts are required for ALL 15 matches.
    I would be happy to pay a reasonable fee if this is again,
    not breeching etiquette.
    Thanks in advance for any help which will be much
    appreciated.
    My main email is [email protected]
    LINKS to files:
    SoccerBingo
    SWF
    fla file
    flp
    file

  • How can i create the blue "I"-Button for the Documentation in a view

    How can i create the blue "I"-Button for the documentation in a view?
    I want to prepare the button with user specified Information...
    and where must be create the documentation?
    thanks
    Edited by: DDC-TD on Apr 24, 2008 10:22 PM

    you have not mentioned where do u want the " I " information button ,
    1. If u want for a report , u can get the information button on selection-screen only .
       if u goto se38 on the mail screen u will find a radio button for documentaion ,
    when u select it and click 'create' or 'change' , an editor will open and u can document anything there ....
    2. Or specify where u want  info button .
    thanks ,
    reward points if usefull.

  • How to create a 3-state button (similar look as OK button) that toggles between 3 different colors.

    How do I create a 3-state button that looks similar to the OK button except it changes to 3 different colors every time it is pressed. Does anyone have such a control ready for use that I can just drop in my front panel?

    With a picture ring you can implement a 3 color button without any code. Look at the attached customized control.
    I have imported the picture of a boolean in three different items and
    colored them. I centered the text and hide/made transparent uneeded
    graphic elements. I set the size of the decrement arrow to cover all
    the picture and made it transparent so when you click on the control
    you decrement the value of the ring and change the picture/color
    Edit: you'll notice that the picture is not fullt covered by the
    decrement arrow so if you click near the bottom of the button, the
    picture ring will show its normal behavior displaying all 3 available
    items
    Message Edité par Jean-Pierre Drolet le 07-07-2005 10:07 PM
    LabVIEW, C'est LabVIEW
    Attachments:
    3COLORSBUTTON.vi ‏8 KB

  • How to create an "exit widget" button on iAd producer.

    I am creating a widget for a children's book and would like to create a simple "exit button" (an X the reader can touch to close the widget). Thus far I have created the object, but i can't seem to find an an 'action' to associate with the "activated" event that will close the widget and return to the iBook. I realise that a widget can alternatively be closed with a two-finger gesture, but for simplicity in view of my target audience prefer to have the "exit button". Note: I am relatively new to iBooks Author, and totally new to iAd producer. Unfortunately I don't know how to script in Java or HTML yet, but am willing to learn. Can anyone please give me some pointers?

    Thanks! The button didn't appear in the preview in iAd producer, so I didn't realize it was there. But I tried my widget in iBooks Author and the button is there. Thanks again!

  • How to create DVT Clickable Piechart in ADF Mobile framework

    Hi All,
    I am working on ADF Mobile app which displays piechart component on the mobile UI screen. I want to have clickable piechart which the user will click to navigate to next page to show more details of the pie clicked/touched.
    I have looked into this doc link below but there is no info on how to create a clickable pie chart.
    http://docs.oracle.com/cd/E37975_01/doc.111240/e24475/amxui.htm#ADFMF670
    Is there any documentation on how to do that?
    Thanks.
    -Nirav
    Edited by: Shah23 on May 29, 2013 11:10 AM

    Hi Nirav,
    There is an action attribute on the dvtm:pieDataItem tag where you can specify which action to take when the user touches the pie slice.
    Hope this helps
    Katia

  • How to create a new push button in application tool bar in GMGRANT thru BDT

    Dear SAP Gurus -
    We have a requirement in 'GMGRANT' transaction. We need to create a button in the application tool bar of 'GMGRANT' transaction. Once the button is activated, if the user clicks on the button then it will go to a new screen (external screen). User can input data in to the external sceeen and upon saving, the data will be stored in to a custom table and when user clicks on 'back ' button user should come back to the GMGRANT transaction.
    Just wanted to know, how to create / activate a new button on application tool bar of GMGRANT transaction and what are the configuration and detail steps to achieve the same through BDT.
    We went through a lot of documents on BDT but do not have a proper solution.
    Could you please help.
    Thanks in advance.
    Regards,
    Atul Mohanty

    hi,
    You can find user-exits (menu exits) to add new menu item.
    But, there is no possibility to add new buttons on application tool bar.
    Regards,
    Sailaja.

  • How to create dropdown box, radio button,check box in wad

    Hi,
    How to create dropdown box, radio button,check box in wad.
    Thanks,
    cheta.

    Cheta,
    This are all standard Web Items in the WAD. Drag them onto your template and then make the changes you need to them in their Properties.
    Regards
    Gill

  • Create Run And Stop Buttons on Front Panel, rather than using the toolbar run/stop

    I would like to make my vi more user friendly by creating start and stop buttons on the front panel. I havent found much info on how to create them. I have created a boolean stop button to stop my FOR LOOP.
    -Chris

    Creating the buttons is easy - just select the style you want from the Boolean palette. What you need to do is change your diagram and the VI properties. To have a VI automatically start running when opened, open VI Properties by selecting that under the File menu or right clicking the VI's icon. Select Execution and check the Run when opened box. If you need the user to enter some data or change parameters before running the program, there's a couple of ways to go about it with a front panel Start button. You could have a separate while loop with just the start button in it and connect an output of that to a main while loop. This creates data flow and ensures that the start while loop executes before the main. You could create a simple state machine. T
    here's a couple of shipping examples. Just open the Example Finder and enter state for the keyword. You could also use the Event structure. Again, there are several shipping examples. Instead of doing a search, you could also browse the Example Finder and look at what's underneath the Building User Interfaces topic.
    p.s. I don't think you created a stop button for a for loop as there is no way to stop a for loop. What you can stop is a while loop.

Maybe you are looking for