How to use the forums and get (helpful) help!

Please, I beg you, read the Javadoc on the class you are asking about:
http://java.sun.com/j2se/1.4/docs/api/index.html
Have you looked for an answer in Suns training documentation, tutorials and Java specification?
http://developer.java.sun.com/developer/infodocs/
Post your code so that it is readable:
http://forum.java.sun.com/faq.jsp#messageformat
Of course, is everyone followed these rules (including me) these forums would probably be a very lonely place ;)

You either use single quotes in the SQL string, or (my preferred method) use a Prepared Statement
String sql = "select count(cc.id) from customers c, creditcards cc where c.cc_id = '" + ccID+ "' ";
// or better IMO
sql = "select count(cc.id) from customers c, creditcards cc where c.cc_id = ?");
PreparedStatement pstmt = con.prepareStatement(sql);
sql.setString(1, ccID);The prepared statement protects you agains SQL injection attacks, and any values that would need escaping in SQL. What would happen if someone entered a single quote in the ccID field?

Similar Messages

  • Gantt chart: Don't know how to use the tooltipkeys and toolkeylabel

    I have a problem. Don't know how to use the tooltipkeys and toolkeylabel. I used jquery to select the gantt bars and on mouse over i was getting the task id "tid" then passing it to adf bean with serverlistener and showing a popup that is adf component with javascript. For positioning of the popup I used a button that has width and height 0 and has position absolute and gets the coordinates of the mouse.
    "div[et]" is a jquery selector that selects all the elements that have attribute et. I noticed that all the bars have that attribute as a few other attributes as well "part"...
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
            xmlns:dvt="http://xmlns.oracle.com/dss/adf/faces">
        <af:document title="untitled1.jsf" id="d1">
            <af:resource type="javascript" source="https://ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js"/>
            <af:resource type="javascript" source="resources/js/home.js"/>
            <af:messages id="m1"/>
            <af:form id="f1">
               <af:commandButton text="commandButton 1" id="cb1" inlineStyle="visibility:hidden; width:0; height:0" />
                <af:popup id="noteWindow" contentDelivery="lazyUncached" binding="#{homeBean.popup}">
                    <af:noteWindow id="popupWindow">
                        <af:panelFormLayout id="pfl2">
                            <af:panelLabelAndMessage label="Task id" id="plam5">
                                <af:outputText value="#{homeBean.taskId1}" id="ot64"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="Start Location Name" id="plam6">
                                <af:outputText value="#{homeBean.startLocation}" id="ot7"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="Stop Location Name" id="plam7">
                                <af:outputText value="#{homeBean.stopLocation}" id="ot8"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="tasktype" id="pla2m7">
                                <af:outputText value="#{homeBean.taskType}" id="ot9"/>
                            </af:panelLabelAndMessage>
                        </af:panelFormLayout>
                    </af:noteWindow>
                </af:popup>
                <af:serverListener type="jsServerListener" method="#{homeBean.serverEventHandler}"/>
                <dvt:schedulingGantt id="gantt1" value="#{bindings.PersonView1.schedulingGanttModel}" var="row"
                                     startTime="2011-07-04 00:00:00" endTime="2011-07-04 23:00:00" summary="gsg"
                                     showMenuBar="false" showToolbar="false" iconPlacement="left"
                                     showTasksAsDailyBar="false">
                    <f:facet name="major">
                        <dvt:timeAxis scale="days" id="ta1"/>
                    </f:facet>
                    <f:facet name="minor">
                        <dvt:timeAxis scale="hours" id="ta2"/>
                    </f:facet>
                    <f:facet name="nodeStamp">
                        <af:column sortProperty="#{bindings.PersonView1.hints.PersonId.name}" sortable="false"
                                   headerText="#{bindings.PersonView1.hints.PersonId.label}" id="c1">
                            <af:outputText value="#{row.PersonId}" id="ot1">
                                <af:convertNumber groupingUsed="false"
                                                  pattern="#{bindings.PersonView1.hints.PersonId.format}"/>
                            </af:outputText>
                        </af:column>
                    </f:facet>
                </dvt:schedulingGantt>            
            </af:form>
        </af:document>
    </f:view>javascript:
    $(document).ready(bindEvents());
    function bindEvents() {
        $("div[et]").live('mouseover', function (e) {
             $('#cb1').css("position", 'absolute');
             $('#cb1').css("top", e.pageY-4);
             $('#cb1').css("left", e.pageX);
            var popup = AdfPage.PAGE.findComponentByAbsoluteId("noteWindow");
            var element = AdfPage.PAGE.findComponent("f1");
            var taskIdToPass = null;
            if ($(this).attr("tid") !=undefined) {
                 taskIdToPass = $(this).attr('tid').toString();
            } else {
                taskIdToPass = $(this).parent().attr('tid').toString();
            var param = {            taskId : taskIdToPass        };
            AdfCustomEvent.queue(element, "jsServerListener", param, true);
            if (!popup.isPopupVisible()) {
                var hints = {};
                hints[AdfRichPopup.HINT_LAUNCH_ID] = "cb1";
                hints[AdfRichPopup.HINT_ALIGN_ID] =  "cb1";
                hints[AdfRichPopup.HINT_ALIGN] = AdfRichPopup.ALIGN_AFTER_START;
                popup.show(hints);
        }).live("mouseout", function () {
            var popup = AdfPage.PAGE.findComponentByAbsoluteId("noteWindow");
            popup.hide();
    };My bean that is session bean:
    package view;
    import oracle.adf.model.BindingContext;
    import oracle.adf.model.binding.DCDataControl;
    import oracle.adf.view.rich.component.rich.RichPopup;
    import oracle.adf.view.rich.render.ClientEvent;
    import oracle.jbo.ApplicationModule;
    import oracle.jbo.Key;
    import oracle.jbo.Row;
    import oracle.jbo.RowSetIterator;
    import oracle.jbo.ViewObject;
    public class HomeBean {
        private RichPopup popup;
        private String taskId1;
        private String startLocation;
        private String stopLocation;
        private long taskId;
        private String taskType;
        public HomeBean() {
            super();
        public void serverEventHandler(ClientEvent clientEvent) {    
            String taskIdString = clientEvent.getParameters().get("taskId").toString();
            this.taskId = Long.parseLong(taskIdString);
            DCDataControl dc1 = BindingContext.getCurrent().findDataControl("AppModuleDataControl");
            ApplicationModule am = dc1.getApplicationModule();
            ViewObject vo = am.findViewObject("PdTrfDayView1");  
            RowSetIterator rowSetIterator = vo.createRowSetIterator(null);
            Row[] rows = rowSetIterator.findByKey(new Key(new Object[] {taskId}), 1);
            Row row = rows[0];
           this.taskId1 =  row.getAttribute("PdTrfDayId").toString();
           this.startLocation = row.getAttribute("StartLocation").toString();
           this.stopLocation = row.getAttribute("StopLocation").toString();
           this.taskType = row.getAttribute ("PdTrfTypeId").toString();
            RichPopup.PopupHints ph = new RichPopup.PopupHints();
            vo.closeRowSetIterator();
        public long getTaskId() {
            return taskId;
        public void setPopup(RichPopup popup) {
            this.popup = popup;
        public RichPopup getPopup() {
            return popup;
        public String getTaskId1() {
            return taskId1;
        public String getStartLocation() {
            return startLocation;
        public String getStopLocation() {
            return stopLocation;
        public String getTaskType() {
            return taskType;
    }I am wondering If i can use setCurrentRow on the iterator that i create and use it for displaying on the popup instead of binding startLocation and stopLocation to the bean and if there is any benefit of that at all...
    Edited by: 897833 on Nov 24, 2011 11:37 AM

    Hi,
    To use tooltipkeys and tooltiplabel in gantt, you can add following code in managed bean
    public String[] getTooltipKeys()
    return new String[]{"columnA", "columnB", "StartDate", "EndDate"};
    public String[] getTooltipLabels()
    return new String[]{"A", "B", "Start Date", "End Date"};
    where , the string array in the ToolTipKeys represents the columns, of the table you have in the gantt component , and the string array in TooltipLabels displays the label you want to display for the table columns.
    In the jsff, you could call the bean methods as follows:
    tooltipKeys="#{GanttBean.tooltipKeys}"
    tooltipKeyLabels="#{GanttBean.tooltipLabels}"

  • How to use the eventing and databag with a WAS 6.20 ?

    How to use the eventing and databag with a WAS 6.20 ?
    Is what there is a good guide for these services?
    Thank's

    In the raise event you can pass the value
    like below.
    <SCRIPT>
    function raiseEvt(value1){
    if(window.document.domain == window.location.hostname){
    if ( document.domain.indexOf(".") > 0 ) document.domain = document.domain.substr(document.domain.indexOf(".")+1);
       EPCMPROXY.raiseEvent( "urn:com.sap:BWEvents","BWiViewevent", value1, null );
      // alert('tree domain'+document.domain);
    </SCRIPT>
    and in the
    subscribe event you can get the values like below.
    <script language="javascript">
    if(window.document.domain == window.location.hostname){
    document.domain = document.domain.substring(document.domain.indexOf('.')+1);
        EPCMPROXY.subscribeEvent("urn:com.sap:BWEvents","BWiViewevent", window, "myreceiveEvent");
    function myreceiveEvent( eventObj ) {
          document.forms[0].gp_hidden.value = eventObj.dataObject;
    </script>
    Also look at the following link for a complete documentation.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/Enterprise%20Portal%20Client.pdf
    Regards
    Raja

  • How to use the validations and exceptions  in BPEL

    Hi,
    How to use the validations and exceptions in BPEL.
    pls provide one sample example to give the exceptions and validations in BPEL

    Hi,
    For example you can create a simple BPEL Process and you can throw an error during running process. If input data is not valid and format is not correct you can throw error using throw activity and using catch activity you can catch particular error. The catch-all will handle all the error occurred with the scope.
    you can also refer faulthandling section in the link for more information related to exception handling.
    http://download-west.oracle.com/docs/cd/B31017_01/integrate.1013/b28981/faults.htm#sthref1188
    Regards,
    Deepa

  • Learn how to use the Forum

    Welcome to the HP Support Forum!
    This forum is a great place to get your questions answered as well as learn how to get the most out of your HP products. If this is your first time in our community, you have come to the right place to learn how the Forum works.
    Let’s begin with the basic structure of the Forum. The forum is divided into Categories, as in the screenshot below, so that you can easily choose an area relevant to your query.
    Each of these Categories, are further divided into Boards, based on specific type of issues or queries. For example, if you click on the + sign beside the Laptop & Notebook Computers category, it will expand and show its boards as below:
    You can just go right into any of the boards, search for a particular issue or create your own post.
    However, if you have used the Search the Community box at the Forum home page, you will be on the Search Results page, where you can create a post directly.
    In this case, you will have to choose a board, while you are creating a post, from the Select Location drop-down menu.
    Before you delve deeper into this board to find more information about how the Forum works, here are a few things to keep in mind.
    Before you create a post, to get the quickest, most accurate response from the community, please include the following in your post:
    A brief Subject title including:
    Product Name
    A short description of the problem
    A detailed message with the following information:
    Product Name and Operating System
    How do I find my product name and number?
    Description of the problem including:
    Error messages, if any
    Any changes made to your system before the issue occurred
    Do not include the product serial number or any private information.
    Read more in here: Advice for Asking the Very Best Question
    You may also be interested in some short videos that show:
    How to search the forum to find the answers you are looking for;
    How to join it so that you will be able to ask a question; and
    How to make post and where to post it to get a timely response. 
    You don’t have to be a member to search for answers. However, you will need to register if you want to post a question.
    There is a lot of information in this board that may help you get the most out of your time on the Forum. You can click here to go back to the main Forum page.
    Should you have any suggestions or feedback on the site feel free to add comments in the Forum Feedback and Suggestions board. 
    We look forward to hearing from you.
    HP Forums Team
    Want to help? Become an Expert!
    I am an HP employee.

    Welcome to the HP Support Forum!
    This forum is a great place to get your questions answered as well as learn how to get the most out of your HP products. If this is your first time in our community, you have come to the right place to learn how the Forum works.
    Let’s begin with the basic structure of the Forum. The forum is divided into Categories, as in the screenshot below, so that you can easily choose an area relevant to your query.
    Each of these Categories, are further divided into Boards, based on specific type of issues or queries. For example, if you click on the + sign beside the Laptop & Notebook Computers category, it will expand and show its boards as below:
    You can just go right into any of the boards, search for a particular issue or create your own post.
    However, if you have used the Search the Community box at the Forum home page, you will be on the Search Results page, where you can create a post directly.
    In this case, you will have to choose a board, while you are creating a post, from the Select Location drop-down menu.
    Before you delve deeper into this board to find more information about how the Forum works, here are a few things to keep in mind.
    Before you create a post, to get the quickest, most accurate response from the community, please include the following in your post:
    A brief Subject title including:
    Product Name
    A short description of the problem
    A detailed message with the following information:
    Product Name and Operating System
    How do I find my product name and number?
    Description of the problem including:
    Error messages, if any
    Any changes made to your system before the issue occurred
    Do not include the product serial number or any private information.
    Read more in here: Advice for Asking the Very Best Question
    You may also be interested in some short videos that show:
    How to search the forum to find the answers you are looking for;
    How to join it so that you will be able to ask a question; and
    How to make post and where to post it to get a timely response. 
    You don’t have to be a member to search for answers. However, you will need to register if you want to post a question.
    There is a lot of information in this board that may help you get the most out of your time on the Forum. You can click here to go back to the main Forum page.
    Should you have any suggestions or feedback on the site feel free to add comments in the Forum Feedback and Suggestions board. 
    We look forward to hearing from you.
    HP Forums Team
    Want to help? Become an Expert!
    I am an HP employee.

  • How to use the user and role API's and where to use it

    Hi All,
    I have configured SSO for my UCM11g. Now my application authenticates through the Oracle SSO login page. Currently it is working with SQL authenticator.
    Now, i have to use LDAP authenticator. when i will configure the LDAP authenticator, i have to use the user and role API's to fetch the user profile information from LDAP. i have got the API's which will be used to fetch the respected information, but i am not getting as where i will write those java programs and how this API will be used in my application. what settings i need to do on it so that application uses the API's. ?
    Please can anyone help me on this.
    thanks,
    Saurabh

    Hi, Mithu,
    Thanks a lot for your help in advance.
    I have carefully read the document: https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/6b66d7ea-0c01-0010-14af-b3ee523210b5.
    Now, I think I have to set the processor of every actions in every process if I use the GP for processing the workflow.
    I am better to hope that I can set the processor to the role for every actions in every process in the runtime through get the organizational structure in the WDA(webdynpro for java or webdynpro for java). Thus, the customer don't set the processor to the role for every action in every process when runing in the GP.   I don't know how to do this. 
    Whether the function is not supported in the GP? If so, I have to config two organizational structure: in the R/3 and in the Portal. I don't think our customer don't receipt this solution.
    Do you give me some hints? Thanks a lot.  My email: [email protected]
    Thanks again.
    Thanks & Regards,
    Tao

  • How to use the rescue and recovery, and the product recovery discs ?

    Hi everyone,
    I've just recently became a new owner of a T61, and really enjoying it. I haven't had a chance yet to test-drive the lenovo phone support, as I have not yet screwed anything up that bad that required their help. I did try a clean factory reinstall from the service partition and it worked great. I would like to find out, how does one use the rescue and recovery startup disc, and the product recovery discs that I created myself? From my previous experience with Dell and HP, I only had to insert the first one and restart the computer, and the rest followed. But with ThinkPads, if I ever wanted to bring it to a clean factory state using those discs, do I use rescue and recovery first, followed by the product recovery? I'm curious, what is the difference between the two? 
    T61 (7658CTO), T9300, 3GB, 250GB, XP Pro
    Solved!
    Go to Solution.

    blake_ibm wrote:
    Hi! I'm blake
    There is no diff between the two... One is on  the Hard Drive and the other on CD/DVD.
    Having the HDD version (pre-installed) is a good for trouble shooting.  It uses a whole diff O/S on a whole diff partition (not C.
    So if you are having problems and boot to RnR (via F11), and those problems go away. you know your issue is software related. If you still have the same problems probly Hardware related...  IT IS AN EFFECTIVE WAY TO TAKE WINDOWS OUT OF THE PROBLEM.
    Other then that. You can re-image another HDD from disks, you can't do that with the F11 version.
    dose all that make sense?
    Hi blake_ibm,
    Thanks. All this makes perfect sense to me, but that's not what I'm asking for. My question is this: if I wanted to bring my notebook to its factory shipped condition using my recovery cd's, how do I do that? Do I insert cd1 first and then restart the notebook, or do I just insert it without restarting it, or perhaps I should use first the rescue and recovery?
    You said that there is no difference between the two, but what two are you talking about man? I am not comparing cd recovery to partition recovery. I am talking about rescue and recovery cd, with system recovery cd's. These are the two things that I'm talking about.
    I'm really grateful for all replies, but please people, read the question first !!!
    I would really appreciate if someone could explain the steps involved in performing a clean factory recovery, using the cd's, and not the recovery partition. I just want to know for the future, in case one day I have to do it. That is all I'm asking.
    T61 (7658CTO), T9300, 3GB, 250GB, XP Pro

  • How to use Hide Tech. and Get cursor field

    Hai Experts,
    Can any one tell me about
    how and when we use hide tech. and get cursor stmt in interactive report.
    In my reqirement , i want to display PO header details like PO docno, Vendor No, and so on. when i am double clicking the EBELN , it will display the item details of the particular document number which i am clicked in the basic list.
    if i am double click the vendor number, it will show the vendor details.
    how can i get this?
    Thanks in advance  for ur reply.
    Regards,
    Msivasamy

    Thanks for ur reply.
    I got the output in this way.
    *& Report  SAPMZMMPO
    REPORT  SAPMZMMPO no standard page heading.
    tables: ekko.
    DATA: f(40) TYPE c, off TYPE i, lin TYPE i, val(10) TYPE c, len TYPE i.
    data: begin of iekko occurs 0,
            bukrs like ekko-bukrs,
            bsart like ekko-bsart,
            ekorg like ekko-ekorg,
            ekgrp like ekko-ekgrp,
            ebeln like ekko-ebeln,
            lifnr like ekko-lifnr,
            bedat like ekko-bedat,
          end of iekko.
    data: begin of iekpo occurs 0,
            ebeln like ekko-ebeln,
            ebelp like ekpo-ebelp,
            matnr like ekpo-matnr,
            menge like ekpo-menge,
            meins like ekpo-meins,
            netpr like ekpo-netpr,
            matkl like ekpo-matkl,
            werks like ekpo-werks,
            lgort like ekpo-lgort,
            eeind like rm06e-eeind,
          end of iekpo.
    data: begin of ilfa1 occurs 0,
            lifnr like lfa1-lifnr,
            name1 like lfa1-name1,
            stras like lfa1-stras,
            ort01 like lfa1-ort01,
          end of ilfa1.
    *parameters: p_ebeln like ekko-ebeln default '4500006130'.
    select-options: s_ebeln for ekko-ebeln DEFAULT '4500006130' TO '4500006135'
                     OPTION bt SIGN i.
    *start-of-selection.
    start-of-selection.
    select bukrs bsart ekorg ekgrp ebeln lifnr bedat
            from ekko into corresponding fields of table iekko
            where ebeln in s_ebeln.
    loop at iekko.
            write:/ iekko-ebeln HOTSPOT COLOR 5 INVERSE ON,
                    iekko-lifnr HOTSPOT COLOR 3 INVERSE ON ,
                    iekko-bukrs,iekko-bsart,iekko-ekorg,iekko-ekgrp.
            hide: iekko-ebeln,iekko-lifnr.
    endloop.
    iekko-lifnr,iekko-ebeln.
    at line-selection.
      GET CURSOR FIELD f VALUE val .
    WRITE: / 'Field: ', f,
            / 'Offset:', off,
            / 'Line:  ', lin,
            / 'Value: ', (10) val,
            / 'Length:', len.
    case sy-lsind.
    when 1.
    *if val = iekko-ebeln.
    if f = 'IEKKO-EBELN'.
            select  ebeln ebelp menge meins lgort werks
                    matnr matkl netpr from ekpo
                    into corresponding fields of table iekpo
                    where ebeln = iekko-ebeln.
                   for all entries in iekko where ebeln = iekko-ebeln.
            loop at iekpo.
                write:/ iekpo-ebelp,iekpo-matnr,iekpo-menge,iekpo-meins,
                        iekpo-werks,iekpo-lgort,iekpo-matkl,iekpo-netpr.
            endloop.
    endif.
    *if val = iekko-lifnr.
    if f = 'IEKKO-LIFNR'.
            select lifnr name1 stras ort01 from lfa1
                    into corresponding fields of table ilfa1
                    where lifnr = iekko-lifnr.
            loop at ilfa1.
                write:/ ilfa1-lifnr,ilfa1-name1,ilfa1-stras,ilfa1-ort01.
            endloop.
    endif.
    when others.
          leave screen.
    endcase.

  • How to use the "GEN_KEY" and "FROM_KEY" of RFC_GET_TABLE_ENTRIES

    Hi there,
    I am using JCO java connector in my own client application to talk to SAP. I need to use RFC_GET_TABLE_ENTRIES to read table entries.
    Just wondering if anyone knows how to use GEN_KEY and FROM_KEY of this function to narrow the table read as it currently returns all the entries in the table. Could someone provide the exact syntax of the data that I need to pass to these two parameters please?
    Your help is much appreciated!

    Thanks for your reply.
    I am using this table "USRSYSACTT". It is keyed on "MANDT", "SUBSYSTEM", "LANGU" and "AGR_NAME". When I want to only get the entry where the SUBSYSTEM = "SUB123", LANGU="E" and AGR_NAME="Role Name", I passed GEN_KEY="SUB123    ERole Name                     ". It did not work for me. It seems that only the "SUBSYSTEM" field has some effect. It returns all the entries with the correct subsystem. But the LANGU and AGR_NAME do not seem to have any effect.
    Any idea what I have done wrong.
    Thanks again

  • How to write the data and get back from NI-9802 installed in cRIO 9081

    Hello,
             I am working on cRIO 9081, with NI-9467 GPS module and NI-9234 Acoustic module. I have generated the data from GPS as well as 9234 module.
    Now I want to write this data in NI-9802, this means i required 2 FPGA vi in one project, and to dumb them in main RT vi.
    So how can we do it ,please suggest me any solution...

    You can use webutil functions.
    There are many posts in the forum... search for them!!
    hope it helps you,
    Fabrizio
    If this answer is helpful or correct, please mark it. Thanks.

  • How to use the MouseAdapter and mouseEntered

    I've made panel(Jpanel) with a Label(Jlabel) wich contains an Image).
    but i want the image changes in another Image when the mouse passesover the image, without click the mouse?
    how can i get this, if i can?
    some told use the MouseAdapter anf the mouseEntered, but how
    here is the program
    public class Panel1 extends JPanel
    JLabel ImageLabel,ImageLabel3;
    ImageIcon imatge1,imatge2,imatge;
    boolean asig;
    int Ymove,Xmove;
    public Panel1()
                   imatge1 = new ImageIcon("c:/Applet/imatges/lupa.gif");
         imatge2 = new ImageIcon("c:/Applet/imatges/not.gif");
              ImageLabel = new JLabel (imatge1);
              ImageLabel.setBackground(new Color(255,219,183));
    ImageLabel.setForeground(new Color(255,219,183));
    ImageLabel.setOpaque(true);
    add(ImageLabel);
    //Add a MouseAdapter to the Jlabel and change the image in the mouseEntered method of the adapter.

    Here a simple example:
    import java.awt.*;
    import java.awt.event.*;
    class MAdapter extends Frame
         private Button b1, b2, b3;
         public MAdapter()
              addWindowListener(new WindowAdapter()
                   public void windowClosing(WindowEvent e)
                        dispose();
                        System.exit(0);
              setLayout(new GridLayout(3, 1, 10, 10));
              b1 = new Button("Button 1");
              b2 = new Button("Button 2");
              b3 = new Button("Button 3");
              MouseListener mListener = new MMListener();
              b1.addMouseListener(mListener);
              b2.addMouseListener(mListener);
              b3.addMouseListener(mListener);
              add(b1); add(b2); add(b3);
         class MMListener extends MouseAdapter
              public void mouseEntered(MouseEvent e)
                   Object o = e.getSource();
                   if (o == b1)
                        b1.setBackground(Color.yellow);
                   else if (o == b2)
                        b2.setBackground(Color.yellow);
                   else
                        b3.setBackground(Color.yellow);
              public void mouseExited(MouseEvent e)
                   Object o = e.getSource();
                   if (o == b1)
                        b1.setBackground(Color.LIGHT_GRAY);
                   else if (o == b2)
                        b2.setBackground(Color.LIGHT_GRAY);
                   else
                        b3.setBackground(Color.LIGHT_GRAY);
         public static void main(String args[])
              MAdapter mainFrame = new MAdapter();
              mainFrame.setSize(400, 200);
              mainFrame.setTitle("MAdapter");
              mainFrame.setBackground(Color.LIGHT_GRAY);
              mainFrame.setVisible(true);

  • How to use the userid and password infor from Oracle DB in BO

    Out client has the userid and passwords(encrypted) infomration stored in oracle table.
    Is it possible to import this useid and password information into BO .And use the same userid and password from Oracle table for its login authentication and for data security...?
    In other words can the userid/pwd info from Oracle Profile Table imported and re-used in BO Enterprise Edition.

    If the users/pw are in an Oracle LDAP v3 compliant server then you can import them via LDAP plugin, else you would need to bring them in an enterprise users via script. The Import wizard can do this and the SDK (see the SDK forums for more info on how)
    Maintaining the passwords would be difficult unless you are using and industry standard directory like LDAP.
    Regards,
    Tim

  • How to use the mirrored and log shipped secondary database for update or insert operations

    Hi,
    I am doing a DR Test where I need to test the mirrored and log shipped secondary database but without stopping the mirroring or log shipping procedures. Is there a way to get the data out of mirrored and log shipped database to another database for update
    or insert operations?
    Database snapshot can be used only for mirrored database but updates cannot be done. Also the secondary database of log shipping cannot used for database snapshot. Any ideas of how this can be implemented?
    Thanks,
    Preetha

    Hmm in this case I think you need Merge Replication otherwise it breaks down the purpose of DR...again in that case.. 
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • How to Check the date and get the latest date?

    Hi Everyone,
    I've an internal table which holding few records which contain date field. How I can check this internal table by getting the record which contain "latest date" only? Kindly advise. Thank you.
    eg:
    I should only get the record which contain lastest date. (eg: I should picked up Record3)
    Table i_test
    Field 1              Field 2(date)
    Record1            20090322
    Record2            20090101
    Record3            20090601
    Moderator message - Please search before asking and do not ask basic questions - post locked
    Edited by: Rob Burbank on Jun 17, 2009 9:21 AM

    Its easy...sort the internal table using the field i.e. date field in DESCENDING manner
    SORT gt_final BY date_field DESCENDING.
    Read the first entry of the internal table..it will have what you require
    READ gt_final INDEX 1.

  • N8 Photo Editing - how to use the cut and paste?

    Hello,
    I am trying to edit some photos - there is a an option to use an ellipse or magic wand.  I thought that was to cut and paste from the photos.
    All I can do is select and area - but how do I cut it. 
    I tried save, but it saves the whole image...
    Or am I just doing this wrong...
    Thanks,
    VeePee
    Nokia 3395
    Nokia 6600
    Nokia N95 8GB
    Nokia N8 (Anna)
    Nokia Lumia 930

    I was hoping to use the ellipse or magic want to cut and paste items in a certain shape to paste on other photos.
    I could do this on my N95-4.
    So there is no way to photo edit with cut and paste?
    Any idea what the ellipse and magic wand function do, and how do they work?
    Thanks,
    VeePee
    Nokia 3395
    Nokia 6600
    Nokia N95 8GB
    Nokia N8 (Anna)
    Nokia Lumia 930

Maybe you are looking for

  • Xp doesn't recognize ipod touch

    Itunes shows the Itouch and when you sync, the Ipod lights up, but nothing is copied over.  The Itouch doesn't show up in device manager or computer.  I can not download anything.  it says no updates! 

  • About user mapping

    hello every one i have a question that is.... we configuration users mapping between SAP portal and R/3 System. in this case, we know the user's IDs are "one to one" relationship. but some times, we have to integrate the more external system such as

  • Dual layer DVD discs

    I have a few backup discs burned dual layer in OSX with archive material - they read just fine in OSX. When I boot into XP via Bootcamp, the discs are not read and are ejected. Anyone come across this or got a suggested set of drivers for the DVD dri

  • Windows SMTP service - restrictions

    Hi I have installed a SMTP service under IIS 6.0 in windows 2008 R2 I would like to know if is possible to restrict the SMPT traffic to specific domains Example: i only want that only relay traffic to google.com Thanks in advance.

  • Group Call log

    Hi guys,  I need to keep a log of business calls I'm doing on skype in terms of time spent/duration but although I get a basic call duration (mostly) on individual contact calls, it doesn't seem to show this on my group calls. It only shows the call