Remove alert clickHandler

I have a form(MovieClip) that I popup where a user can update
their info.
Each time the profile is updated I popup an Alert saying
"Profile Updated". It's adding a new listener for each time I
update the profile. 2nd time I call it I get 2 Alerts, 3rd time 3
etc.
How do I remove these after they have been triggered? I'm
removing several others, but do not know and can't find the syntax
to remove these.

Maybe you mean this:
<?xml version="1.0" encoding="utf-8"?>
<s:Application  xmlns:fx="http://ns.adobe.com/mxml/2009"
       xmlns:s="library://ns.adobe.com/flex/spark"
       xmlns:mx="library://ns.adobe.com/flex/mx"
       creationComplete="init();">
<fx:Script>
  <![CDATA[
    public function init():void {
    addEventListener("cEvent", cEventHandler);
   private function cEventHandler (e:Event):void {
     removeEventListener("cEvent",cEventHandler);
     mx.controls.Alert.show("cEvent handled and removed");
   private function  clickHandler(e:Event):void {
    dispatchEvent(new Event("cEvent"));
  ]]>
</fx:Script>
<s:Button lable="click"  click="clickHandler(e)"/>
</s:Application>

Similar Messages

  • Bogus "Device Removal" Alert for SDcard Reader

    Using the same SDcards, same reader, same USB hub as I did before the 10.5.8 update, I now get a "Device Removal" alert after a period of time once an SDcard is inserted. It varies from just a minute or two to around an hour or more. When I click off the alert window the card remounts right away but the alert always comes back after a while.
    Something tells me a PRAM zap might fix it, but is anyone else seeing this with 10.5.8?

    More Info: After resetting PRAM and a reboot, still the same symptoms except this time, after the "Device Removal" message came up. the lights on the reader flashed for a while and then the following alert window appeared: "Disk Repair The disk "NO NAME" was not repairable by this computer. It is being made available to you with limited functionality. You must back up your data and reformat the disk as soon as possible." Never saw that one before. This alert finally went away by itself, another "Device Removal" alert appeared, and now it's continually mounting the card then showing the removal alert, every few minutes.

  • Removing alert logs and trace files

    Hi everyone!
    I noticed that in all the oracle databases, the trace files are piling and alert log is growing like anything ....
    Thought of making a copy of the trace files somewhere and remove them from the hard disk excluding the most recent ones.
    For alert log, thought of making a copy and renaming the current file so that Oracle can create a new one.
    Any advice if there are better approaches in handling this?
    Thanks in advance.

    user645399 wrote:
    Hi everyone!
    I noticed that in all the oracle databases, the trace files are piling and alert log is growing like anything ....
    Thought of making a copy of the trace files somewhere and remove them from the hard disk excluding the most recent ones.
    For alert log, thought of making a copy and renaming the current file so that Oracle can create a new one.
    Any advice if there are better approaches in handling this?
    Thanks in advance.I would include the alert log file in my backup strategy as it includes many important information; database parameter values,when and how the database was shut down, the important database errors and when they occur , etc ... I usually backup the alert log file once a month and keep 1 year of alert log file copies..

  • Removing alert box in Add to Cart

    Hi,
    I really need your help on how to remove the add to cart alert box.
    I thought using window.alert=function(msg){}  would help but it removes all the other alert boxes in the site.
    Thank you.

    I wouldn't remove the alerts all together, just display them in a div.
    Here is what I do in the shopping cart.
    First open the shopping cart layout ( /Layouts/OnlineShop/shopping_cart-XX -- XX is the country code)
    Right above my checkout button (aka: {tag_buybutton} ) I insert this div:
    <span class="msg" style="display:none"></span>
    Then, in the same layout I insert this code:
    <script>
    $(function() {
         window.alert = function(msg) {
            msg = msg.replace('ERROR: ','');
            $('.msg').text(msg).fadeIn().delay(5000).fadeOut()
    </script>
    If you add this code to your site template it will remove all your alerts; this is why you only add the code to your layout.
    Hope this helps!

  • How to remove alert hadler?

    After uninstall spcolumnpermission, SharePoint grumbles:
    OWSTIMER.EXE SharePoint Foundation           Alerts
    Unexpected      FileNotFoundException while calling alert handler for subscription 5bccbda9-0320-4297-816e-d4d44657e2b5. Alert handler assembly: SPGuys
    CustomFieldPermissionLibrary, Version=1.0.0.0, Culture=neutral, PublicKeyToken=a8a8bdc8ce8bd55f. Alert handler class: SPGuysCustomFieldPermissionLibrar
    y.CustomAlertModule.
    How to remove this subscription?

    Hello
    Pls refer this
    Please try to check if you have HtmlAgilityPack.sll in your GAC. If not please download this sharepoint solution. This
    solution will add HtmlAgilityPack do your GAC. If this solution doesn't add this dll to GAC. Please add it manualy. In Zip file you will also find this dll file. 
    Thank you 
    http://spcolumnpermission.codeplex.com/discussions/399478
    Please remember to click 'Mark as Answer' on the answer if it helps you

  • Removing alerts from Designer Workflows

    Hi,
    I am currently in a predicament, and would appreciate any type of assistance (no code -just OOTB).
    I currently have a master list for my company, which individual users have alerts set up on. There are also numerous SPD 2010 workflows that go on in the background, that send out emails, and update fields based on certain conditions.
    The issue is that some of these workflows have been firing out of line and individuals with user alerts are getting emails every time a workflow fires and "Modifiies" the item.
    Is there any way to have an OOTB workflow that does not affect individual user alerts or is there some type of setting that will cause alerts to not recognize OOTB workflows produce by SPD, therefore it won't be sending out emails?
    Thanks!
    Greg
    Greg Baker

    Hi Greg,
    It looks like the alerts are the one which is creating problem. What really happening here is, whenever SPD workflow modifies / updates the list, the corresponding alert assigned to the list is sending an notification.
    Instead of modifying your workflow, you  may need to reconfigure the alerts.
    Try to change alert settings "send me an alert" choose the best option that fits your requirement,
    or
    "when to send an alert"
    Also there is no OOTB way to configure as per your requirement either on alerts or workflows.
    Hope this helps!
    MCITP: SharePoint 2010 Administrator
    MCTS - MOSS 2007 Configuring, .NET 2.0
    | SharePoint Architect | Evangelist |
    http://www.sharepointdeveloper.in/
    http://ramakrishnaraja.blogspot.com/

  • How to delete all ALERTS in iCal at once?

    Over the years I have added repeating Events with Alerts to iCal on various devices (some of them passed on to my relatives). As a  result I get plenty of Alert emails or sounds. I find it onerous to go through all repeating events to delete the alert. Hence my question: how to delete all Alerts at once?
    Thanks for any suggestions/pointers/ideas. Cheers, Veit

    Hi John,
    Thanks so much for your help with this problem. I am trying to remove alerts for a couple of specific shared calendars (which I can edit) but am having some difficulty due to my inexperience with applescript! I am also not sure where else to go for help solving this problem.
    My plan is to run your script a couple of times specifying one calendar at a time by name.
    This is the modification I made to your script:
    tell application "Calendar"
      activate
              delay 0.5
              display alert "Removing all alarms from your editable calendars" message "This process may take some time and is permanent. Are you sure you want to do this?" buttons {"Yes", "No"} cancel button 2
              set calname to "Consultant_on_call"
      --- repeat with myCalendar in (calendars whose writable is true)
              repeat with myCalendar in (calendars whose name is calname)
                        repeat with myEvent in events of myCalendar
      delete display alarms of myEvent
      delete mail alarms of myEvent
      delete sound alarms of myEvent
      delete open file alarms of myEvent
                        end repeat
              end repeat
              display alert "Removing all alarms from your editable calendars" message "This process is complete." buttons {"OK"} default button 1
    end tell
    Are you able to tell me what I am doing wrong? Thanks again.
    Andrew

  • Alert category - SALERT_CREATE

    Hi Al,
       When we define alert rule/Alert catefogy in  SAP PI, nomally it internally calls SALERT_CREATE report. How should i call customized ABAP report from an alert category?
    When i checked in alert category under Administration Data , i could find application pac which always has SALERT..What does it mean? Is it possile to change this so that alert category will call our customized ABAP report?
    Thanks
    Rajesh

    So you are terminating the mapping in case if your source payload does not contain the data for particular field and sending the error via alert...
    In order not to receive multiple alerts for this..either to remove the alert in UDF or should not end the message mapping in error if udf condition is not satisfied...(continue the mapping dont throw the alert in exception..instead use in try block itself.)
    if mapping should not be continued..for this error and if you remove alert in UDF,still  you can use enable trace in UDF and can find the cause of the error in moni..after receiving the alert using alert rule...(only thing will be error message will not be like what you will frame...)
    HTH
    Rajesh

  • Removing incidents in grid control from backend repos database.

    hi,
    Like we remove alerts sometimes by deleting from mgmt_severity, is there any table which can help me remove some incidents which are not clearing in grid control 12C?
    I really need it please.

    What kinds of incidents are not clearing?
    For stateless incidents (such as logfile based incidents) you will need to manually clear the incident. You can remove the underlying alert using emcli clear_stateless_alerts.
    http://docs.oracle.com/cd/E24628_01/em.121/e17786/cli_verb_ref.htm#CACGAEDI
    The other alerts should be cleared by fixing the root cause after which the Incident should clear automatically.
    Mark.

  • ICal adding alert for 35791394 minutes after events

    Since I've upgraded to Mountain Lion, I'm now getting random Alerts set for 35791394 minutes after the event (between one to three alerts with the same number of minutes for each event). I'm syncing with iCloud to an iPhone 4S and iPad (3), both with most recent iOS. All calendars are set to default with None for Alerts (on all devices).

    I've been following this - and have just been holding off contacting Apple, since it seems there's no fix yet from what some of you have gone through - But I've done a few tests tonight and can replicate the alert - here's what I found - maybe this can shed some light on the bug for some Apple tech:
    Make event in Calendar - no alert
    Open it on iPhone - shows alert at time of event
    Edit it on iPhone - now in Calendar it shows Alert - Message 35791394 minutes after.
    Edit on Calendar to set Alert to NONE,
    iPhone still shows Alert at Time of Event
    Edit iPhone to remove Alert to NONE
    Calendar still shows NONE (as before)
    Edit iPhone timing of event, still alert None
    Calendar still shows NONE
    ---------NEXT-------
    Make event in Calendar - no alert
    iPhone shows Alert at Time of Event
    Remove alert, set to None AND edit time of event on iPhone
    Calendar still shows no alert.
    -----So it seems to me that an event created first on Calendar with no alert - shows up on iPhone with Alert at Time of Event - then if you edit it on iPhone - it goes back to Calendar with the Alert -Message 35791394 minutes after.
    But... if you FIRST remove the Alert on the iPhone before editing the time of event - it doesn't create an alert back in Calendar.

  • I am trying to download a calendar into ical and keep getting this message-Some of the events in this calendar have alerts that open files or applications.  What am I doing wrong???

    I am trying to download a calendar into ical and keep getting this message-Some of the events in this calendar have alerts that open files or applications. Remove alerts or cancel 
    What am I doing wrong or missing??

    I have this same problem in October of 2013. I am unable to import .ics files into Lion that I exported from my Snow Leopard MacBookPro without losing all of my future events (which all have alerts attached). All of the events from BEFORE today's date are successfully importing, presumably because they are no longer expected to trigger alerts via Apple Mail. After my first unsuccessful attempt, I learned that iCal was communicating with iCloud by default. I have since turned off iCloud, but I have not found a solution to the problem. Harvey

  • Managing Alert log files : Best practices?

    DB Version : 10.2.0.4
    Several of our DBs' alert logs have become quite large. I know that oracle will create a brand new alert log file if i delete the existing one.
    But i just want to know how you guys manage your alert log files. Do you guys archive (move to a different directory) and recreate a brand new alert log. Just want to know if there any best practices i could follow.

    ScottsTiger wrote:
    DB Version : 10.2.0.4
    Several of our DBs' alert logs have become quite large. I know that oracle will create a brand new alert log file if i delete the existing one.
    But i just want to know how you guys manage your alert log files. Do you guys archive (move to a different directory) and recreate a brand new alert log. Just want to know if there any best practices i could follow.Every end of day (or every periodic time) archive your alert.log and move other directory then remove alert.log.Next time Database instance will automatically create own alert.log

  • Remove unused styles in one action...

    Hi everyone,
    Is there any better and quick way to delete unused Paragraph styles and character styles in InDesign without looping the styles. Below is my created script. Its working fine.
    var doc=app.activeDocument;
    var pStyle=doc.paragraphStyles;
    for (i=pStyle.length-1; i>=2; i--){
        app.findTextPreferences=app.changeTextPreferences=null;
        app.findTextPreferences.appliedParagraphStyle=pStyle[i];
        var myFind=app.findText(false);
            if (myFind==0){
                pStyle[i].remove();
    alert("OK");
    But in our documents we have lot of styles. So above script is taking few minutes to perform the task. It could be better if it has perform the action in few seconds. Can any one look into this and provide me a better solution.
    Thanks in advance
    Thiyagu

    Hi Jongware,
    First of all my honorable thanks for your great support valuable comments. I have checked the script and added few lines as you said. Now the script is working fine.
    But conern is the script is not consider the texts in the tables of the stories. So inside the table, the text styles are also treated as unused styles and get removed.
    Find the updated script below.
    var allpars = app.activeDocument.stories.everyItem().paragraphs.everyItem().appliedParagraphStyle;
    var pStyles = app.activeDocument.paragraphStyles;
    var parlist = new Array;
    rmvPStyles();
    function rmvPStyles(){
        for (a=0; a<allpars.length; a++)
            add_me = true;
            for (b=0; b<parlist.length; b++)
                if (parlist[b] == allpars[a])
                    add_me = false;
                    break;
            if (add_me)
                parlist.push (allpars[a]);
        for (c=pStyles.length-1; c>=2; c--){
            myStyle=pStyles[c];
            if (styleInArray(myStyle, parlist)){
                pStyles[c].remove();
    function styleInArray(ParaStyle, myArray){
        for (y in parlist){
            if (ParaStyle == parlist[y]){
                return false;
        return true;
    alert ("DONE");
    Can you please look into this and help me out.
    Thanks
    Thiyagu

  • How to get a kerning value in JavaScript

    How to get a kerning value(distance between two characters) using javascript?

    @Raykor11:
    It would be best to move that question to scripting forum for InDesign.
    But one solution could be:
    1. Read out the property kerningValue from the insertion point between the two characters:
    //if two characters are selected:
    var _kerningValue = app.selection[0].insertionPoints[1].kerningValue;
    2. Measure the exact distance between the characters, so you can decide if you want to increase or decrease the distance
    //Two characters are selected:
    var _twoCharacters = app.selection[0];
    var _charLeft = _twoCharacters.characters[0];
    var _charRight = _twoCharacters.characters[1];
    var _temp1 = _charLeft.createOutlines(false) //false = does NOT delete original
    var _bounds1 = _temp1[0].visibleBounds;
    var _temp2 = _charRight.createOutlines(false) //false = does NOT delete original
    var _bounds2 = _temp2[0].visibleBounds;
    var _distance = _bounds2[1]-_bounds1[3];
    _temp1[0].remove();
    _temp2[0].remove();
    alert("Distance between: "+_distance);
    Be aware that there are a lot of other factors that will apply to character distance if you change the kerning value (like tracking, kerning method, composer, desiredGlyphScaling, desiredLetterSpacing, horizontalScale … just to mention a few), especially if the paragraph justification is set to JUSTIFIED or FULLY_JUSTIFIED.
    Uwe

  • How to 'import xml' in my script

    Hi All,
    Below "Script 1" is working fine, now I want to call the '.xml' file which was placed in Template folder(see script code).
    How to import xml in 'New.indd' file("Line 27:-->var source = File(path + '/New.indd')".
    Please add import xml code in 'Script 1"
    Script 1:
    var path = Folder.selectDialog ("Select folder");
    if(path==null)
    exit();
    var files = path.getFiles(/\.(indd?|indt?)$/i);
    if(files==0)  
      alert("There is no 'indd'/'indt' file in your folder");
      exit();
    app.scriptPreferences.userInteractionLevel = UserInteractionLevels.NEVER_INTERACT;
    try
    myDocument = app.open(new File(files));
    MasterpageScriptLabel();
    TableCellStyleCreation();
    myDocument.save(new File(path + "/New.indd"));
    var folder = new Folder(path + '/Updated_Folder');
    folder.create();
    myDocument.close();
    var source = File(path + '/New.indd');
    var dest = new File(folder + '/New.indd');
    source.copy(dest);
    source.remove();
    catch(e)
    alert ("Your folder permissible only one file of 'INDD' or 'INDT' file");
    exit();
    function MasterpageScriptLabel()
    var myDoc=app.activeDocument;
    var myXMLElement=myDoc.xmlElements[0];
    if(myXMLElement.isValid)
        var myParentStory=myXMLElement.parentStory;
        var myTextContainers=myParentStory.textContainers;
        for(var i=0;i<myTextContainers.length;i++)
            myTextContainers[i].label="S_TF";
    var myDoc=app.activeDocument;
    var mspreads=myDoc.masterSpreads;
    for (i=0;i<mspreads.length;i++)
    if(mspreads[i].textFrames.length>1)
        var txfmlength=mspreads[i].textFrames;
        for (j=0;j<txfmlength.length;j++)
            if(txfmlength[j].nextTextFrame!=null)
            {txfmlength[j].label="S_TF";}
            if(txfmlength[j].previousTextFrame!=null)
            {txfmlength[j].label="S_TF";}
    function TableCellStyleCreation()
        var cestyle = myDocument.cellStyles;
        var array = ["TBL_COLH", "TBL_BODY"];
        var i = array.length;
        while(i--)
                try{
                    var style = myDocument.cellStyles.add();
                    style.name = array[i++];
                catch(e)
                    style.remove();
                    alert("'" + array[i-1] + "'"+ " Already exists in the document.")
                i--;
    main();
    function main(){
          var progress_win = new Window ("palette");
    var progress = progress_bar(progress_win, 2, 'Processing ... Completed');
        delay(1);
          progress.value = progress.value+1;
        delay(1);
        progress.parent.close();
    // delay function found here
    //found here http://www.wer-weiss-was.de/theme157/article1143593.html
      function delay(prmSec){
      prmSec *= 1000;
      var eDate = null;
      var eMsec = 0;
      var sDate = new Date();
      var sMsec = sDate.getTime();
      do {
      eDate = new Date();
      eMsec = eDate.getTime();
      } while ((eMsec-sMsec)<prmSec);
    * Taken from ScriptUI by Peter Kahrel
    * @param  {Palette} w    the palette the progress is shown on
    * @param  {[type]} stop [description]
    * @return {[type]}      [description]
    function progress_bar (w, stop, labeltext) {
    var txt = w.add('statictext',undefined,labeltext);
    var pbar = w.add ("progressbar", undefined, 1, stop);
    pbar.preferredSize = [300,20];
    w.show ();
    return pbar;
    by
    hasvi

    DECLARE @x xml=N'
    <Jobs>
    <Job>
    <JobCode>123</JobCode>
    <JobTitle>Years</JobTitle>
    <JobSubCode>
    <div>
    <Ol>
    <li>2001</li>
    <li>2002e</li>
    <li>2003</li>
    <li>2004</li>
    </Ol>
    </div>
    </JobSubCode>
    </Job>
    </Jobs>'
    SELECT J.c.value('(JobCode/text())[1]', 'varchar(10)') AS JobCode,
           J.c.value('(JobTitle/text())[1]', 'nvarchar(40)') AS JobTitle,
           L.c.value('.', 'varchar(10)') AS Years
    FROM   @x.nodes('/Jobs/Job') AS J(c)
    CROSS  APPLY J.c.nodes('JobSubCode/div/Ol/li') AS L(c)
    Erland Sommarskog, SQL Server MVP, [email protected]

Maybe you are looking for