Need to change the Idoc Status based on the Text in the Idoc

Hi All,
I have developed Idoc--SOAP Sync Process Scenario Using BPM and Works Perfectly.
I have used STATUS.SYSTAT01 Idoc to capture the Response that is comming from the Webservice.
I have mapped the response Text( Success or Fail) to one of the field in the Response Idoc, this is perfect.
Requirement:
1) If the Response Idoc Field receives Success Text means the Idoc Status shld be in Green Status.
2) If the Respnse Idoc Field Receives FAIL means the Idoc Status shld be in RED Status.
How can i Do this. please suggest me......
Regards

Hi Santhosh,
YES, I have to Capture the Response from Webservice in SAP R/3 by using STATUS.SYSTAT01 Idoc.
I have mapped the response from webservice to the one of the field in the Idoc.
If this field contains Success as text means the Idoc Status in We05 shld be 53 else it shld be 56
With out changing the FM code, can we use any other process to achieve this???
@ Mario
Can u please Allobarate your views more based on my requirement
Regards

Similar Messages

  • How to change a prospect status to customer in BP,when the prospect turns out to be a potential customer?Please help me with the details.

    How to change a prospect status to customer in BP,when the prospect turns out to be a potential customer?Please help me with the details.
    Moderation: Kindly search before you post

    Dear Ramesh,
    Using Account life cycle we can record the different stages of a BP.
    But at any point of time we can hold one Stage at Business partner.and once we change status Prospect ro Customer. We can't able to see Prospect Status in that BP.
    Ex -
    Stage A- Potentail
    Stage B- Prospect
    Stage C- Customer
    with the help of UI configuration we can define.
    Need your comment,
    Thx
    Karthik

  • I need to change my Apple id in my phone to match the new id i set up online.  How do I do that?  I dont have the password to that email address.

    I need to change my Apple id in my phone to match the new id i set up online.  How do I do that?  I dont have the password to that email address.

    Go to Settings>Store (or Settings>iTunes and App Stores for iOS 6) and sign out and sign in with the other/updated account.

  • HT5312 Hello everyone, i need to change my rescue email address in order to retrieve the answers to my secret questions which I forgot. Any clues on how to do that? Thanks in advance

    Hello everyone, i need to change my rescue email address in order to retrieve the answers to my secret questions which I forgot. Any clues on how to do that? Thanks in advance

    If you can't remember your security questions go to  Express Lane , select iTunes from the list, then iTunes store.    On the next screen select account Management.    There, select iTunes store account security and write that you would like to reset your security questions and / or answers.
    You should get an eMail reply over the next 24 hours.

  • I need to change my security questions. But it's sending the link to an old email. Suggestions?

    I need to change my security questions. But it's sending the link to an old email. Suggestions?

    You won't be able to change your rescue email address until you can answer your questions, you will need to contact iTunes Support / Apple in your country to get the questions reset.
    Contacting Apple about account security : http://support.apple.com/kb/HT5699
    When they've been reset you can then use the steps half-way down this page to update your rescue email address for potential future use : http://support.apple.com/kb/HT5312

  • My phone has been smashed I need to get records of all my iMessages and texts from the last month. How do I get these?

    My phone has been smashed I need to get records of all my iMessages and texts from the last month. How do I get these?

    Do you have a backup of your iPhone which contains these messages?
    If so, you can restore a new iPhone from that backup during setup.
    If not, the messages are gone.

  • Is there a way to change the font size and color of text in the calendar app?

    Does anyone know a way of changing the font size and color of text in the calendar app that comes with the iPad 2?  It is very hard to see the small gray numbers on the calendar.  Thanks

    Looks like you didn't get a reply on your post, but it is still a problem.  Font size is supposedly changeable via "Accessibility" in Settings, but it doesn't work.  You can turn on "Zoom".

  • Exchange 2010 - The certificate status could not be determined because the revocation check failed.

    I have tried everything I have found online to get my DigiCert to work.
    I have exported the cert and imported it into my child domains and they look perfect.
    It is just my parent domain having issues.
    netsh winhttp show proxy
    does show my correct proxy server for http and https and port 8080
    I have tried name, FQDN and IP address.
    In the Bypass-list I have tried none, *.domain.com, and a list of all domains and child domains in my forest.
    I have flushed the cache
    certutil -urlcache crl delete
    certutil -urlcache ocsp delete
    and rebooted the Exchange 2010 (Windows 2008 R2) server
    No matter what, I still see in my Server Configuration for the parent domain's DigiCert cert the message
    The certificate status could not be determined because the revocation check failed.
    with a red X on the left hand icon.  Again, Child domains all say "The certificate is valid for Exchange Server usage."
    Note: In spite of having the red X, I was able to assign via EMS the services.
    Webmail works fine.  Outlook Anywhere fails... I suspect it is due to my red X problem.
    Suggestions?
    Thanks in Advance
    Jim.
    Jim.

    I have contacted DigiCert and they said the cert is working per their utility, hence the problem is outside the scope of their support.
    I have followed, several times, http://support.microsoft.com/kb/979694
    http://www.digicert.com/help/  reports all is well.
    The DigiCertUtil.exe reports all is well and happy.
    I have run
    netsh winhttp set proxy proxy-server="http=myproxy:8080;https=myproxy:8080" bypass-list="*.mydomain.com"
    Current WinHTTP proxy settings:
        Proxy Server(s) :  http=myproxy:8080;https=myproxy:8080
        Bypass List     :  *.mydomain.com
    I have flushed the cache using the commands
    certutil -urlcache crl delete
    certutil -urlcache ocsp delete
     I still see in my Server Configuration for the parent domain's DigiCert cert the message
    "The certificate status could not be determined because the revocation check failed."
    with a red X on the left hand certificate icon. 
    To verify the cert via command line:
    certutil -verify -urlfetch c:\mail_domain_com.cer
    LoadCert(Cert) returned ASN1 bad tag value met. 0x8009310b (ASN: 267)
    CertUtil: -verify command FAILED: 0x8009310b (ASN: 267)
    CertUtil: ASN1 bad tag value met.
    I suspect this is why I cannot get Outlook Anywhere to connect.
    Child domains show a happy certificate icon. Parent domain does not.
    Still scratching my head.
    Thanks all!
    Jim.

  • Need to change user & system status of trade promotion

    Hi,
    I have a requirement where I need to advance a user status if system status is changed based on some creiteria.
    Similarly a system status will be changed on a particular user status.
    Which table is updated for status of trade promotion? Which class/method can be used for it?
    Regards,
    Shikha

    Hello Shikha,
    Status management on the whole in CRM is pretty complex at the db level as there are so many nr of tables. So, i feel it is better not to go more deep.
    Individual application frameworks like one order, marketing has extended the status management for their needs which resulted in pretty good number of APIs for status related actions.
    Try the using the following methods of the class CL_CRM_MKTPL_APPL_BASE
    1) STATUS_READ --> to read the active status of the marketing object at that point of time
    2) STATUS_SET --> for this method pass the business transaction associated with the status of your marketing project.
    Hope this helps.
    Regards,
    Vinay

  • Need to change color of one column's value depending on the other column

    Hi,
    i have a search form which displays two column values
    First column value's colour should be based on second column's value
    For example, if second column has values 'Active', 'Inactive' and 'Pending'
    If 'Active' , the first column value's color sholud be 'red'
    If 'inacitve, another color ....
    Thanks in advance,

    Hi!
    What we did was we added a column on the VO that returns kind of a css part (for example if a column value is 'Active' the value of this column should be "background-color:rgb(255,0,0);")
    Than you use something like this on your column:
    inlineStyle="#{row.StatusStyle}"where StatusStyle is the name of the column with "background-color:rgb(255,0,0);" value.
    The problem here can be that the background color doesn't cover the whole column but only the text in it (so if it is null, the color is default).
    If you want the whole column to be of this color you use something like this:
                                        <af:column ...>
                                          <afh:tableLayout ...>
                                            <afh:rowLayout ...>
                                              <afh:cellFormat inlineStyle="#{row.StatusStyle}" ...>
                                                <af:outputText ...>
                                                </af:outputText>
                                              </afh:cellFormat>
                                            </afh:rowLayout>
                                          </afh:tableLayout>
                                        </af:column>Basically you put another table layout inside a column instead just a outputText (or whatever control you use)
    Hope this is understandable and it helps :)
    It works for us.
    BB

  • IDOC status 30 even if I set transfer IDoc immediately in we20

    Hi All,
    I am creating Bommat IDocs using 'MASTER_IDOC_DISTRIBUTE'  .I am getting the 30 status instead of getting status 3.
    Even   if I set transfer IDoc immediately in we20.
    Please let me know how to resolve this.
    Thanks,
    Vinay.

    Hi Vinay parakala
    Schedule back ground job to program RSEOUT00 regularly to process the 30 status idoc....
    Your program generates the idoc ... and RSEOUT00 will process you idocs which are in 30 status...
    i hope  above info helps you
    Note: enter Message type BOMMAT in  program RSEOUT00
    Thanks
    Ramesh

  • Need to assign char in o12c to show long text of the char in PI sheet

    Hi, Trying to learn PP-PI.  in o12c t-code, created instruction category u201Ctextu201D under instruction cattype (0) and trying to assign a characteristic (test) which is having char group as u201Cprocess instruction characteristicsu201D and willing to select u201Clong text indictor- Tu201D against this characteristic, but getting the error that u201Cthis characteristic is not supported for long textu201D. Please advise how to set long text indicator so that we can show long text in the pi sheet. Thank you.

    Hi,
    To Maintain Long text for characteristic in O12C , you need to
    1) create the Char in T-code O25C with Data type character and click on Proc.Mgmt tab
    2) Tick unlimited field situated right of Length and SAVE the char
    3) Assign this char in O12C under instruction cattype (0). You can see the indicator in the field Text. Now it will allow to main long text for that char in O12C.
    Hope this will help
    Regards
    Brahmaji D

  • How to update the Sent Idoc Status based on the Response From Webservice

    Hi All,
    I have to develop Idoc--SOAP Sync Process Scenario Using BPM .
    I have configured every thing using BPM and mapped
    MATMAS----SOAP Request
    SOAP Resp----STATUS.SYSTAT01
    In R/3  the Main Idoc Number(MATMAS) Status needs to be update , but it is creating the new Idoc with STATUS.SYSTAT01.
    I have used STATUS.SYSTAT01 Idoc to Update the status of the Original idoc based on the Response that is coming from webservice .
    I was posted the same thread a days ago and there Bhavesh suggested me some sugessions.
    How can we make the status of the Idoc based on some response Text
    iam unable to follow OR not able to clear my self on this.
    Please suggest me or give some over view kind of thing on this
    Regards

    Hi Suman,
    It is clearly mentioned in SAP help that "SAP Intermediate Documents (IDOCS) are EDI like documents that are asynchronous in nature."
    So Your Scenario is Asynch(receive) - Synch(WS call) -Transformation (Multimapping)- Asynch(Send to R/3).
    now go in this way:
    you can develop all the message Interfaces  of  Abstract catagory (not manditory )
    MI_AA_MATMAS   -> Abstract Asynchronous message    interface for your Matmas IDOC
    MI_AS_SOAP_ReqandResp  -> Abstarct Syncronous MI for SOAP request and response.
    MI_AA_STATUS ->Abstract Asyncronous MI for Status Idoc
    MI_AA_SOAP_Req ->  Abstarct Asyncronous MI for SOAP request .
    MI_AA_SOAP_Res ->  Abstarct Asyncronous MI for SOAP response .
    Thats all in Message interface.
    your first reciever :
    (This will receive the message asynchronously from R/3)
    create a conatainer varaiable (say preceive) and assign it message interface MI_AA_MATMAS
    Now in thw Propert TAB of this step: give this message name.
    Step2: Synchronous call :
    create container Variable psoaprequest and psoapresponse  give abstract message interface MI_AA_SOAP_Req and MI_AA_SOAP_Req  resp.
    Now in thw Propert TAB of this step:
    Synchronous Interface : MI_AS_SOAP_ReqandResp
    Request Message : psoaprequest
    Response Message: psoapresponse
    Transformation Step :
    Here you will specify Interface Mapping that will conatain Multimapping between Synch Response - MATMAs and STATUS
    Let's name it as IM_ResandMatmasToStatus
    create a container variable as pstatus and assign it abstract interface MI_AA_STATUS.
    In Property pan of this step :
    Interface mapping :IM_ResandMatmasToStatus
    Source Message :psoapresponse
                                preceive
    (IT will ask you for two source messages as IM selected in this transformation has 2 source messages)
    Target Message :pstatus
    Send step:
    Select a message as pstatus.
    thats all in IR.
    If have doubt in ID just let me know.
    Thanks
    Sunil Singh

  • Need to change pgm to add graphics to deskpane (desk) not the overlay panel

    Hello everybody.
    I recently had help in adding graphics to my program and I unintentionally requested that my graphics be added to a overlay panel. After further development I realized that I actually need the graphics to be painted to jdeskpane DESK. I assume that by doing this that the graphics will remain where I placed them (relative to the associated frames) when the scrollbar is utilized.
    This might be a simple question, but I am new to graphics. Once I have the answer, I will analyze it and educate my self further.
    Thank you in advance,
    BAJH
    * Copyright (c) 2007 BAH
    * All rights reserved.
    package com.newsystem.common;
    import java.awt.Color;
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import java.awt.Rectangle;
    import java.awt.RenderingHints;
    import java.awt.geom.Line2D;
    import java.awt.geom.Point2D;
    import java.awt.geom.Rectangle2D;
    import java.beans.PropertyVetoException;
    import javax.swing.*;
    import javax.swing.JButton;
    import javax.swing.JDesktopPane;
    import javax.swing.JFrame;
    import javax.swing.JInternalFrame;
    import javax.swing.JList;
    import javax.swing.JMenuBar;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.ListModel;
    import javax.swing.ScrollPaneConstants;
    import javax.swing.UIManager;
    import javax.swing.event.InternalFrameEvent;
    import javax.swing.event.InternalFrameListener;
    public class A_Test_of_Frame_Connectors extends JDesktopPane {
         private static final long serialVersionUID = 1L;
         JDesktopPane desk;
         JScrollPane scrollpane;
         JInternalFrame iframe;
         JFrame frame;
         JList jList1;
         String currentframetitle;
         String currentframetip;
         String title;
         Integer maxwidth;
         Boolean definingsecondaryconnector;
         Boolean definingparentsecondaryconnector;
         Boolean definingchildsecondaryconnector;
         Rectangle secondaryparentrectangle;
         Rectangle secondarychildrectangle;
        double barb = 10.0;
        double phi = Math.toRadians(20.0);
        RenderingHints hints;
        Boolean drawline = false;
        Integer connectorcount;
        String[] connectiontype;
        String[] connectorparentframe;
        String[] connectorchildframe;
        JInternalFrame[] allframes;
        protected void paintComponent(Graphics g) {
            super.paintComponent(g);
            Graphics2D g2 = (Graphics2D)g;
            g2.setRenderingHints(hints);
            g2.setPaint(Color.blue);
            if (drawline){
                  drawConnector(g2, secondaryparentrectangle, secondarychildrectangle);
        private void drawConnector(Graphics2D g2,Rectangle r1,Rectangle r2) {
            double dx = r2.getCenterX() - r1.getCenterX();
            double dy = r2.getCenterY() - r1.getCenterY();
            double theta = Math.atan2(dy, dx);
            Point2D.Double p1 = getIntersectionPoint(r1, theta);
            Point2D.Double p2 = getIntersectionPoint(r2, theta+Math.PI);
            Line2D.Double line = new Line2D.Double(p1, p2);
            drawArrowHeads(line, g2);
            g2.draw(line);
         public A_Test_of_Frame_Connectors(){
            hints = new RenderingHints(null);
            hints.put(RenderingHints.KEY_ANTIALIASING,
                      RenderingHints.VALUE_ANTIALIAS_ON);
            hints.put(RenderingHints.KEY_STROKE_CONTROL,
                      RenderingHints.VALUE_STROKE_PURE);
              definingsecondaryconnector = false;
              frame = new JFrame("All Frames in a JDesktopPane Container");
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              scrollpane = new JScrollPane(desk,
                        ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS,
                        ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS);
              scrollpane.setPreferredSize(new java.awt.Dimension(9925, 9580));
              desk = new JDesktopPane();
              desk.setPreferredSize(new java.awt.Dimension(15000, 30000));
                   int i = 5;
                   for (int j = 1; j <= i; j++){
                        UIManager.getDefaults().put("InternalFrame.icon", "");
                             ListModel jList1Model =
                                  new DefaultComboBoxModel(
                                            new String[] { "Item One" });
                             title = "Frame " + j;
                             jList1 = new JList();
                             jList1.setModel(jList1Model);
                        jList1.setBounds(1, 1, 45, 54);
                        jList1.setEnabled(false);
                        iframe = new JInternalFrame("Internal Frame: " + j, false, false, false, false);
                        iframe.setName(String.valueOf(j));
                        iframe.setTitle(title);
                        Integer titlewidth;
                        if (title.length() < 30){
                             titlewidth = 265;
                        else{
                             titlewidth = title.length()*8 + 20;
                        iframe.setBounds(j*20, j*20,titlewidth , j*18 + 35);
                        iframe.add(jList1);
                        iframe.addInternalFrameListener(new InternalFrameListener(){
                             public void internalFrameClosing(InternalFrameEvent e) {}
                             public void internalFrameClosed(InternalFrameEvent e) {}
                             public void internalFrameOpened(InternalFrameEvent e) {}
                             public void internalFrameIconified(InternalFrameEvent e) {}
                             public void internalFrameDeiconified(InternalFrameEvent e) {}
                             public void internalFrameActivated(InternalFrameEvent e) {
                                  currentframetitle = e.getInternalFrame().getTitle();
                                  currentframetip = e.getInternalFrame().getToolTipText();
                                  // Connectors
                                  if (definingsecondaryconnector.equals(true)){
                                       if (definingparentsecondaryconnector.equals(true)){
                                            // Build dummy rectangle for creating connector                         
                                            secondaryparentrectangle = new Rectangle(e.getInternalFrame().getBounds());
                                            System.out.println("f name - "+e.getInternalFrame().getName());
                                            definingparentsecondaryconnector = false;
                                            definingchildsecondaryconnector = true;
                                       } else {
                                       if (definingchildsecondaryconnector.equals(true)){
                                            // Build dummy rectangle for creating connector                         
                                            secondarychildrectangle = new Rectangle(e.getInternalFrame().getBounds());
                                            // draw connector
                                               drawline = true;
                                               repaint();
                                               definingchildsecondaryconnector = false;
                             public void internalFrameDeactivated(InternalFrameEvent e) {}
                        iframe.setToolTipText("Internal Frame :" + j);
                        iframe.setVisible(true);
                        desk.add(iframe);
              scrollpane.setViewportView(desk);
              JMenuBar menubar = new JMenuBar();
              JButton SecondaryConnector = new JButton("Secondary Connector");
              SecondaryConnector.addMouseListener(new java.awt.event.MouseAdapter() {
                   public void mousePressed(java.awt.event.MouseEvent e) {
                        definingsecondaryconnector = true;
                        definingparentsecondaryconnector = true;
                        definingchildsecondaryconnector = false;                    
                        try {
                             desk.getSelectedFrame().setSelected(false);
                        } catch (PropertyVetoException e1) {
                             // TODO Auto-generated catch block
                             e1.printStackTrace();
              JPanel overlayPanel = new JPanel();
                 OverlayLayout overlay = new OverlayLayout(overlayPanel);
                 overlayPanel.setLayout(overlay);
                 this.setOpaque(false);
                 overlayPanel.add(this);
                 overlayPanel.add(scrollpane);
              menubar.add(SecondaryConnector);
              frame.setJMenuBar(menubar);
    //          frame.add(scrollpane);
              frame.add(overlayPanel);
              scrollpane.setVisible(true);
              frame.setSize(800,600);
              frame.setVisible(true);
        private Point2D.Double getIntersectionPoint(Rectangle r, double theta) {
            double cx = r.getCenterX();
            double cy = r.getCenterY();
            double w = r.getWidth()/2;
            double h = r.getHeight()/2;
            double radius = Point2D.distance(0,0,w,h);
            double x = cx + radius * Math.cos(theta);
            double y = cy + radius * Math.sin(theta);
            Point2D.Double p = new Point2D.Double();
            int outcode = r.outcode(x, y);
            switch(outcode) {
                case Rectangle2D.OUT_TOP:             // 2
                    p.x = cx - h*((x - cx)/(y - cy));
                    p.y = cy - h;
                    break;
                case Rectangle2D.OUT_LEFT:            // 1
                    p.x = cx - w;
                    p.y = cy - w*((y - cy)/(x - cx));
                    break;
                case Rectangle2D.OUT_BOTTOM:          // 8
                    p.x = cx + h*((x - cx)/(y - cy));
                    p.y = cy + h;
                    break;
                case Rectangle2D.OUT_RIGHT:           // 4
                    p.x = cx + w;
                    p.y = cy + w*((y - cy)/(x - cx));
                    break;
                default:
                    System.out.println("Non-cardinal outcode: " + outcode);
            return p;
        private void drawArrowHeads(Line2D.Double line, Graphics2D g2) {
            double dy = line.getY2() - line.getY1();
            double dx = line.getX2() - line.getX1();
            double theta = Math.atan2(dy, dx);
            drawArrowHead(line.getP2(), theta, g2);
            drawArrowHead(line.getP1(), theta+Math.PI, g2);
        private void drawArrowHead(Point2D tip, double theta, Graphics2D g2) {
            double x = tip.getX() - barb * Math.cos(theta+phi);
            double y = tip.getY() - barb * Math.sin(theta+phi);
            g2.draw(new Line2D.Double(tip.getX(), tip.getY(), x, y));
            x = tip.getX() - barb * Math.cos(theta-phi);
            y = tip.getY() - barb * Math.sin(theta-phi);
            g2.draw(new Line2D.Double(tip.getX(), tip.getY(), x, y));
         public static void main(String[] args) {
              A_Test_of_Frame_Connectors d = new A_Test_of_Frame_Connectors();
    }

    Hello everybody.
    I recently had help in adding graphics to my program and I unintentionally requested that my graphics be added to a overlay panel. After further development I realized that I actually need the graphics to be painted to jdeskpane DESK. I assume that by doing this that the graphics will remain where I placed them (relative to the associated frames) when the scrollbar is utilized.
    This might be a simple question, but I am new to graphics. Once I have the answer, I will analyze it and educate my self further.
    Thank you in advance,
    BAJH
    * Copyright (c) 2007 BAH
    * All rights reserved.
    package com.newsystem.common;
    import java.awt.Color;
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import java.awt.Rectangle;
    import java.awt.RenderingHints;
    import java.awt.geom.Line2D;
    import java.awt.geom.Point2D;
    import java.awt.geom.Rectangle2D;
    import java.beans.PropertyVetoException;
    import javax.swing.*;
    import javax.swing.JButton;
    import javax.swing.JDesktopPane;
    import javax.swing.JFrame;
    import javax.swing.JInternalFrame;
    import javax.swing.JList;
    import javax.swing.JMenuBar;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.ListModel;
    import javax.swing.ScrollPaneConstants;
    import javax.swing.UIManager;
    import javax.swing.event.InternalFrameEvent;
    import javax.swing.event.InternalFrameListener;
    public class A_Test_of_Frame_Connectors extends JDesktopPane {
         private static final long serialVersionUID = 1L;
         JDesktopPane desk;
         JScrollPane scrollpane;
         JInternalFrame iframe;
         JFrame frame;
         JList jList1;
         String currentframetitle;
         String currentframetip;
         String title;
         Integer maxwidth;
         Boolean definingsecondaryconnector;
         Boolean definingparentsecondaryconnector;
         Boolean definingchildsecondaryconnector;
         Rectangle secondaryparentrectangle;
         Rectangle secondarychildrectangle;
        double barb = 10.0;
        double phi = Math.toRadians(20.0);
        RenderingHints hints;
        Boolean drawline = false;
        Integer connectorcount;
        String[] connectiontype;
        String[] connectorparentframe;
        String[] connectorchildframe;
        JInternalFrame[] allframes;
        protected void paintComponent(Graphics g) {
            super.paintComponent(g);
            Graphics2D g2 = (Graphics2D)g;
            g2.setRenderingHints(hints);
            g2.setPaint(Color.blue);
            if (drawline){
                  drawConnector(g2, secondaryparentrectangle, secondarychildrectangle);
        private void drawConnector(Graphics2D g2,Rectangle r1,Rectangle r2) {
            double dx = r2.getCenterX() - r1.getCenterX();
            double dy = r2.getCenterY() - r1.getCenterY();
            double theta = Math.atan2(dy, dx);
            Point2D.Double p1 = getIntersectionPoint(r1, theta);
            Point2D.Double p2 = getIntersectionPoint(r2, theta+Math.PI);
            Line2D.Double line = new Line2D.Double(p1, p2);
            drawArrowHeads(line, g2);
            g2.draw(line);
         public A_Test_of_Frame_Connectors(){
            hints = new RenderingHints(null);
            hints.put(RenderingHints.KEY_ANTIALIASING,
                      RenderingHints.VALUE_ANTIALIAS_ON);
            hints.put(RenderingHints.KEY_STROKE_CONTROL,
                      RenderingHints.VALUE_STROKE_PURE);
              definingsecondaryconnector = false;
              frame = new JFrame("All Frames in a JDesktopPane Container");
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              scrollpane = new JScrollPane(desk,
                        ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS,
                        ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS);
              scrollpane.setPreferredSize(new java.awt.Dimension(9925, 9580));
              desk = new JDesktopPane();
              desk.setPreferredSize(new java.awt.Dimension(15000, 30000));
                   int i = 5;
                   for (int j = 1; j <= i; j++){
                        UIManager.getDefaults().put("InternalFrame.icon", "");
                             ListModel jList1Model =
                                  new DefaultComboBoxModel(
                                            new String[] { "Item One" });
                             title = "Frame " + j;
                             jList1 = new JList();
                             jList1.setModel(jList1Model);
                        jList1.setBounds(1, 1, 45, 54);
                        jList1.setEnabled(false);
                        iframe = new JInternalFrame("Internal Frame: " + j, false, false, false, false);
                        iframe.setName(String.valueOf(j));
                        iframe.setTitle(title);
                        Integer titlewidth;
                        if (title.length() < 30){
                             titlewidth = 265;
                        else{
                             titlewidth = title.length()*8 + 20;
                        iframe.setBounds(j*20, j*20,titlewidth , j*18 + 35);
                        iframe.add(jList1);
                        iframe.addInternalFrameListener(new InternalFrameListener(){
                             public void internalFrameClosing(InternalFrameEvent e) {}
                             public void internalFrameClosed(InternalFrameEvent e) {}
                             public void internalFrameOpened(InternalFrameEvent e) {}
                             public void internalFrameIconified(InternalFrameEvent e) {}
                             public void internalFrameDeiconified(InternalFrameEvent e) {}
                             public void internalFrameActivated(InternalFrameEvent e) {
                                  currentframetitle = e.getInternalFrame().getTitle();
                                  currentframetip = e.getInternalFrame().getToolTipText();
                                  // Connectors
                                  if (definingsecondaryconnector.equals(true)){
                                       if (definingparentsecondaryconnector.equals(true)){
                                            // Build dummy rectangle for creating connector                         
                                            secondaryparentrectangle = new Rectangle(e.getInternalFrame().getBounds());
                                            System.out.println("f name - "+e.getInternalFrame().getName());
                                            definingparentsecondaryconnector = false;
                                            definingchildsecondaryconnector = true;
                                       } else {
                                       if (definingchildsecondaryconnector.equals(true)){
                                            // Build dummy rectangle for creating connector                         
                                            secondarychildrectangle = new Rectangle(e.getInternalFrame().getBounds());
                                            // draw connector
                                               drawline = true;
                                               repaint();
                                               definingchildsecondaryconnector = false;
                             public void internalFrameDeactivated(InternalFrameEvent e) {}
                        iframe.setToolTipText("Internal Frame :" + j);
                        iframe.setVisible(true);
                        desk.add(iframe);
              scrollpane.setViewportView(desk);
              JMenuBar menubar = new JMenuBar();
              JButton SecondaryConnector = new JButton("Secondary Connector");
              SecondaryConnector.addMouseListener(new java.awt.event.MouseAdapter() {
                   public void mousePressed(java.awt.event.MouseEvent e) {
                        definingsecondaryconnector = true;
                        definingparentsecondaryconnector = true;
                        definingchildsecondaryconnector = false;                    
                        try {
                             desk.getSelectedFrame().setSelected(false);
                        } catch (PropertyVetoException e1) {
                             // TODO Auto-generated catch block
                             e1.printStackTrace();
              JPanel overlayPanel = new JPanel();
                 OverlayLayout overlay = new OverlayLayout(overlayPanel);
                 overlayPanel.setLayout(overlay);
                 this.setOpaque(false);
                 overlayPanel.add(this);
                 overlayPanel.add(scrollpane);
              menubar.add(SecondaryConnector);
              frame.setJMenuBar(menubar);
    //          frame.add(scrollpane);
              frame.add(overlayPanel);
              scrollpane.setVisible(true);
              frame.setSize(800,600);
              frame.setVisible(true);
        private Point2D.Double getIntersectionPoint(Rectangle r, double theta) {
            double cx = r.getCenterX();
            double cy = r.getCenterY();
            double w = r.getWidth()/2;
            double h = r.getHeight()/2;
            double radius = Point2D.distance(0,0,w,h);
            double x = cx + radius * Math.cos(theta);
            double y = cy + radius * Math.sin(theta);
            Point2D.Double p = new Point2D.Double();
            int outcode = r.outcode(x, y);
            switch(outcode) {
                case Rectangle2D.OUT_TOP:             // 2
                    p.x = cx - h*((x - cx)/(y - cy));
                    p.y = cy - h;
                    break;
                case Rectangle2D.OUT_LEFT:            // 1
                    p.x = cx - w;
                    p.y = cy - w*((y - cy)/(x - cx));
                    break;
                case Rectangle2D.OUT_BOTTOM:          // 8
                    p.x = cx + h*((x - cx)/(y - cy));
                    p.y = cy + h;
                    break;
                case Rectangle2D.OUT_RIGHT:           // 4
                    p.x = cx + w;
                    p.y = cy + w*((y - cy)/(x - cx));
                    break;
                default:
                    System.out.println("Non-cardinal outcode: " + outcode);
            return p;
        private void drawArrowHeads(Line2D.Double line, Graphics2D g2) {
            double dy = line.getY2() - line.getY1();
            double dx = line.getX2() - line.getX1();
            double theta = Math.atan2(dy, dx);
            drawArrowHead(line.getP2(), theta, g2);
            drawArrowHead(line.getP1(), theta+Math.PI, g2);
        private void drawArrowHead(Point2D tip, double theta, Graphics2D g2) {
            double x = tip.getX() - barb * Math.cos(theta+phi);
            double y = tip.getY() - barb * Math.sin(theta+phi);
            g2.draw(new Line2D.Double(tip.getX(), tip.getY(), x, y));
            x = tip.getX() - barb * Math.cos(theta-phi);
            y = tip.getY() - barb * Math.sin(theta-phi);
            g2.draw(new Line2D.Double(tip.getX(), tip.getY(), x, y));
         public static void main(String[] args) {
              A_Test_of_Frame_Connectors d = new A_Test_of_Frame_Connectors();
    }

  • HT201303 I need to change my security question because I do not know the answer to the car question can someone help me please.

    the security question about which was your favorite car and least fav I cannot remmeber my answer how do i go about changing this or getting a new set up question ?

    Alternatives for Help Resetting Security Questions and Rescue Mail
         1. Apple ID- All about Apple ID security questions.
         2. Rescue email address and how to reset Apple ID security questions
         3. Apple ID- Contacting Apple for help with Apple ID account security.
         4. Fill out and submit this form. Select the topic, Account Security.
         5.  Call Apple Customer Service: Contacting Apple for support in your
              country and ask to speak to Account Security.
    How to Manage your Apple ID: Manage My Apple ID

Maybe you are looking for