How to check an action is complete
I have some code, seen below, that creates a typing... thing.
Basically when you start the code, it creates 26 random letter jumbles on screen, each beginning with a different letter of the alphabet.
You then type these jumbles, one by one, to make them disappear.
How It works as I have posted it below is that you have to type the first letter twice, but if you have a quick look through you can see there is a (red) commented out line that I want to include in order to delete the first letter first try.
But it seems that it can't parse the previous action fast enough in order to carry it out.
Is there a way to tell flash to wait until the previous action has completed before it tries to parse the one at hand?
var available:int=0;
var letterCode:int;
var keyPressed:String;
var focusWord:TextField;
var aWord:TextField;
var wordArray:Array = new Array;
var wordsFormat:TextFormat = new TextFormat;
wordsFormat.size = 20;
wordsFormat.font = "Cooper Std";
wordsFormat.align = TextFormatAlign.CENTER;
var centerFormat:TextFormat = new TextFormat;
centerFormat.size = 100;
centerFormat.color = 0xFFFFFF;
for(var i:int = 0; i<26; i++){
newWord();
function newWord():void{
letterCode = 65;
wordsFormat.color = Math.random() * 0x999999 + 0x444444;
aWord = new TextField;
addChild(aWord);
aWord.defaultTextFormat = wordsFormat;
aWord.y = Math.random() * (stage.stageHeight-25);
aWord.x = Math.random() * (stage.stageWidth-100);
aWord.width = 140;
testLetter()
function testLetter():void{
if (wordArray.length>0){
for(var j:int = 0; j<wordArray.length; j++){
if (wordArray[j].text.charAt(0) == String.fromCharCode(letterCode))
available++
if (available==0)
fillLetters();
else{
available=0
letterCode++;
testLetter();
else fillLetters();
function fillLetters():void{
aWord.text = String.fromCharCode(letterCode);
for (var k:int = 0; k < Math.random()*5+3; k++){
letterCode = Math.random()*26+65;
aWord.appendText(String.fromCharCode(letterCode));
wordArray.push(aWord);
if (i > 24)
stage.addEventListener (KeyboardEvent.KEY_DOWN, checkKey);
function checkKey (e:KeyboardEvent):void{
keyPressed = String.fromCharCode(e.charCode).toUpperCase();
for(var l:int = 0; l<wordArray.length; l++){
if (wordArray[l].text.charAt(0) == keyPressed)
focusWord = wordArray[l];
// focusWord.replaceText(0, 1,"");
stage.removeEventListener (KeyboardEvent.KEY_DOWN, checkKey);
stage.addEventListener(KeyboardEvent.KEY_DOWN, deleteText);
function deleteText (e:KeyboardEvent):void{
keyPressed = String.fromCharCode(e.charCode).toUpperCase();
if (keyPressed == focusWord.text.charAt(0)){
focusWord.replaceText(0, 1,"");
if (focusWord.length == 0){
stage.removeEventListener(KeyboardEvent.KEY_DOWN, deleteText);
stage.addEventListener (KeyboardEvent.KEY_DOWN, checkKey);
var available:int = 0;
var letterCode:int;
var keyPressed:String;
var focusWord:TextField;
var aWord:TextField;
var wordArray:Array = new Array ;
var wordsFormat:TextFormat = new TextFormat ;
wordsFormat.size = 20;
wordsFormat.font = "Cooper Std";
wordsFormat.align = TextFormatAlign.CENTER;
var centerFormat:TextFormat = new TextFormat ;
centerFormat.size = 100;
centerFormat.color = 0xFFFFFF;
for (var i:int = 0; i<26; i++)
newWord();
function newWord():void
letterCode = 65;
wordsFormat.color = Math.random() * 0x999999 + 0x444444;
aWord = new TextField ;
addChild(aWord);
aWord.defaultTextFormat = wordsFormat;
aWord.y = Math.random() * (stage.stageHeight-25);
aWord.x = Math.random() * (stage.stageWidth-100);
aWord.width = 140;
testLetter();
function testLetter():void
if (wordArray.length > 0)
for (var j:int = 0; j<wordArray.length; j++)
if (wordArray[j].text.charAt(0) == String.fromCharCode(letterCode))
available++;
if (available == 0)
fillLetters();
else
available = 0;
letterCode++;
testLetter();
else
fillLetters();
function fillLetters():void
aWord.text = String.fromCharCode(letterCode);
for (var k:int = 0; k < Math.random()*5+3; k++)
letterCode = Math.random() * 26 + 65;
aWord.appendText(String.fromCharCode(letterCode));
wordArray.push(aWord);
if (i > 24)
stage.addEventListener(KeyboardEvent.KEY_DOWN, checkKey);
function checkKey(e:KeyboardEvent):void
keyPressed = String.fromCharCode(e.charCode).toUpperCase();
for (var l:int = 0; l<wordArray.length; l++)
if (wordArray[l].text.charAt(0) == keyPressed)
focusWord = wordArray[l];
focusWord.replaceText(0, 1,"");
stage.removeEventListener(KeyboardEvent.KEY_DOWN, checkKey);
stage.addEventListener(KeyboardEvent.KEY_DOWN, deleteText);
function deleteText(e:KeyboardEvent):void
keyPressed = String.fromCharCode(e.charCode).toUpperCase();
if (keyPressed == focusWord.text.charAt(0))
focusWord.replaceText(0, 1,"");
if (focusWord.length == 0)
stage.removeEventListener(KeyboardEvent.KEY_DOWN, deleteText);
stage.addEventListener(KeyboardEvent.KEY_DOWN, checkKey);
Similar Messages
-
How to check which action is completed in a Process having Multiple Actions
Hi,
In a GP that we designed, a Process contains multiple actions, so what we want to achieve is after 1st Action is completed i.e once 1st Approver approves the request, next action is executed wherein a Notification Workitem in his/her UWL is sent to initiator to notify the approvers action whether it rejected or approved.
My question is when a Initiator starts a process, then he/she is not able to start the same process again, unless & until the process is finished, but now the requirement is, if 1st Level Approver i.e 1st Action, is completed, we need to allow the Initiator to start a new process of same name in-spite of 2nd Action & previously started process is not completed.
Please let me know if I can find whether in a Process a particular Action is completed or not.
Thanks.
Regards
TusharHi,
Any possible inputs for my query......
do let me know for your suggestions.
Thanks
Best Regards
Tushar.S -
How to check the action selected by the user in CRMD_ORDER
Hi all,
I have created actions and these actions will be displayed in the actions tool box in CRMD_ORDER
transaction.
User can select any actions as required.
When the user selects any one of these action, i want to get the action selected by the user and i want to validate aganist a field in the same transaction.
This validation should happen only for certain actions, so i want to find out the action selected by the user .
I didnt find any threads related to this. Pls provide inputs.
Thnks,
Jean.Hi PePe,
Thnks for ur rply. But both the BADI's didnt helped me, I didnt find any information related to action in these BADI's.
Any other suggestion pls.
Regard's
Jean.
Didnt find exact solution, i got alternative solution to my requirement. closing the thread. -
R12.1.1 staging complete! How to check whether the stage is Good
Hi Gurusl,
I have completed staging R12.1.1 for Hp unix B.11.31. I want to know how to check whether the stage is good for installation or whether it is corrupted. Is there any metalink note or script from where we can check it. Ur help will be highly appreciated. Thanks in advance
regards,Hi,
Please refer to (Note: 802195.1 - MD5 Checksums for R12.1.1 Rapid Install Media).
Regards,
Hussein -
With a PDF Dynamic form using show/hide actions, how to ensure that when the completed form is saved, closed and re-opened, the form still show the fields as before it was closed?
I have developed a form with fields hidden by default, that become visible based on box ticked or radio button selections.
My problem is that, when I close the form and re-open it, it comes back to it's default presentation, regardless of the information already recorded in the form (including in the now hidden fields.
How to correct that
Thanks in advance for any hint you can provide.I've had the same problem. This solved it...
Go to the "Form properties..." in the File-menu. Select "Run-time" to the left and in the box "Scripting" Preserve scripting changes to form when saved: choose Automatically (Script-based state changes are saved locally in an insecure fashion. This option cannot be used for certified forms).
Hope it works for you to... -
How to check Sales Order complete or incomplete in program?
Hi, Gurus:
In the program, how to check Sales Order complete or incomplete based on Order Number vbeln?
Thanks,You can check the status table VBUK for this.
VBUK has all the status related fields in it.
Search for the field which suits to your specific requirment.
Regards,
Naimesh Patel -
How to record user action?
Dear All,
I am trying to build a performance testing tool like jmeter. I want to know how jmeter or any HTTP performance tool records user action. I don't know how to write the action recording code. If anybody knows please help me out.
The following are the logic behind the jmeter action recording
1. Turn on the proxy (HTTP in this case). Jmeter starts listening to HTTP traffic to/from the specified URL. It basically acts like a sniffer for the traffic between your client (the browser) and the server IP address.
2. User starts performing his business process (the activities/requests to the server).
3. When a request is sniffed/captured by the tool, it immediately creates a code to send the same request (basically an HTTP GET/POST method created).
4. At the same time it monitors the response from the server and creates a checking code for verifying that the response obtained is correct (This is used further by the tool when we run the test). The response includes the complete HTML data including the Header and Body sections.
5. All the requests and corresponding responses are captured by the tool and the corresponding code generated automatically.
6. Once the recording ends, it puts together these snippets to create a complete code which could be further modified by the users so that they can run it in a multi-threaded environment.
7. Users run the code specifying the number of users (basically threads) to perform a load test on the server. (The code generated would be thread-safe so that there are no overlaps)
Thanks & regardsSo why not using Jmeter and make you own modification when required
This is the great benefit of open source community
Regards,
Alan Mehio
London,UK -
Disabling "Beep till the action is completed" in Power Manager
Hi,
I selected the the "beep till the action is completed" checkbox when the lid is closed, and the continuous beeping is starting to annoy me now. I was looking through the on-system help that comes with Power Manager (v3.01a) and it doesn't say how to undo the change. I would like to revert back to the default single beep when the lid is closed.
Any help would be appreciated, thanks.
ThinkPad T400 2767-RV8 Win7 Ultimate x64, ThinkPad T61 7659-AB5 Win7 Home Premium x64hey tuna91,
that's a bit strange, could you uninstall the 3.64 version and then install version 3.62 which is located below and see if the option returns ?
http://download.lenovo.com/ibmdl/pub/pc/pccbbs/mobiles/8ru410ww.exe
WW Social Media
Important Note: If you need help, post your question in the forum, and include your system type, model number and OS. Do not post your serial number.
Did someone help you today? Press the star on the left to thank them with a Kudo!
If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"!
Follow @LenovoForums on Twitter!
Have you checked out the Community Knowledgebase yet?!
How to send a private message? --> Check out this article. -
How to mark a Document as completed
Hello Experts,
We have a one DP document in status "Document Created". The Work item status is In Process.
This document was created in August 2012 and now we need to mark it as completed.
The last action on 5th Nov 12 is Work Item started manually.
Could you please let me know how to mark a document as completed which is in status "Document Created" in SAP IM?
Let me know if you need additional inputs to analyze.
Thanks in advance.
Leena S.Hi,
Can let us know what is the workflow template ID, Standard or Custom?
Provide the template ID if it is standard.
Is there any wait step in the workflow template. which is waiting for some event?
Is there any end condition defined for the step in the workflow template?
Check, if any terminating events are mapped to the task-id from PFTC transaction. If exists, then try to raise the event manually from SWUE transaction, if the system is not PROD.
If there are no terminating events then try to complete the work-item manually from SWIA transaction.
Regards
Pavan -
Open Slaes Order-How to check and close ?
Hi,
We have an open sales order which looks like the delivery is closed and 100% completed, but the sales order is still open!
Now i know this is an ongoing issue which has several possible reasons for and i have used a script to see what is returned but nothing.
Can you let me know how to check if there were any changes made in any particular Sales orders ?
eg comparing open items list of sales orders with something ?
Thank you in advance,Hi,
Yes we ran the query in note 948670 and it came back zero for all?! See below for details.
This is what has thrown us so what is the simplest way to check why a SO remains open i.e how to check if there were any changes made?
Rdr u2013 0 Rows
Dln - 0 Rows
Rdn - 0 Rows
Por - 0 Rows
Pdn - 0 Rows
Rpd - 0 Rows -
SRM RFx Response - How to check if a button is clicked or not
Hi All,
This is rani. Im very new to SAP.
Im into my first project, in which im having an Immediate enhacement.
In SRM Portal, I need to logged in as bidder to create a bid response.
"Participate" button is there, i need to clicked that button, this is mandatory.
So how and where to check whether the button is clicked or not.
else i need to raise the error message in BBP_DOC_CHECK_BADI and some fileds needs to be grayed out.
The webdynpro component is FPM_OIF_COMPONENT.
Can u please help me out in this regard.
Thanks in Advance,
Rani.Hi Rani ,
In SRM 7.0 the system variables ( sy-ucomm & sy-Tcode ) will not work .
if you want the action code triggered in the Webdynpro screen inside the BADI: BBP_DOC_CHECK_BADI
kindly study the SAP Note 1334202 - How to get current action ID and transaction group
Below piece of code will give you the action Id in side the badi
DATA: lo_trans_context TYPE REF TO /sapsrm/if_transaction_context,
lv_action TYPE /sapsrm/pdo_action_type,
lv_tcode TYPE /sapsrm/transaction_group.
lo_trans_context = /sapsrm/cl_transaction_context=>/sapsrm/if_transaction_context~get_instance( ) .
lv_action = lo_trans_context->get_current_action( ). " replacement for sy-ucomm
lv_tcode = lo_trans_context->get_transaction_group( )." replace ment for sy-tcode
kindly go through the SAP note provided .
Regards
Chinnaiya P
Edited by: chinnaiya pandiyan on Jun 27, 2011 7:34 PM -
Z-Button - How to call a Action Profile to Open a PDF-Doc. within an Event?
Hi Experts,
we have created a Z-Button that afterwards creates an event. In the coding for the event an Action Profile should be called and a PDF-Document should be opened. We have copied the coding from the standard button 'Print Preview' which is calling the standard event: EH_ONPRINT_PREVIEW.
We have also defined a Z Action Profile which is a copie of SERVICE_CONFIRMATION. Our problem is we don't know how why our Z-Action Prodile is not called? What is the class lr_actioncontext (TYPE REF TO cl_crm_bol_entity)?
DATA: lr_cn TYPE REF TO cl_bsp_wd_context_node,
lr_adminh TYPE REF TO cl_crm_bol_entity,
lr_actioncontext TYPE REF TO cl_crm_bol_entity,
lv_adminh_guid TYPE string,
lv_url TYPE string,
lc_head_context TYPE REF TO cl_doc_context_crm_order,
lt_item_context TYPE ppftctxpos,
iv_header_guid TYPE crmt_object_guid,
lif_decision_pop TYPE REF TO if_bsp_wd_popup,
lv_string TYPE string.
CHECK gv_print_preview_enabled = abap_true.
lr_cn = me->get_context_node( gc_cn_btadminh ).
CHECK lr_cn IS BOUND.
lr_adminh ?= lr_cn->collection_wrapper->get_current( ).
CHECK lr_adminh IS BOUND.
lv_adminh_guid = lr_adminh->get_property_as_string( iv_attr_name = 'GUID' ).
lr_actioncontext = lr_adminh->get_related_entity( iv_relation_name = 'BTHeaderAction' ). "#EC NOTEXT
CLEAR gt_print_actions.
CLEAR gr_action_popup.
iv_header_guid = lv_adminh_guid.
CALL METHOD cl_crm_uiu_actions_tools=>get_action_definition
RECEIVING
rv_action_def = lv_string.
CALL METHOD cl_crm_uiu_actions_tools=>show_print_actions_popup
EXPORTING
ir_action_context = lr_actioncontext
ir_parent_node = lr_adminh
ir_view_controller = me
ir_component_controller = comp_controller
iv_event_name = gc_ev_print_preview_closed
iv_for_preview = abap_true
iv_appl_guid = lv_adminh_guid
IMPORTING
et_actions = gt_print_actions
ev_url = lv_url
CHANGING
cr_decision_popup = gr_action_popup.
IF lv_url IS NOT INITIAL.
call_print_preview_popup( lv_url ).
ENDIF.
Best RegardsClosed. No answers.
-
OSB : How can we copy actions from one project folder to other projects?
How can we copy actions from one project folder to other projects in OSB?
For eg:
I have a service call out action in Project1/proxySer1
I want to copy this to Project2/proxySer2.
Espicially, in our case error handling callout is common to all of our projects and we should be able to copy from one to another.
Edited by: user10367892 on Aug 20, 2009 12:28 PMThank you for the reply.
It was my fault. I was on two different servers, while i was doing this and so didn't work. But copy /past action works as you suggested.
Can I select multiple actions from one stage and paste to different proxy service? I have too many options to copy/paste and hence I have this question.
Is there any other way of copying all selected actions in one stage to another, but not the complete stage itselft? -
How to use same actions for differ pop-up
Hi gurus,
I am using 2 popup in a view.same popup's having same buttons 'Yes', 'No'.when i use 1st one i have to create an action for that Yes button where i put my code for that particular Action.
But when i used 2nd one the action define for that is not acceptable with differ name.it takes only standard one.
Now my Query is : How to use same actions for differ pop-up buttons with in a similar view?Where i put my code.
Plz sugges me.
<b>Points will be sured.</b>
Sanket sethiHi,
Take one integer value attribute in the context of view
when you r performing action on POP1 set it's value to 1
when you r performing action on POP2 set it's value to 2
create one method which receives integer argument, say diaplay(int a)
In the action call display(wdContext.currentContextElement().get<intvariable>()) by passing the value in the context attribute
in display() method, Check the value of integer variable..
if it is 1 then perform action related to POP1
if it is 2 then perform action related to POP2
Regards
LakshmiNarayana -
How to check the Memory consumtions and time taken by a Java Program??
HI all,
I want to know how to check for the Memory Usage of an XML Parser.
See, a product was developed completely in DOM parser and now I am replacing that thing with SAX Parser Completely, because the DOM parser was taking huge memory as u may have guessed.
BUt the thig is that, now I want to check how much memory is being taken by the SAX parser alone and DOM parser alone so that I can compare them.
Can anyone suggest me how to do that ???
Thanx in Advance
KaushikThanx boss ..thanx a lot
I tried that, but in the API docs, it is mentioned that freeMemory()Returns the amount of free memory "in the system"
and totalMemory() Returns the total amount of memory in the "Java Virtual Machine".
So if I compare both the Values then would it give the Correct result to me ???? Beacuse the freeMemory() gives the data in terms of the Host System whereas totalMemory() provides the data in terms of Java Virtual Machine ..... are they Same ?????
I think I am clear in explaining what exactly is going on my mind ...
Please clarify
Thanx again
Kaushik
Maybe you are looking for
-
Can anyone please help me with getting Logic to control the bank changes on this beast. I have it controlling the patch changes no problem it is just the bank changes I need thanx
-
Print with metadata and/or titles
I have iPhoto 5 (non-intel iMac G5) and know how to print a contact sheet using iphoto. Can I get it to print the metadata for each photo next to the photo? If not, can I get it to print the titles with the picture? I'm taking a class and need to bri
-
Purchase order ME21N screen layout-document overview
One of my users has an issue with the screen layout for transaction ME21N, when they click document overview on, everything works ok, when it gets switched off, the screen cannot be maximised, i have attached a screen print what could have caused thi
-
Windows 10 TP build 9926 Enterprise English UK x64 iso SHA1 value
I am getting the media driver missing error during installation.I cannot find the sha1 value for the iso.what is it? 9926.0.150119-1648.FBL_AWESOME1501_CLIENTENTERPRISE_VOL_X64FRE_EN-GB.ISO mine is F204C1DBDDA7F7653B24F51D845F823FF2858338 I want to c
-
ICloud Keychain verification codes
How do I stop getting iCloud Keychain verification codes via text