Problem when getting the choice clicked by the user on a confirmation dialo

Hi
I want to prompt a confirmation Dialog, before deleting from a table,
with yes,no,cancel options.
Then I created 3 event handlers
1.EmpRemove-parameter is 'cosid'
  code:
     public void EmpRemove(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, java.lang.String consid )
           try
              int n=stmt.executeUpdate("delete SaConsultantMaster where ConsultantId='"consid"'");
          wdThis.showDialog("The Details of the consultant  Are removed !!!");
          wdThis.EmpReset();
           catch(Exception e){}
2.No
public void No(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
3.Cancel
public void Cancel(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
in my Action coding:
I wrote.
          String Message="Do u want  to Remove The Consultant "empid" ??";
          IWDControllerInfo controllerInfo = wdControllerAPI.getViewInfo().getViewController();
          com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent1=null;
          wdThis.EmpRemove(wdEvent1,empid);
          IWDConfirmationDialog dialog =wdComponentAPI.getWindowManager().createConfirmationWindow( Message, controllerInfo.findInEventHandlers("EmpRemove"), "Yes");
          dialog.addChoice(controllerInfo.findInEventHandlers("No"),"No");
          dialog.addChoice(controllerInfo.findInEventHandlers("Cancel"),"Cancel");
          dialog.open();
but the problem is
   Before clicking the choice, itself the record is getting deleted.
   If i click yes/No/Cancel, the action in event handler empremove is executing.
And when passing parameters to eventhandler, what should i give for 'Event' parameter?
can anybody help me..
Thanks in advance.
Smitha

Hi Smitha,
in your action coding you call your EventHandler EmpRemove before showing the dialog:
wdThis.EmpRemove(wdEvent1,empid);
IWDConfirmationDialog dialog =wdComponentAPI.getWindowManager().createConfirmationWindow( Message, controllerInfo.findInEventHandlers("EmpRemove"), "Yes");
So remove the line "wdThis.EmpRemove(wdEvent1,empid);" and let the EventHandler do his work when the user confirms the deletion. Probably you should als check whether and how your ConsultantId is transfered as parameter. Think about removing it from the EventHandler and getting the selection straight out of the table.
HTH
Tina

Similar Messages

  • Problem when getting the new iphone software iOS4

    I did the download to get the software but during the download i had a call ... didnt seem to disturb the download.. it then said it was backing up (syncing)... and then it would say "cancelling back up" n stop... ive tried to do it again .. many times and ive even turned both my laptop and my iphone off n retried it. but it goes straight to "backing up" but it cancells again! any help?!

    I also had trouble with updating to OS4 through iTunes update. What I did to get around it is this:
    1. Set iPhone to airplane mode and wifi off
    2. Open iTunes and connect iPhone
    3. If update message comes up - cancel (do not download and do not install)
    4. Create a backup (via sync and backup)
    5. While that is working, go to this site and download the 3GS OS4 firmware to your desktop.
    http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7437. 20100621.5urG8/iPhone2,14.0_8A293Restore.ipsw
    6. When 4 and 5 are complete, disconnect iPhone and reconnect it
    7. At the iPhone summary page, "shift + click" restore and select the firmware from the desktop.
    8. After upgrading the firmware to OS4, iTunes should recognize that the device has already been associated and offer to restore the most recent backup.

  • Problem when getting the process of execution of JAVAWS on PC

    Hello,
    I give here a part of my code:
    boolean stillrunning = true;
    Process p =null;
    while (stillrunning)
    try
         p=Runtime.getRuntime().exec(javawsPath + "javaws " + portalURL_);
    catch (Exception ext)
    printException(ext);
    try{
         int g = p.exitValue();
    stillrunning = false;
         catch(IllegalThreadStateException ex)
              printException(ex);
    The process of javaws is running normally on my Pc (Win Xp), but I have always stillrunning to false, it seems that the process p is killed but the javaws is still running.
    Can you help me? how can I get the Process p?
    Best regards

    Hello,
    Ok , I put the part that causes a problem to me :
    ============================
    Process p = null;
    boolean stillrunning= true;
    try{
    p=Runtime.getRuntime().exec(javawsPath + "javaws " + portalURL_);
    catch (Exception ext)
    printException(ext);
    try{
    int g = p.exitValue();
    stillrunning = false;
    catch(IllegalThreadStateException ex)
    printException(ex);
    ==========================
    The value of "stillrunning" is always "false", the process p is killed, however the application "javaws" is running.
    The value of exit is 0,
    Is it a normal behaviour?
    My purpose is to get the id of the process of javaws that I have launched, have you any idea how to get it.
    Thank you

  • Please help, i used to have various colors to select from when selecting FILL in Keynote such as red, now I only have a few pastel colors. I cannot seem to fix this problem to get the original colors back. Can someone please advise what I need to do.

    Please help, i used to have various colors to select from when selecting FILL in Keynote such as red, now I only have a few pastel colors. I cannot seem to fix this problem to get the original colors back. Can someone please advise what I need to do.

    i have on my ipad2 and re-download it - but I can't afford to loose the presentation that I currently have ....??
    Are you using Keynote on an iPad?
    If so you posted in the wrong forum, this is the Keynote Mac discussion and it is a different application. I dont know how the iPad works at all, so I cant help you, post in the Keynote iOS discussion.
    If you are using a Mac, the colours palette is accesed by clicking on the colour well (arrowed) and then selecting a colour chip or changing the color in the colour wheel.

  • Problem in getting the application login page

    Hi Firends,
    I am facing problem in getting the application login page.
    http://localhost:7777/pls/apex/f?p=102:1
    when i am clicking this link it is not directing me to the login page for this application.please let me know what could be the reason behind this.
    Thanks in advance

    Hi Martin, many thanks for replying. Let me know how this could effect in not getting the login page. I have checked in my application,it is by default "No application authorization required " and other option is " must not be a public user " . Should i change it to " must not be a public user from no application authorization required"
    please put more light on it. Y i am saying this because it was working fine day b4r yesterday but today i am getting problem in finding the login page of my application aftr providing the url. i am following the SSO authentication scheme and under Home>Application Builder>Application 102>Shared Components>Edit Security Attributes , i have given f?p=&APP_ID.:1:&SESSION. as home link and under Home>Application Builder>Application 100>Page 101>Edit Page Process, this code i have provided
    wwv_flow_custom_auth_std.login(
    P_UNAME => v('P101_USERNAME'),
    P_PASSWORD => :P101_PASSWORD,
    P_SESSION_ID => v('APP_SESSION'),
    P_FLOW_PAGE => :APP_ID||':1'
    as a source code.
    i am really stucked into it, and i need to finish is ASAP. Please provide all possible reasons for this problem.

  • Problem with getting the little blackberry icon

    Hi the blackberry I'm using is working and up to date. I was setting up my mates blackberry 9320 but having a problem with getting the little blackberry icon to appear in the top right corner of my phone where the GMS is and signal bar and stuff its something to do with blackberry.
    I tried downloading bbm and it say associating bbm with blackberry id and constant loads with nothing happening bbm not working
    I NEED THE TINY BB ICON AT TOP RIGHT???

    Hi neal123
                            That BlackBerry icon will appear near signal bar when we activate  BIS on a 3G device. Did he activated BIS on his account. ? 
    Click " Like " if you want to Thank someone.
    If Problem Resolves mark the post(s) as " Solution ", so that other can make use of it.

  • I am currently using Lightroom 5.6 and operating on a Mac with OSX Ver 10.9.5. I am receiving an error problem when doing the following -  I am exporting selected photos from a particular Catalogue saved on Drive 1 to a folder created on another Drive whe

    Hi, I am having a little trouble with exporting images to another drive and Catalogue and need some help if anyone can give me some advice
    I am currently using Lightroom 5.6 and operating on a Mac with OSX Ver 10.9.5.
    I am receiving an error problem when doing the following -
    I am exporting selected photos from a particular Catalogue saved on Drive 1 to a folder created on another Drive where a Lightroom Catalogue has been created. In this Catalogue I have arranged for the images once exported to be moved to a different folder - I used the Auto Import process under the File dialogue box.
    When processing the Export I receive an error message for each of the images being exported indicating the following -
    Heading Import Results
    Some import operations were not performed
    Could not move a file to requested location. (1)
    then a description of the image with file name
    Box Save As                                  Box  OK
    If I click the OK button to each image I can then go to the other Catalogue and all images are then transferred to the file as required.
    To click the OK button each time is time consuming, possibly I have missed an action or maybe you can advise an alternative method to save the time in actioning this process.
    Thanks if you can can help out.

    Thank You, but this is a gong show. Why is something that is so important to us all so very, very difficult to do?

  • Problem in getting the database connection from a connection pool

    Hai All,
    I am facing a problem in getting the database connection from a connection pool created on weblogic server 8.1.
    I am using the Oracle database 8.1.7.
    I have configured my connection pool, datasource and JNDI in weblogic.
    In my java program i have the following code to retrieve the connection.
    import java.sql.*;    
    import java.util.Hashtable;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    class jdbcshp1 {
        public static void main(String[] args) {
         Connection connection = null;
         try {
               Hashtable ht = new Hashtable();
               ht.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");  // Wanna get rid of this.
               ht.put(Context.PROVIDER_URL,"t3://localhost:7001"); // wanna get rid of this.
               // Get a context for the JNDI look up
               Context ctx = new InitialContext(ht);
            javax.sql.DataSource ds = (javax.sql.DataSource) ctx.lookup ("myjndi1");
              //Create a connection object
              connection = ds.getConnection();
         The above code is working fine but, the two ht.put statements are creating problem.
    The problem is, after converting the application into WAR file it can be deployed
    on any machine or different port on same machine. My application fails if its deployed on
    weglogicserver which is at different port.
    Is there any way that i can get rid of those ht.put statements or any other way to solve the problem.
    any help is appreciated.
    Thanks in advance
    Pooja.

    Hai All,
    Firstly, thanks for ur reply.
    Even i have seen some code which uses context constructor with out any parameter and works fine.
    i dont understand why its not working for my code.
    When i remove those ht.put code and use context constructor with out any parameter, it giving an error.
    Context ctx = new InitialContext();
    javax.sql.DataSource ds = (javax.sql.DataSource) ctx.lookup ("ocjndi");
    connection = ds.getConnection();The error is as follows:
    javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
    the above error is forcing me to include those code but if the port number is changed the code will not work. Plz let meknow if some setting have to be made.
    I appreciate all ur valuable help.
    Thanks once again.
    Pooja.

  • How to avoid the split problem when uploading the data from csv file

    Dear Friends,
                  I have to upload data from the .csv file to my custom table , i have found a problem when uploading the data .
    i am using the code as below , please suggest me what i have to do in this regard
          SPLIT wa_raw_csv  AT ',' INTO
                    wa_empdata_csv-status
                     wa_empdata_csv-userid
                     wa_empdata_csv-username
                     wa_empdata_csv-Title
                     wa_empdata_csv-department.
    APPEND wa_empdata_csv TO  itab.
    in the flat file i can see for one of the record for the field Title  as
    Director, Finance - NAR............there by through my code the  wa_empdata_csv-Title is getting splited data as "Director, and  Department field is getting Finance - NAR" , i can see that even though  " Director, Finance - NAR"  is one word it is getting split .
    .......which is the problem iam facing.Please could any body let me know how in this case i should handle in my code that this word
    "Director,Finance - NAR"   wil not be split into two words.
    Thanks & Records
    Madhuri

    Hi Madhuri,
    Best way to avoid such problem is to use TAB delimited file instead of comma separated data. Generally TAB does not appear in data.
    If you are generating the file, use tab instead of comma.
    If you cannot modify the format of file and data length in file is fixed character, you will need to define the structure and then move data in fixed length structure.
    Regards,
    Mohaiyuddin

  • Problem in getting the function template object from the repository.

    Hi all,
    I have created a par file. I have a JCO connection in that. I am facing problems in getting the function template object from the repository. This thing is running successfully when i try to deploy it in Tomcat. But i am facing problems when i try to deploy it in SAP EP 6.0.
    Below is statement which is giving error after being deployed to SAP EP6.
    This is executing fine when executed in Tomcat Server.
    // getting the object of function template
    IFunctionTemplate functionTemplate =
    aRepository.getFunctionTemplate("YADDNEWUSER");
    Note : YADDNEWUSER is the name of the RFC which I am calling from my JAVA Code.
    Thanks in advance,
    Divija

    This sounds like a bug in the smart upload code. I have used this stuff before, but it's probably an older version, so maybe they broke something. Enumerations aren't usually guaranteed to keep things in any particular order. I would say for now, make a method to take the enumeration and a param name to find the value. And write to the JSPSmart people.

  • Problem about get the workflow context

    There are 2 servers.
    One is Weblogic server (server1), deployed a fusion web project on it.
    Another is BPM server (server2), deployed the bpm process on it.
    On the fusion web project, we use API to get the tasks. But we encountered a problem about get the workflow context.
    There are 2 method to get the workflow context.
    1. getTaskQueryService().authenticate(userId, password, null, null), this method need to pass in useId and password, we can get the user form request but can't get
    password.
    2. getTaskQueryService().createContext(request), we pass the request on server1, but can't get the context on server2, exception thrown.
    Appreciate if you can give some help.

    javax.el.ELException: java.lang.SecurityException: [Security:090398]Invalid Subject: principals=[jcooper, ERole]
         at javax.el.BeanELResolver.getValue(BeanELResolver.java:266)
         at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:173)
         at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:200)
         at com.sun.el.parser.AstValue.getValue(Unknown Source)
         at com.sun.el.ValueExpressionImpl.getValue(Unknown Source)
         Truncated. see log file for complete stacktrace
    Exception thrown when createContext()

  • TS5179 I've been bitten by the "Missing MSVCR.dll file" problem when downloading the latest iTunes update (PC w/ Win-7 & Outlook-2007#. 'Have followed Apple's instructions of un-installing all Apple software, and re-installing it. #out of space...??)

    I've been bitten by the "Missing MSVCR.dll file" problem when downloading the latest iTunes update, 11.4.62 (on a PC w/ Win-7 & Outlook-2007#. 'Have followed Apple's instructions of un-installing all Apple software, and re-installing it (Ugh).  First result Outlook couldn't find my 1,385 item contact file in iCloud, although the outlook distribution lists were there.  Second result, upon installing iCloud again, I have two iCloud contact files shown in outlook - "iCloud" & iCloud, within iCloud".  1,332 & 1,385 contacts respectively. 
    Plus an iCloud installation error message saying iCloud moved 6,835 files to a "deleted items folder" somewhere.  This is NOT fun at 72-yrs old...!!
    So, how do I make sure I haven't lost anythying from Outlook?   Russ-AZ

    Interesting response, Kappy  -  Back to original post: "First result: Outlook couldn't find my 1,385 item contact file in iCloud, although the outlook distribution lists were there (therefore, initially I had lost my contact file from Outlook).  Second result, upon installing iCloud again, I now have two iCloud contact files shown in Outlook - "iCloud" & iCloud, within iCloud".  W/ 1,332 & 1,385 contacts respectively.  
    Plus an iCloud installation error message saying iCloud moved 6,835 files to a "deleted items folder" somewhere.  This is NOT fun at 72-yrs old...!!
    So, how do I make sure I haven't lost anythying from Outlook?   Russ-AZ"
    You can safely assume that I have tried using it!   So, to make things a little clearer:
         1)  I now have two iCloud "contacts files", w/ a different total count. What's the difference?  Why the different toatl count?
         2)  Since re-installing the Apple software (part of the MSVCR" recovery instructions) "couldn't possible affected Outlook", why am I getting an iCloud installation error message saying iCloud moved 6,835 files to a "deleted items folder" somewhere.  What's in those files? And where are they?
    Probably more important questions get down to:
         3)  Why is a basic Apple product upgrade "screwing-up Outlook"?  This iTunes upgrade, failing to install properly forced Outlook 2007 into a 2-min start-up cycle.  Which was fixed with this "Goat-Rpdeo" of re-installing MSVCR80.dll.
         4)  And under the latest release of iOS-7.0.4 on our iPhones, why is Apple now forcing us to use the iCloud to back-up our contacts, calendars & tasks, vs. allowing these files to be backed-up directly on our PC's via the USB cable?
    Thanks again for your interest and comments.  - Russ-AZ

  • I have a problem when installing the Developer Suite

    Hello,
    I'm new to Oracle and I'm having a problem when installing the Developer Suite 10g. I have the Oracle Database 11g installed, but when I try to istall the developer, it gives me this error: "Oracle Developer Suite 10g cannot be installed into an existing Oracle9i 9.2.0.1.0 oe higher Oracle Home", Although I have installed the same thing twice before and it was working.
    Please help me with this :(

    Hi user;
    I'm new to Oracle and I'm having a problem when installing the Developer Suite 10g. I have the Oracle Database 11g installed, but when I try to istall the developer, it gives me this error: "Oracle Developer Suite 10g cannot be installed into an existing Oracle9i 9.2.0.1.0 oe higher Oracle Home", Although I have installed the same thing twice before and it was working.What is your OS? If you are linux-unix level you are making installation wiht same user of Oracle Db11g? Did you try to create new Oracle_home and set it before start installation?
    Regard
    Helios

  • I have a problem when updated the new release of iphoto version(11 jun 2012). After that I cannot open any photo libraries and program is error.

    I have a problem when updated the new release of iphoto version(11 jun 2012). After that I cannot open any photo libraries and program is error. I must to force quit iphoto window. There are any fixed bug update.

    If you have no photos:
    Hold down the option (or alt) key key and launch iPhoto. From the resulting menu select 'Create Library' and start.
    Regards
    TD

  • I can't turn off find my ihone, always show "there was a problem when canceling the registration of this iphone with icloud" please help me. i can't restore my iphone before turn off find my iphone

    i can't turn off find my ihone, always show "there was a problem when canceling the registration of this iphone with icloud" please help me. i can't restore my iphone before turn off find my iphone

    If you are the original owner of the phone and know the Apple ID and password that were used to activate it originally, and if you have an existing backup to restore from, you can force it into recovery mode (which will completely erase it) and restore it as explained here: If you can't update or restore your iPhone, iPad, or iPod touch - Apple Support.  When you do you will encounter activation lock, and will have to provide the ID and password used to activate it originally in order to activate it again.  If you can't, you won't be able to activate and use it.

Maybe you are looking for

  • Network Place to SharePoint 2010 unable to access sub sites with error: "The folder may have been moved or deleted".

    I am working on SharePoint 2010 Enterprise and had recently upgraded our site from Sharepoint 3.0 Services to SharePoint 2010 Enterprise.  Everything seems to be working fine for the site, but there is one issue.  The problem I am running into is whe

  • Can't install Snow Leopard to iMac

    When I try installing snow leopard on my iMac I get the message, can't install this disc currently used for time machine backups (the disc is the iMac's internal hard drive). I tried installing with the computer already on and by booting directly fro

  • Where do I put classes shared between EJBs and WAR

    I have written some ValueObject classes stored in their own jar, they are used by a number of ejbs and and a Web application WAR. I have packaged the thing up as a single EAR but neither the EJBs or the jsps can see these classes. How do I share thes

  • JTextArea not gaining focus

    I have a tabbed pane consisting of 2 JPanels. Each panel has a text area (within a scrollpane) on both. All I want is for the text area to gain focus when its tab has been clicked. I've tried adding a changelistener to the tabbedpane:         tabbedP

  • Weblogic IBM Power 6 and Power 7

    We are planning to move our Weblogic from IBM P6 hardware to IBM p7 hardware. We are thinking of running admin server on p6 and managed servers on p7 hardware . does this will have any performance or conflict ? we are planning to use weblogic 10.3 Th