GetButton() gives 0 in a mouseDragged(MouseEvent)-Method instead 1,2,3

When processing a mouseDragged-event I try to get the Button which is dragged. Unfortunally I get the value 0 regardless which button has been pressed. Where can I get more information about this issue?

Here is the code:
class MyListener extends MouseInputAdapter
   public void mouseDragged(MouseEvent e)
      System.out.println (e.getButton();
}This Object ist registered as MouseListener and as MouseMotionListener on some Component. Every time the mouseDragged() is called the e.getButton() returns the value of 0.

Similar Messages

  • How long should I let Safe Mode startup run? I keep getting the "disk0s2 i/o error" message and I'm just not sure when to give up and try a different method. I already ran disk utility in Recovery Mode and it said there were no repairs needed.

    How long should I let Safe Mode startup run? I keep getting the "disk0s2 i/o error" message and I'm just not sure when to give up and try a different method. I already ran disk utility in Recovery Mode and it said there were no repairs needed but it still kept getting stuck on the apple loading screen.

    You have limited opportunity to attempt to create a backup of your created files.
    That is what the SafeBoot or safemode appears to allow you -- at the moment.
    Since the hard disk drive exhibits signs of failure or other major issues, plan
    on a replacement in the near future. You may be able to get the computer to
    start up in a regular full OS X (not safe mode) but consider its hours are limited.
    An externally enclosed hard disk drive (with own power supply, not relying on
    Mac ports to run it) is a good basic means of which to use a disk utility to make
    a copy or a Clone of the current OS X. This may help retrieve an archive that
    could be used along with a Time Machine backup, to restore your Mac once you
    get a new hard drive installed inside.
    Good luck & happy computing!

  • Pls give me the code to load method only once in JVM.

    Hi all,
    Pls give me the code to execute method only once in JVM.Even if we create more than one instance to call the method.
    Thanks & Regards,
    Vinodh

    [How to ask a question on these forums|http://catb.org/~esr/faqs/smart-questions.html]

  • Static factory methods, instead of constructor

    Hi All,
    why we use static factory methods, instead of constructor.
    Apart from Singleton class , what is use of static factory methods ?
    Thanks in Advance,
    Rishi

    One reason for using factories is that they simplify creating instances of immutable classes that might otherwise have messy constructors with lots of arguments.

  • Using camera accessory, I have imported photos to my iPad 3rd generation. By mistake I have imported multiple copies of same photos. Now if I want to delete additional copies I can't. It gives me only one option "Delete everywhere" instead of delete 1copy

    Using camera accessory, I have imported photos to my iPad 3rd generation. By mistake I have imported multiple copies of same photos. Now if I want to delete additional copies I can't. It gives me only one option "Delete everywhere" instead of delete one by one, so that I can keep one copy of that photo.
    Is there a way to delete additional copies of a photo and keeping only one?

    The links below have instructions for deleting photos.
    iOS and iPod: Syncing photos using iTunes
    http://support.apple.com/kb/HT4236
    iPad Tip: How to Delete Photos from Your iPad in the Photos App
    http://ipadacademy.com/2011/08/ipad-tip-how-to-delete-photos-from-your-ipad-in-t he-photos-app
    Another Way to Quickly Delete Photos from Your iPad (Mac Only)
    http://ipadacademy.com/2011/09/another-way-to-quickly-delete-photos-from-your-ip ad-mac-only
    How to Delete Photos from iPad
    http://www.wondershare.com/apple-idevice/how-to-delete-photos-from-ipad.html
    How to: Batch Delete Photos on the iPad
    http://www.lifeisaprayer.com/blog/2010/how-batch-delete-photos-ipad
    (With iOS 5.1, use 2 fingers)
    How to Delete Photos from iCloud’s Photo Stream
    http://www.cultofmac.com/124235/how-to-delete-photos-from-iclouds-photo-stream/
     Cheers, Tom

  • Why do we use init() method instead of constructor to initialize a servlet?

    Why do we use init() method instead of constructor to initialize a servlet?

    I suspect the reasons are partly historical. A servlet is loaded dynamically, by class name and, once you've loaded the Class, it's easier to to a newInstance, using the default construtor than it is to search for a particular matching constructor and invoke it.

  • [svn:osmf:] 10996: Changing MediaElementLayoutTarget to be constructed via a static ' getInstance' method, instead of by its constructor.

    Revision: 10996
    Author:   [email protected]
    Date:     2009-10-19 07:45:26 -0700 (Mon, 19 Oct 2009)
    Log Message:
    Changing MediaElementLayoutTarget to be constructed via a static 'getInstance' method, instead of by its constructor. This prevents the construction of multiple instances that reference one single media-element. Updating client code accordingly.
    Extending layout unit tests. Adding a custom renderer, checking calculation and layout passes invokation counts.
    Modified Paths:
        osmf/trunk/framework/MediaFramework/org/osmf/composition/CompositeViewableTrait.as
        osmf/trunk/framework/MediaFramework/org/osmf/composition/ParallelViewableTrait.as
        osmf/trunk/framework/MediaFramework/org/osmf/composition/SerialViewableTrait.as
        osmf/trunk/framework/MediaFramework/org/osmf/gateways/RegionSprite.as
        osmf/trunk/framework/MediaFramework/org/osmf/layout/DefaultLayoutRenderer.as
        osmf/trunk/framework/MediaFramework/org/osmf/layout/LayoutContextSprite.as
        osmf/trunk/framework/MediaFramework/org/osmf/layout/LayoutRendererBase.as
        osmf/trunk/framework/MediaFramework/org/osmf/layout/MediaElementLayoutTarget.as
        osmf/trunk/framework/MediaFramework/org/osmf/utils/MediaFrameworkStrings.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/composition/TestParallelViewableTrai t.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/gateways/TestRegionSprite.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/layout/TestDefaultLayoutRenderer.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/layout/TestLayoutUtils.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/layout/TestMediaElementLayoutTarget. as
    Added Paths:
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/composition/CustomRenderer.as

    AlexCox, can you clarify that once you get the default model out and save it in the temp var, that your ONLY access to the data is then through temp and never through the JList methods?
    Quick question for everyone: Are any of you using JList.setListData to set you initial dataset? I think that is where the bug lies. When I do not use it and start with an empty list, I am able to add to that list, and then remove from that list using the following line:
    ((DefaultListModel)myList.getModel).remove(###);
    And this cast works everytime.
    But when I start that list out with some data such as:
    myList.setListData(myStringArray);
    and then try to execute the above line, boom! I get the ClassCast exception.
    I think setListData creates a whole new model which is an inner class to JList (which seems stupid when DefaultListModel seems made for this).
    Just my thoughts on where the problem lies. I'll add my data directly to the list and see if that works better.
    PK

  • I can't give my variable to the get method

    Hello togheter
    At the moment I work with JDOM. It is possible to get access to an XML File with JDOM, but I want to pass the String I get, to another Method in a different class. My problem is, that my getMethod doesn't get the variable. The variable is always "null". What is the problem, please help me.
    I will also give you my code:
    Here is the code for class 1, I take the String from this class. See the arrow
    package FahrplanXML;
    import java.io.File;
    import java.io.IOException;
    import javax.swing.JFileChooser;
    import javax.swing.filechooser.FileFilter;
    import org.jdom.Attribute;
    import org.jdom.Document;
    import org.jdom.Element;
    import org.jdom.JDOMException;
    import org.jdom.input.SAXBuilder;
    import org.xml.sax.InputSource;
    public class FileAuswahl {
       private File filenames;
       private String scheduledtdversion;
       public void ablauf() throws JDOMException, IOException {
          FileAuswaehlen();
          saxwer();
          grundoberflaeche xmloberflaeche = new grundoberflaeche();
          xmloberflaeche.grundoberflaechen();
       public void FileAuswaehlen() {
       JFileChooser datei = new JFileChooser();
       datei.setFileFilter(new FileFilter()
                @Override public boolean accept (File f)
                   return f.isDirectory() ||
                   f.getName().toLowerCase().endsWith(".xml");
                @Override public String getDescription()
                   return "XML-Files";
       int state = datei.showOpenDialog(null);
       if (state == JFileChooser.APPROVE_OPTION )
          filenames = datei.getSelectedFile();
          System.out.println (filenames);
          if (filenames != null)
                   try {
                      System.out.print(filenames);
                      saxwer();
                   } catch (JDOMException e) {
                      // TODO Auto-generated catch block
                      e.printStackTrace();
                   } catch (IOException e) {
                      // TODO Auto-generated catch block
                      e.printStackTrace();
          else
             System.out.println("Kein File ausgew�hlt");
       else
       System.out.println("Auswahl abgebrochen");
       System.exit(0);
       //Ausgew�hlter Dateiname an saxwer �bergeben
       public File getNames() {
          System.out.println (filenames);
          return this.filenames;
       public void saxwer() throws JDOMException, IOException {
          //FileAuswahl filename = new FileAuswahl();
          File files = getNames();
          System.out.println (files);
             SAXBuilder builder = new SAXBuilder();
             Document doc = builder.build(files);
             Element schedulemessage = doc.getRootElement();
             //Root Element auslesen
             String sch_msg_dtdversion = schedulemessage.getAttributeValue ("DtdVersion");  // <---
             scheduledtdversion = sch_msg_dtdversion;
             new grundoberflaeche().grundoberflaechen();
             public String getDtdVersion() {
                System.out.println (scheduledtdversion);
                return this.scheduledtdversion;
       } Now, you will see the class in which I pass the String. See also arrow...
    package FahrplanXML;
    import java.awt.Component;
    import java.awt.Container;
    import java.awt.GridBagConstraints;
    import java.awt.GridBagLayout;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.io.IOException;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import javax.swing.JTextField;
    import javax.swing.text.Caret;
    import org.jdom.Attribute;
    import org.jdom.JDOMException;
    public class grundoberflaeche {
    //      Layout f�r Laender vorbereiten
          static void addComponent (Container cont,
                GridBagLayout diversemoegl,
                Component laenderdetails,
                int x, int y,
                int width, int height,
                double weightx, double weighty )
                GridBagConstraints grundoberflaechen = new GridBagConstraints();
                grundoberflaechen.fill = GridBagConstraints.BOTH;
                grundoberflaechen.gridx = x; grundoberflaechen.gridy = y;
                grundoberflaechen.gridwidth = width; grundoberflaechen.gridheight = height;
                grundoberflaechen.weightx = weightx; grundoberflaechen.weighty = weighty;
                diversemoegl.setConstraints(laenderdetails, grundoberflaechen);
                cont.add(laenderdetails);
          //Ausw�hlen des XML Files
          public void XMLAuswaehlen() {
             JFrame xmlauswahl = new JFrame("Fahrplan ausw�hlen");
             xmlauswahl.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
             Container laenderdetails = xmlauswahl.getContentPane();
             GridBagLayout diversemoegl = new GridBagLayout();
             laenderdetails.setLayout(diversemoegl);
             JButton dateiauswahl = new JButton ("Datei ausw�hlen");
             addComponent(laenderdetails,diversemoegl,dateiauswahl,1,1,1,1,1,1);
             ActionListener ersterdateiauswaehler = new ActionListener()
                public void actionPerformed( ActionEvent e)
                      try {
                         new FileAuswahl().ablauf();
                      } catch (JDOMException e1) {
                         // TODO Auto-generated catch block
                         e1.printStackTrace();
                      } catch (IOException e1) {
                         // TODO Auto-generated catch block
                         e1.printStackTrace();
             dateiauswahl.addActionListener(ersterdateiauswaehler);
             xmlauswahl.setSize(150,70);
             xmlauswahl.setVisible(true);
          //Layout machen
          public void grundoberflaechen() {
             JFrame fahrplan = new JFrame("Fahrplanauswahldetails");
             fahrplan.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
             Container laenderdetails = fahrplan.getContentPane();
             GridBagLayout diversemoegl = new GridBagLayout();
             laenderdetails.setLayout(diversemoegl);
             //Klassenobjekt aufbauen
             FileAuswahl fileauswahl = new FileAuswahl();
             // Labelsbauen und einbauen in den Fahrpl�nen
             String dtdversion = fileauswahl.getDtdVersion();   // <---
             System.out.println(dtdversion);
             JTextField DtdVersion = new JTextField(1);
             DtdVersion.setText(dtdversion);
             JTextField fahrplanzeit = new JTextField(1);
             fahrplanzeit.setText("123");
             JTextField fahrplanzeita = new JTextField(1);
             fahrplanzeita.setText("piips");
             //JButton oesterreich = new JButton("�sterreich");
             //JButton italien = new JButton("Italien");
             //JButton frankreich = new JButton("Frankreich");
             //JButton spanien = new JButton("Spanien");
             addComponent(laenderdetails,diversemoegl,new JLabel("Fahrplandetails"),0,0,1,1,0,0);
             addComponent(laenderdetails,diversemoegl,DtdVersion,1,0,1,1,0,0);
             addComponent(laenderdetails,diversemoegl,fahrplanzeit,2,0,1,1,0,0);
             addComponent(laenderdetails,diversemoegl,fahrplanzeita,3,0,1,1,0,0);
             //         Action Listener f�r Dateiauswahl
             //         Action Listener f�r das Speichern der Datei
             //addComponent(laenderdetails,diversemoegl,frankreich,2,1,1,1,0,0);
             //addComponent(laenderdetails,diversemoegl,spanien,3,1,1,1,0,0);
             fahrplan.setSize(600,750);
             fahrplan.setVisible(true);
    }Thank you very much for your help....
    Your Java Learner

    Reposted here, rather than bumping up this topic:
    http://forum.java.sun.com/thread.jspa?threadID=736492

  • PopUpManager.centerPopUp gives Cannot access a property or method of a null object reference

    Hello all,
    The PopUpManager.centerPopUp(this); in my code gives out the following error:
    Main Thread (Suspended: TypeError: Error #1009: Cannot access a property or method of a null object reference.)   
        mx.managers::PopUpManagerImpl/findPopupInfoByOwner   
        mx.managers::PopUpManagerImpl/centerPopUp   
        mx.managers::PopUpManager$/centerPopUp   
        com.mycom.view::LoginView/doInit   
        com.mycom.view::LoginView/___LoginView_TitleWindow1_creationComplete   
        flash.events::EventDispatcher/dispatchEventFunction [no source]   
        flash.events::EventDispatcher/dispatchEvent [no source]   
        mx.core::UIComponent/dispatchEvent   
        mx.core::UIComponent/set initialized   
        mx.managers::LayoutManager/doPhasedInstantiation   
        Function/http://adobe.com/AS3/2006/builtin::apply [no source]   
        mx.core::UIComponent/callLaterDispatcher2   
        mx.core::UIComponent/callLaterDispatcher
    MyAppl.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"
        xmlns:view="com.mycom.view.*">
        <mx:Panel id="applPanel" height="100%" width="100%" backgroundColor="#3CACCC">
            <view:LoginView />
        </mx:Panel>
    </mx:Application>
    LoginView.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml"
        layout="absolute" width="400" height="300" creationComplete="doInit()">
        <mx:Script>
            <![CDATA[
                import mx.managers.PopUpManager;
                private function doInit():void {               
                    PopUpManager.centerPopUp(this);               
                private function login():void{
                    trace("login clicked");
            ]]>
        </mx:Script>
        <mx:Form id="loginForm" defaultButton="{loginBtn}">               
            <mx:HBox>
                <mx:Button id="loginBtn" label="OK" click="login()" />           
            </mx:HBox>
        </mx:Form>
    </mx:TitleWindow>
    Somebody please help me on this.
    Thanks.
    roshni

    Pls find your solution Below.
    MyAppl.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"
    creationComplete="onCreationComplete()">
    <mx:Script>
    <![CDATA[
    import com.mycom.view.LoginView;
    import mx.core.IFlexDisplayObject;
    import mx.managers.PopUpManager;
    private var popUp:IFlexDisplayObject;
    private function onCreationComplete():void
    popUp = PopUpManager.createPopUp(this, LoginView, true);
    popUp.move(((this.width/2)-(popUp.width/2)),(((this.height/2)-(popUp.height/2))));
    ]]>
    </mx:Script>
    <mx:Panel id="applPanel" height="100%" width="100%" backgroundColor="#3CACCC"/>
    </mx:Application>
    LoginView.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml"
    layout="absolute" width="400" height="300">
    <mx:Script>
    <![CDATA[
    import mx.managers.PopUpManager;
    private function login():void{
    trace("login clicked");
    ]]>
    </mx:Script>
    <mx:Form id="loginForm" defaultButton="{loginBtn}">
    <mx:HBox>
    <mx:Button id="loginBtn" label="OK" click="login()" />
    </mx:HBox>
    </mx:Form>
    </mx:TitleWindow>
    Pls let me know if you have any problem with this one code.
    with Regards,
    Shardul Singh Bartwal

  • How to force validator method instead of data type validation in af:table

    This post will probably once again illustrate exactly how new I am to the Java/JDeveloper world so thanks in advance for any help! I have tried searching but couldn't find anything that seemed to mirror my problem.
    I am using a modification of Frank's idea on how to individually color table cell backgrounds.
    http://thepeninsulasedge.com/frank_nimphius/2008/04/10/adf-faces-conditionally-color-table-cell-background-2/
    My intention was to use this along with custom validation to color cells with invalid values. It was a user request that it be done so as to quickly spot input errors (when updating records) if someone had missed the initial faces message and was no longer in the field that generated the error. It works fine for fields in my af:table based on VO attributes with varchar2 types but the 2 values with float and number types handle character input with a faces message "Not a number" and then do not seem to process the validator. The reason I (think I) need to use the validator in addition to Franks code is that in the validator code I use an addpartialtarget to the uicomponent that refreshes the background color if it changed in the backing bean.
    FYI the project is based on ADF BC/JSF.
    I tried gave the full use case as suggested so you understand what I am trying to accomplish and if you have a better way to accomplish this please let me know as well.
    Thanks,
    Rich
    Managed-Bean
        public String getMODELColorString() {
            MODELColorString = "width:125px;";
            Object MODEL = getRowValue("#{row.ModelType}");
            if (MODEL != null) {
                if (!isValidMODEL(MODEL.toString())) {
                    MODELColorString = "background-color:red;width:125px;";
            return MODELColorString;
        }Backing-Bean
            if (!myValidation.isValidMODEL(object.toString())) {
                System.out.println("InValid Data");
            AdfFacesContext.getCurrentInstance().addPartialTarget(uiComponent);P.S. If I made any newbie mistakes in my code please let me know, although this is obviously not production code yet by any means.
    Message was edited by:
    BengalGuy

    Frank (or anyone else who might offer some advice),
    I thought that solved my issue as I could see the validator getting triggered, however something else is now happening. It seems to pass through the validator once for each of the values on my table with the invalid input I entered on one of the numbers, "a" in this case, and then once again through the color change backing bean but at that time the invalid input reverts to the original input and the change is rendered on the af:table as well. Any thoughts ? I put a print in the validator method, in the method that gets called from the validator (checks to see if value can be converted to float) , and then the color change bean (which also calls the float validation test) and pasted the output below.
    Validator Triggered \Current Value = 0.037178375 \FloatTestOn: 0.037178375 \Result: Valid Data
    Validator Triggered \Current Value = 0.109212324 \FloatTestOn: 0.109212324 \Result: Valid Data
    Validator Triggered \Current Value = 0.18624917 \FloatTestOn: 0.18624917 \Result: Valid Data
    Validator Triggered \Current Value = 0.26863635 \FloatTestOn: 0.26863635 \Result: Valid Data
    Validator Triggered \Current Value = 0.35674548 \FloatTestOn: 0.35674548 \Result: Valid Data
    Validator Triggered \Current Value = -0.38118127 \FloatTestOn: -0.38118127 \Result: Valid Data
    Validator Triggered \Current Value = -0.3382032a \FloatTestOn: -0.3382032a NumberFormatException: For input string: "-0.3382032a"
    08/04/16 10:03:14 \Result: InValid Data
    Validator Triggered \Current Value = -0.29224017 \FloatTestOn: -0.29224017 \Result: Valid Data
    Validator Triggered \Current Value = -0.24308495 \FloatTestOn: -0.24308495 \Result: Valid Data
    Validator Triggered \Current Value = -0.1905158 \FloatTestOn: -0.1905158 \Result: Valid Data
    Validator Triggered \Current Value = -0.13429564 \FloatTestOn: -0.13429564 \Result: Valid Data
    Validator Triggered \Current Value = -0.07417088 \FloatTestOn: -0.07417088 \Result: Valid Data
    Validator Triggered \Current Value = -0.009870344 \FloatTestOn: -0.009870344 \Result: Valid Data
    \Checking for color change \FloatTestOn: 0.037178375
    \Checking for color change \FloatTestOn: 0.109212324
    \Checking for color change \FloatTestOn: 0.18624917
    \Checking for color change \FloatTestOn: 0.26863635
    \Checking for color change \FloatTestOn: 0.35674548
    \Checking for color change \FloatTestOn: -0.38118127
    \Checking for color change \FloatTestOn: -0.3382032 <- "a" is no longer there ?
    \Checking for color change \FloatTestOn: -0.29224017
    \Checking for color change \FloatTestOn: -0.24308495
    \Checking for color change \FloatTestOn: -0.1905158
    \Checking for color change \FloatTestOn: -0.13429564
    \Checking for color change \FloatTestOn: -0.07417088
    \Checking for color change \FloatTestOn: -0.009870344

  • Use SAP defined methods instead of Logical Database(LDB)

    Hi All,
    I gonethrough some documents related to new HR ABAP programing without using logical database.  we can replace the logical databased with SAP defined methods for all the infotypes.  Appreciate if anyone let me know how do this.
    Thanks in advance.
    Thanks,
    -suresh

    Yes.. we can use the Infotype reader class.. you can use the following sample code & go from there.. fyi I wrote this on a 47 system..
    *& Report  ZP_INF_CL                                                   *
    *&  read an infotype using ABAP Objects                                *
    report  zp_inf_cl line-size 1000.
    infotypes: 0001,0008.
    parameters: p_infty type infty,
                p_pernr type pernr_d.
    constants: c_a type tclas value 'A',
               c_true value 'X'.
    data: w_infotype_reader type ref to if_hrpa_read_infotype,
          t_inftab type hrpad_prelp_tab,
          w_missing_auth type boole_d,
          w_data_exists  type boole_d,
          rec_infty like line of t_inftab.
    * init infotype reader
    call method cl_hrpa_read_infotype=>get_instance
      importing
        infotype_reader = w_infotype_reader.
    call method w_infotype_reader->read
      exporting
        tclas         = c_a
        pernr         = p_pernr
        infty         = p_infty
        begda         = sy-datum
        endda         = sy-datum
        no_auth_check = c_true
      importing
        infotype_tab  = t_inftab
        data_exists   = w_data_exists
        missing_auth  = w_missing_auth.
    loop at t_inftab into rec_infty.
      call method cl_hr_pnnnn_type_cast=>prelp_to_pnnnn
        exporting
          prelp = rec_infty
        importing
          pnnnn = p0001.
      append p0001.
    endloop.
    loop at p0001.
      write:/ p0001-orgeh.
    endloop.
    ~Suresh

  • Use Action to call JSP method instead for forwarding to another url

    I have a servlet button to save data I have entered on a form. The only way I understand to save the data when the button is pressed is to use ACTION and call up a .jsp to do the work like this:
    <FORM ACTION="http://localhost:8080/examples/jsp/learningJSP/UpdateStudentInfo.jsp" METHOD="POST">
    and here's the .jsp that sets my current properties from the form and saves them.
    <HTML>
    <BODY>
    <jsp:useBean id="studentDataBean"
         class="learningservlets.StudentDataBean"
         scope ="application"/>
    <jsp:setProperty name="studentDataBean" property ="*" />
    <!--call saveData() to send the data you just set - to the database%=stuInfo.saveData()%>-->
    <%studentDataBean.saveData();%>
    <jsp:forward page="PresentStudentData.jsp" />
    <H1>
    UpdateStudentInfo Bean
    </H1>
    </BODY>
    </HTML>
    The problem I have with using this approach is my user is sent to another page. Is there anyway to complete the above task transparently (i.e. without making the user go to the page that does all of the work)?
    Thanks for any assistance you may offer.

    Use this,
    UpdateStudentInfo.jsp
    <%@ page import="learningservlets.StudentDataBean" %>
    <jsp:useBean id="studentDataBean"
    class="learningservlets.StudentDataBean"
    scope ="application">
    <jsp:setProperty name="studentDataBean" property ="*" />
    </jsp:useBean>
    <!--call saveData() to send the data you just set - to the
    database%=stuInfo.saveData()%>-->
    <%
    studentDataBean.saveData();
    response.sendRedirect("PresentStudentData.jsp");
    return;
    %>
    Hope this helps.
    Sudha

  • FM or Method instead of transaction se78

    Hello folks,
    does anyone knows, if there is a function module or method to upload und store a picture (bmp or tif) instead of calling transaction se78 directly?
    I want to run the logic in background task, so I am not able to use the workstation processes by using gui_upload for example. The graphic will be used in smart forms.
    Has anybody a clue?
    Thank's in advance

    Hello Nag,
    yes, storage happened on application server. But I found a hint in scn:
    perform import_bitmap_bds
                      in program saplstxbitmaps
                                using  filename
                                       name
                                       'GRAPHICS'    "Object
                                       'BMAP'       "ID
                                       'BMON'       "B/W
                                       'BMP'       "Extension
                                       title
                                       space
                                       'X'
                                changing l_docid
                                         l_resolution.
    GUI_UPLOAD is included in the form-routine. I will copy the code and change guy_upload by open dataset ... . I let you know, if it works in background.
    Regards
    Andreas

  • Which method instead of getCustomDatum?

    in the sample application the method rs.getCustomDatum is used, this method is deprecated, isn't it?
    which method can i use instead?
    where can i find the documentation of the Java Class OracleResultSet?

    Please ignore this error for interMedia. This is the supported method for interMedia at this time.
    Larry

  • HRPAD00INFTYBL -- Edit button on ESS invokes INSERT method instead of MODIF

    Hi Guys,
    In the BADI HRPAD00INFTYBL, when an ESS user clicks on Edit work address, the INSERT method is invoked instead of the MODIFY method.
    Has anyone encountered this problem and is there any resolution of this?
    Regards,
    Mark

    Hi,
    does it mean that in new BP drop-down triggers an event?
    Regards,
    Lukasz

Maybe you are looking for

  • Latest patch cluster idated march 14 nstalled on solaris10

    I installed the latest patch cluster on my solaris10 system and afterwards the Solaris Management console would not work. I kept getting the error that the server was not running. I followed the limited trouble-shooting guidelines for stopping and st

  • Cisco 7940 phone - lock out handset

    Hi, is it possible to lock out the handset, we use IPPC Enterprise and want to stop our call centre agents from using the handset for making calls. Instead we want to force them, to use the dialing function in the CTI OS application, with the result

  • Why won't my apostrophe display?

    I created a pdf export in InDesign (CS4) and opened it up in Adobe Acrobat Pro to make a form and the apostrophe disappeared.  When I open the same pdf in Preview it's still there.  I went back and embedded the entire font (it's Helvetica) and still

  • Duet Enterprise trainig / certification

    Hello , is there any certification or partnership program or training material  on Duet Enterprise Thanks

  • Time Machine help - Can't find my stuff after restore

    I've backed up from Time Machine but can't find of my stuff. all applications are bare, no vid/pics etc. My macintosh hd stoage is showing mainly as 'other'. Can anyone help me get my computer back please?!