Quick button question

I have several buttons that were converted from images that were imported into flash. Some of them have very large areas that extend way beyond the button graphic. I've tried using the hit area, but it appears that it doesn't work if you make a hit area that is smaller than or within the size of the button (albeit mostly just blank space). Is there a way to either perform a crop function of sorts on these buttons or otherwise make the hit area smaller so the clickable area of these buttons aren't so huge.
As a note I know I could fix the image sizes in photoshop and import them again, but I would really prefer not to because I have many of them and I'm already quite a ways through the website I'm making and would hate to start over converting tons of buttons and checking all my as3 connections.
Thank you so much for any help. I've been stuck for ages!

As I said, it's not really clear (to me) what your problem is or what you are trying to do.  Your could try applyig a mask to the image as far as some form of cropping goes.  Alternatively you could make the image a movieclip and within that movieclip incorporate an invisible button that is sized to whatever dimensions you want, effectively making the hit area of the image whatever size you want.

Similar Messages

  • A quick button question (I think)

    Hi all, I have been asked by a client to create some online ads, and then send them off to the website who will be displaying them. My problem is that they have asked that I do the following...
    I should use the 'clickTAG' code below to trigger link:
    on (release) {
    if (clickTAG.substr(0,5) == "http:") {
    getURL(clickTAG, "_blank");
    Is this a simple case of creating an invisible button the same size as the advert and adding an action to it? Is that all they mean?
    Thanks.
    Mat

    Yes, that's pretty much it.  The actual clickTag value is speciied in the html embedding code (I believe)., which the person who's planting the ad will manage.

  • Hi all .hope all is well ..A quick trim question

    Hi all
    Hope all is well ......
    I have a quick trim question I want to remove part of a string and I am finding it difficult to achieve what I need
    I set the this.setTitle(); with this
    String TitleName = "Epod Order For:    " + dlg.ShortFileName() +"    " + "Read Only";
        dlg.ShortFileName();
        this.setTitle(TitleName);
        setFieldsEditable(false);
    [/code]
    Now I what to use a jbutton to remove the read only part of the string. This is what I have so far
    [code]
      void EditjButton_actionPerformed(ActionEvent e) {
        String trim = this.getTitle();
          int stn;
          if ((stn = trim.lastIndexOf(' ')) != -2)
            trim = trim.substring(stn);
        this.setTitle(trim);
    [/code]
    Please can some one show me or tell me what I need to do. I am at a lose                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            

    there's several solutions:
    // 1 :
    //you do it twice because there's a space between "read" and "only"
    int stn;
    if ((stn = trim.lastIndexOf(' ')) != -1){
        trim = trim.substring(0,stn);
    if ((stn = trim.lastIndexOf(' ')) != -1){
          trim = trim.substring(0,stn);
    //2 :
    //if the string to remove is always "Read Only":
    if ((stn = trim.toUpperCase().lastIndexOf("READ ONLY")) != -1){
       trim = trim.substring(0,stn);
    //3: use StringTokenizer:
    StringTokenizer st=new StringTokenizer(trim," ");
        String result="";
        int count=st.countTokens();
        for(int i=0;i<count-2;i++){
          result+=st.nextToken()+" ";
        trim=result.trim();//remove the last spaceyou may find other solutions too...
    perhaps solution 2 is better, because you can put it in a separate method and remove the string you want to...
    somthing like:
    public String removeEnd(String str, String toRemove){
      int n;
      String result=str;
      if ((n = str.toUpperCase().lastIndexOf(toRemove.toUpperCase())) != -1){
       result= str.substring(0,stn);
      return result;
    }i haven't tried this method , but it may work...

  • Quick script question

    Hi all,
    Could anyone advise me if i can add anything within - header('Location: http://www.mysite.co.uk/thankyou.html'); in the script below so as the page
    re- directs back to the main index page after a few seconds ?
    Thankyou for any help.
    <?php
    $to = '[email protected]';
    $subject = 'Feedback form results';
    // prepare the message body
    $message = '' . $_POST['Name'] . "\n";
    $message .= '' . $_POST['E-mail'] . "\n";
    $message .= '' . $_POST['Phone'] . "\n";
    $message .= '' . $_POST['Message'];
    // send the email
    mail($to, $subject, $message, null, '');
    header('Location: http://www.mysite.co.uk/thankyou.html');
    ?>

    andy7719 wrote:
    Mr powers gave me that script so im rather confused at this point in time
    I don't think I "gave" you that script. I might have corrected a problem with it, but I certainly didn't write the original script.
    What you're using is far from perfect, but to suggest it would lay you open to MySQL injection attacks is ludicrous. For you to be prone to MySQL injection, you would need to be entering the data into a MySQL database, not sending it by email.
    There is a malicious attack known as email header injection, which is a serious problem with many PHP email processing scripts. However, to be prone to email header injection, you would need to use the fourth argument of mail() to insert form data into the email headers. Since your fourth argument is null, that danger doesn't exist.
    One thing that might be worth doing is checking that the email address doesn't contain a lot of illegal characters, because that's a common feature of header injection attacks. This is how I would tidy up your script:
    <?php
    $suspect = '/Content-Type:|Bcc:|Cc:/i';
    // send the message only if the E-mail field looks clean
    if (preg_match($suspect, $_POST['E-mail'])) {
      header('Location: http://www.example.com/sorry.html');
      exit;
    } else {
      $to = '[email protected]';
      $subject = 'Feedback form results';
      // prepare the message body
      $message = 'Name: ' . $_POST['Name'] . "\n";
      $message .= 'E-mail: ' . $_POST['E-mail'] . "\n";
      $message .= 'Phone: ' . $_POST['Phone'] . "\n";
      $message .= 'Message: ' . $_POST['Message'];
      // send the email
      mail($to, $subject, $message);
      header('Location: http://www.example.com/thankyou.html');
      exit;
    ?>
    Create a new page called sorry.html, with a message along the lines of "Sorry, there was an error sending your message". Don't put anything about illegal attacks. Just be neutral.
    By the way, when posting questions here, don't use meaningless subject lines, such as "Quick script question". If you're posting here, it's almost certain to be a question about a script. It doesn't matter whether it's quick. Use the subject line to tell people what it's about.

  • Camera quick button doesnt appear on the lock screen but did when I first upgraded the new OS

    I upgraded to the new OS5 today and the camera quick button appeared on the lock screen when the upgrade was complete but has since disappeared. I have resynced the phone and still nothing. anyone else have the same problem? I have the iphone 3GS. Thanks!

    Thanks for the replies, I was having the same issue/ had the same question

  • Quick Buttons

    Hello,
    I always minimalise Itunes and I want to use quick buttons,
    I got on my keyboard a play button - forward button - backward button etc ...
    But I can only use them if I open Itunes to front of desktop, not when I minimalise it ...
    Is their anyway that I can fix it ? So I don't always have to open Itunes when I want to pause a song etc ?

    This thread was the one that worked for me.
    thirurajesh yea there is a way to fix the eject button if u want the simple way just intall the old mediasmart menu from this link ftp://ftp.hp.com/pub/softpaq/sp42001-42500/sp42238.exe when it installs open the mediasmart properties from the icon on the desktop and go to compatability and choos windows vista service pack 1 click ok and  then logoff and login again ill work fine. but if u want it to look like the new mediasmart menu
    1.u still have to install the old mediasmart menu
    2.open the task manager and close the mediasmart menu from (processes)
    3.extract these files http://h.imagehost.org/download/0402/HP_MediaSmart in c:/program files/hewlett-packard/hp mediamsart and if it asks to replace just say yes
    4.restart
    there u go now u got the eject button to work with the new mediasmart menu
    D-a-n_L

  • GT70 Dominator Dragon, Problems with Quick buttons ( Help)

    Hi  my friends, first  sorry my engliash its really bad.
    Have  a little problem with  the quick buttons of my  GT70 Dominator Dragon. Have  a  moth  with the Pc and I really love it, all work fine but when I update the Pc some  quick buttoms stop working.
    where  can find the new drivers? of how I can  fix this??
    Here a  photo with the  problems
    Ty all and sorry again

    EC reset only needs once, just by removing the battery and the AC adapter and wait for few minutes then plug the AC adapter back on and restart the system.
    If you have pre-installed Win8.1, then the first video button should have Power DVD 10 running after pressing. (Only if you don't have the Power DVD software, then it'll show the windows media player.)
    G buttons will only work if you have the application installed.
    Display off button, G button and the video play buttons will need the right EC firmware and the SCM drivers (plus the right application installed)
    Check if you have the latest EC firmware in BIOS menu. (Press Delete button after MSI logo shows up during the bootup to enter the BIOS menu> Main> System Information> EC version)
    Full color backlight keyboard (516) *check your current version and make sure after update, the version name is also starts with the same number 5XX.
    http://dl.msi.com/download_files/frm_exe/1763EMS1.516.zip

  • Is there any quick buttons setup for going back or forward

    Is there any quick buttons setup for going back or forward for navigating on a website. I would like to press a button to go back or forward while surfing different websites.

    Do you mean the back and forward history of a tab or buttons on a web page to go to the next and previous page?
    * [[Keyboard shortcuts]]
    * [[Mouse shortcuts]]
    *NextPlease!: https://addons.mozilla.org/firefox/addon/390
    There are other things that need attention:
    Your above posted system details show outdated plugin(s) with known security and stability risks that you should update.
    # Shockwave Flash 10.0 r45
    # Next Generation Java Plug-in 1.6.0_14 for Mozilla browsers
    Update the [[Managing the Flash plugin|Flash]] plugin to the latest version.
    *http://www.adobe.com/software/flash/about/
    Update the [[Java]] plugin to the latest version.
    *http://www.oracle.com/technetwork/java/javase/downloads/index.html (Java Platform: Download JRE)

  • Quick NativeWindow questions.

    Hi,
    Two Quick Questions about native window actions (I am using AIR with HTML and JS):
    1. How do you "refer" to minimize button ? - So, when a user clicks minimize, it should do an action defined in javascript.
    2. How to define click event for System tray icon ? - So I can display something when my system tray icon is double-clicked.
    Thanks.

    1. Add an event listener to the window.nativeWindow object, listening for the NativeWindowDisplayStateEvent.DISPLAY_STATE_CHANGING  or DISPLAY_STATE_CHANGE events.
    2. Add an event listener to your SystemTrayIcon object. You can listen for click, mouseUp or mouseDown events, but doubleClick events are not dispatched by this object.

  • Quick naming question

    Wasnt sure if its a naming issue or not but Ive never ran into the problem and Im not sure how to describe it....so here goes.
    Question: Is there a way to insert a string into the name of a component name and have java see it as the actual component name. (see that question still sounds incorrect)
    What I mean is......
    you have 10 buttons named oneB, twoB, threeB,......tenB
    I need to either change a whole lot of code and make what I want to be simple, very large and complex or, find a way to....
    "one"B.setLocation(whereverNotImportant);
    or
    (someObject.getString( ) ) + B.setLocation(whereverNotImportant);
    It looks really odd to me. If theres a way to do it, it just saved me a lot of annoyance.....if not well, Im gonna need more energy drinks.

    Paul5000 wrote:
    Fair enough. I kept adding features onto the code and it grew into needing something different. Was just hoping there was a quick workaround so I didnt have to go back and recode half of it.When you've got Franken-code, the answer is to recode it.

  • My Home Button question.

    I just got my Touch yesterday (a great bit of kit!) and it seems that sometimes when I press the Home button it goes back into the main (Home) menu quicker than others, sometimes I have to press the button 2 or 3 times before it goes back to the main menu.
    I'm only pressing the button gently, am I supposed to hold it down for a few seconds for it to work properly?
    I did a search and found similar posts but nothing that really answered this question.
    Thanks for your help.

    Thanks for the info guys. I am pressing the button a bit harder and even though it still sometimes takes 3 or 4 presses it still goes back home, just me being a bit paranoid with the new toy I suppose! At the end of the day it works perfectly and does what it says on the box.
    Thanks for the replies.

  • Urgent help with quick translation questions

    Hello,
    I am somewhat new to Java. I have a translation to hand in in a few hours (French to English). Argh! I have questions on how I worded some parts of the translation (and also if I understood it right). Could you, great developers, please take a look and see if what I wrote makes sense? I've put *** around the words I wasn't sure about. If it sounds strange or is just plain wrong, please let know. I also separated two terms with a slash, when I was in doubt of which one was the best.
    Many thanks in advance.
    1) Tips- Always ***derive*** the exceptions java.lang.Exception and java.lang.RuntimeException.
    Since these exceptions have an excessively broad meaning, ***the calling layers will not know how to
    distinguish the message sent from the other exceptions that may also be passed to them.***
    2) The use of the finally block does not require a catch block. Therefore, exceptions may be passed back to the
    calling layers, while effectively freeing resources ***attributed*** locally
    3) TIPS- Declare the order for SQL ***statements/elements*** in the constant declaration section (private static final).
    Although this recommendation slightly hinders reading, it can have a significant impact on performance. In fact, since
    the layers of access to data are ***low level access***, their optimization may be readily felt from the user’s
    perspective.
    4) Use “inlining.”
    Inlining is a technique used by the Java compiler. Whenever possible, during compilation, the compiler
    copies the body of a method in place of its call, rather than executing a ***memory jump to the method***.
    In the example below, the "inline" code will run twice as fast as the ***method call***
    5)tips - ***Reset the references to large objects such as arrays to null.***
    Null in Java represents a reference which has not been ***set/established.*** After using a variable with a
    large size, it must be ***reassigned a null value.*** This allows the garbage collector to quickly ***recycle the
    memory allocated*** for the variable
    6) TIPS Limit the indexed access to arrays.
    Access to an array element is costly in terms of performance because it is necessary to invoke a verification
    that ***the index was not exceeded.***
    7) tips- Avoid the use of the “Double-Checked Locking” mechanism.
    This code does not always work in a multi-threaded environment. The run-time behavior ***even depends on
    compilers.*** Thus, use the following ***singleton implementation:***
    8) Presumably, this implementation is less efficient than the previous one, since it seems to perform ***a prior
    initialization (as opposed to an initialization on demand)***. In fact, at runtime, the initialization block of a
    (static) class is called when the keyword MonSingleton appears, whether there is a call to getInstance() or
    not. However, since ***this is a singleton***, any occurrence of the keyword will be immediately followed by a
    call to getInstance(). ***Prior or on demand initializations*** are therefore equivalent.
    If, however, a more complex initialization must take place during the actual call to getInstance, ***a standard
    synchronization mechanism may be implemented, subsequently:***
    9) Use the min and max values defined in the java.lang package classes that encapsulate the
    primitive numeric types.
    To compare an attribute or variable of primitive type integer or real (byte, short, int, long, float or double) to
    ***an extreme value of this type***, use the predefined constants and not the values themselves.
    Vera

    1) Tips- Always ***derive*** the exceptions java.lang.Exception and java.lang.RuntimeException.***inherit from***
    ***the calling layers will not know how to
    distinguish the message sent from the other exceptions that may also be passed to them.***That's OK.
    while effectively freeing resources ***attributed*** locally***allocated*** locally.
    3) TIPS- Declare the order for SQL ***statements/elements*** in the constant declaration section (private static final).***statements***, but go back to the author. There is no such thing as a 'constant declaration section' in Java.
    Although this recommendation slightly hinders reading, it can have a significant impact on performance. In fact, since
    the layers of access to data are ***low level access***, their optimization may be readily felt from the user’s
    perspective.Again refer to the author. This isn't true. It will make hardly any difference to the performance. It is more important from a style perspective.
    4) Use “inlining.”
    Inlining is a technique used by the Java compiler. Whenever possible, during compilation, the compiler
    copies the body of a method in place of its call, rather than executing a ***memory jump to the method***.
    In the example below, the "inline" code will run twice as fast as the ***method call***Refer to the author. This entire paragraph is completely untrue. There is no such thing as 'inlining' in Java, or rather there is no way to obey the instruction given to 'use it'. The compiler will or won't inline of its own accord, nothing you can do about it.
    5)tips - ***Reset the references to large objects such as arrays to null.***Correct, but refer to the author. This is generally considered bad practice, not good.
    Null in Java represents a reference which has not been ***set/established.******Initialized***
    After using a variable with a
    large size, it must be ***reassigned a null value.*** This allows the garbage collector to quickly ***recycle the
    memory allocated*** for the variableAgain refer author. Correct scoping of variables is a much better solution than this.
    ***the index was not exceeded.******the index was not out of range***
    The run-time behavior ***even depends on compilers.***Probably a correct translation but the statement is incorrect. Refer to the author. It does not depend on the compiler. It depends on the version of the JVM specification that is being adhered to by the implementation.
    Thus, use the following ***singleton implementation:***Correct.
    it seems to perform ***a prior initialization (as opposed to an initialization on demand)***.I would change 'prior' to 'automatic pre-'.
    ***this is a singleton***That's OK.
    ***Prior or on demand initializations***Change 'prior' to 'automatic'.
    ***a standard
    synchronization mechanism may be implemented, subsequently:***I think this is nonsense. I would need to see the entire paragraph.
    ***an extreme value of this type******this type's minimum or maximum values***
    I would say your author is more in need of a technical reviewer than a translator at this stage. There are far too serious technical errors in this short sample for comfort. The text isn't publishable as is.

  • Updateable Report : re-display collection & Update Button question

    This a sequel to a previous Updateable Report question I had.
    Varad pointed me to this doc which has been incredibly helpful .
    http://www.oracle.com/technology/products/database/application_express/
    howtos/tabular_form.html#RESTRICTIONS
    I was\am having the following issue :
    Let's zoom to the part where we create a region to display the tabular form for the previously saved collection , and drill down to the part where we create an UPDATE EMP button for that displayed collection :
    I was not able to display the collection again when I failed the validation a 2nd time. ie, clicking on the UPDATE EMP button after it displays both the errors-post validation and after displaying the collection ( of course) would return me to the previous report pre-collection creation. When I turned debug on I found out that it was not even creating the collection and was hence deleting it before displaying the subsequent page.
    So what I did differently from what the documention instructs is as follows :
    I removed the page reference on the 'branch to page' of the UPDATE EMP button. In my case, the default 'Branch to ' Page after Processing is the same page I am using for this part of the application.
    So when I remove the reference to the page number. for that button, the page is then able to re-create the collection and hence re-display the collection so I can re-fix the 2nd error ( ... and 3rd) and finally update the report .
    Just wondering if anyone else has had the same experience ?
    Thanks !

    The columns and rows have a set format for the Id, so if you know one Id you know the row and the ids of all the other columns.
    As an example, this will show the value of column 6 when you click on any column with the function call in the Element Attributes:
    Script:
    <script type="text/javascript">
    function showCol6(col){
      var col6 = document.getElementById("f06_" + col.id.substr(4,4));
      alert(col6.value);
    </script>Element Attributes:
    onclick=showCol6(this);You could also use a Named Column template, specific to this region, to include the column values directly in the function call, but I think it's best to stick with the ApEx defaults if possible.

  • Quick REGEXP_LIKE Question

    Hi everyone,
    Had a very quick question: so I need to retrieve all records that have values in this format "type:123;target_id:456". Note that the numeric value can be 1-6 digits long for either type or target_id.
    Can someone please help me with the regexp_like-ing this?
    Thank you,
    Edited by: vi2167 on May 27, 2009 2:06 PM
    Edited by: vi2167 on May 27, 2009 2:07 PM

    WHERE REGEXP_LIKE(val,'type:\d{1,6};target_id:\d{1,6}')SY.

  • Quick export question (i hope) for Reader

    I'm using the following button created in livecycle:
    form1.Submit::click - (JavaScript, client)
    xfa.host.exportData("",0);
    In Acrobat Pro, I get a prompt to save the file as .xml (desired behavior)
    I have enabled the form with "extend features in adobe reader" using Pro and have the 'save as' menu item available in Reader, so I know that is working.
    However, when the export button is clicked in Reader, it flickers and does nothing.
    Any ideas on this one?
    Thanks!

    Thank you very much for your answer.  I'm not sure I understand, or maybe my question wasn't clear.. I'm developing a form in LiveCycle but I've used the extensions in Acrobat Pro to enable it for Reader.
    If these are available to turn on in LiveCycle, can you point me to some documentation on how to turn it on, or describe where these features are located?  I've combed through much of the documentation / help and haven't seen anything on this.
    Thanks for your help..

Maybe you are looking for

  • Why can't I access the Google site? None of the suggested remedies worked.

    I signed in to my Google calendar account and got an error message saying there was a problem with my cookies and I should clear my cache. If that didn't fix the problem, I should disable cookies. I followed these instructions and the problem was not

  • MaxL shell: show only db name from display database command

    Hello at all. I launch from MaxL command line shell the command: display database It response with some field but i need only the application and database field. Is possible ? How ? Thanks. Alessandro Edited by: Alessandro Celli on Mar 31, 2011 2:50

  • I want individual purchase order process?

    i mention below is right or wrong, can anybody please explain? OR--->ME58----->MIGO---->VL01N---->VF01----->MIRGO above process is right or wrong can you please explain.

  • Saving values in parameters while Navigation

    Hi, Can I save the value of the dimensions in some parameter while navigation. Means If I click on some value in a table which has navigation enabled, I want to store corresponding dimensions values in some parameters. How can we achieve the above re

  • Addon Installation Error on 2008 Server (64Bit)

    I have installed an Add-On of our development on various PCs' without any problem. However on a specific server during the installation process we get an error: "Error: An attempt was made to load a program with an incorrect format (Exception from HR