Coordinates for next internal square

Hi, the next question :)
Imagine big square and several small squares inside it. These small squares should appear automatically and should not lay one over other. So, the problem is to calculate next X and next Y for each new square to be placed on big square. I need a proper algorythm to do that.
Please advice.
Thanks and regards,
F.

import java.awt.*;
import java.awt.event.*;
import java.util.*;
import java.util.List;
import javax.swing.*;
import javax.swing.event.MouseInputAdapter;
public class MSFRx extends JPanel {
    Rectangle crib;
    List<Rectangle> rects;
    int[] limits;
    final int S = 25;
    final int PAD = 3;
    final int MARGIN = 40;
    public MSFRx() {
        Dimension d = getPreferredSize();
        crib = new Rectangle(MARGIN, MARGIN, d.width-2*MARGIN, d.height-2*MARGIN);
        rects = new ArrayList<Rectangle>();
        initLimits();
    protected void paintComponent(Graphics g) {
        super.paintComponent(g);
        Graphics2D g2 = (Graphics2D)g;
        g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                            RenderingHints.VALUE_ANTIALIAS_ON);
        g2.setPaint(Color.green.darker());
        g2.draw(crib);
        g2.setPaint(Color.blue);
        for(Rectangle r : rects)
            g2.draw(r);
    public void setRect(Rectangle r, int x, int y) {
        r.setLocation(x, y);
        repaint();
    public void addRect() {
        int x = (int)(crib.getCenterX() - S/2.0);
        int y = crib.y + 1;
        Rectangle r = new Rectangle(x, y, S, S);
        Point nextPos = getNextPosition(r);
        if(nextPos != null) {
            r.setLocation(nextPos);
            rects.add(r);
        repaint();
    private Point getNextPosition(Rectangle r) {
        int w = crib.width;
        int h = crib.height;
        int xPos = crib.x + w/2, yPos = crib.y + 1;
        for(int j = 0; j < rects.size()+1; j++) {
            if(j < limits[0]) {
                xPos = crib.x + w/2 + j*(S + PAD);
                yPos = crib.y + 1;
            } else if(j < limits[1]) {
                xPos = crib.x + w - S -1;
                yPos = crib.y + 1 + (j + 1 - limits[0])*(S + PAD);
            } else if(j < limits[2]) {
                xPos = crib.x + w - (j + 2 - limits[1])*(S + PAD);
                yPos = crib.y + h - S - 1;
            } else if(j < limits[3]) {
                xPos = crib.x + 1;
                yPos = crib.y + h - (j + 2 - limits[2])*(S + PAD);
            } else if(j < limits[4]) {
                xPos = crib.x + 1 + (j + 1 - limits[3])*(S + PAD);
                yPos = crib.y + 1;
            } else {
                System.out.println("crib is full");
                return null;
        return new Point(xPos, yPos);
    public Dimension getPreferredSize() {
        return new Dimension(400,400);
    private void initLimits() {
        int w = crib.width;
        int h = crib.height;
        int[] numRects = new int[5];
        // top middle to top right corner
        numRects[0] = (w/2)/(S + PAD);
        // right side: top to bottom
        numRects[1] = (h - S - PAD)/(S + PAD);
        // bottom: right to left
        numRects[2] = (w - S - PAD)/(S + PAD);
        // left: bottom to top
        numRects[3] = (h - S + PAD)/(S + PAD);
        // top: left corner to middle
        numRects[4] = (w/2 - S - PAD - 1)/(S + PAD);
        limits = new int[numRects.length];
        for(int j = 0, total = 0; j < limits.length; j++) {
            total += numRects[j];
            limits[j] = total;
        //System.out.printf("numRects = %s%nlimits = %s%n",
        //                   Arrays.toString(numRects), Arrays.toString(limits));
    public static void main(String[] args) {
        MSFRx test = new MSFRx();
        RectangleWrangler rw = new RectangleWrangler(test);
        test.addMouseListener(rw);
        test.addMouseMotionListener(rw);
        JFrame f = new JFrame("Click in green to add rectangles");
        f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        f.getContentPane().add(test);
        f.pack();
        f.setLocationRelativeTo(null);
        f.setVisible(true);
class RectangleWrangler extends MouseInputAdapter {
    MSFRx component;
    Rectangle selectedRect = null;
    Point offset = new Point();
    boolean dragging = false;
    public RectangleWrangler(MSFRx msfrx) {
        component = msfrx;
    public void mousePressed(MouseEvent e) {
        Point p = e.getPoint();
        List<Rectangle> list = component.rects;
        // Are we selecting an existing rectangle?
        for(int j = 0; j < list.size(); j++) {
            Rectangle r = list.get(j);
            if(r.contains(p)) {
                selectedRect = r;
                offset.x = p.x - r.x;
                offset.y = p.y - r.y;
                dragging = true;
                break;
        // Or are we adding a new rectangle to the crib?
        if(selectedRect == null && component.crib.contains(p))
            component.addRect();
    public void mouseReleased(MouseEvent e) {
        dragging = false;
        selectedRect = null;
    public void mouseDragged(MouseEvent e) {
        if(dragging) {
            Point p = e.getPoint();
            double cx = selectedRect.getCenterX();
            double cy = selectedRect.getCenterY();
            Rectangle crib = component.crib;
            int S = component.S;
            boolean top    = cy - crib.y < S;
            boolean left   = cx - crib.x < S;
            boolean bottom = crib.y + crib.height - cy < S;
            boolean right  = crib.x + crib.width  - cx < S;
            boolean horizontal = top  || bottom;
            boolean vertical   = left || right;
            if(horizontal && vertical) {
                if(top && left) {
                    // Check boundries.
                    if(selectedRect.x - crib.x < 0) selectedRect.x = crib.x -1;
                    if(selectedRect.y - crib.y < 0) selectedRect.y = crib.y +1;
                    // Choose direction according to larger displacment.
                    if(Math.abs(p.x - offset.x) <= Math.abs(p.y - offset.y))
                        horizontal = false;
                    else
                        vertical = false;
                } else if(left && bottom) {
                    if(selectedRect.x - crib.x < 0) selectedRect.x = crib.x +1;
                    if(crib.y + crib.height - selectedRect.y < S)
                        selectedRect.y = crib.y + crib.height - S -1;
                    if(Math.abs(p.x - crib.x) < Math.abs(p.y - crib.y - crib.height))
                        horizontal = false;
                    else
                        vertical = false;
                } else if(bottom && right) {
                    if(crib.x + crib.width - selectedRect.x + S < 0)
                        selectedRect.x = crib.x + crib.width - S -1;
                    if(crib.y + crib.height - selectedRect.y + S < 0)
                        selectedRect.y = crib.y + crib.height - S -1;
                    if(Math.abs(p.x - crib.x - crib.width) <=
                               Math.abs(p.y - crib.y - crib.height))
                        horizontal = false;
                    else
                        vertical = false;
                } else if(right && top) {
                    if(crib.x + crib.width - selectedRect.x + S < 0)
                        selectedRect.x = crib.x + crib.width - S -1;
                    if(selectedRect.y - crib.y < 0) selectedRect.y = crib.y +1;
                    if(Math.abs(p.x - crib.x - crib.width) <= Math.abs(p.y - crib.y))
                        horizontal = false;
                    else
                        vertical = false;
            int x = p.x - offset.x;
            int y = p.y - offset.y;
            // Make the rectangle follow the line.
            if(horizontal) {
                if(top) {
                    y = crib.x + 1;
                } else if(bottom) {
                    y = crib.y + crib.height - S -1;
            } else if(vertical) {
                if(left) {
                    x = crib.x + 1;
                } else if(right) {
                    x = crib.x + crib.width - S -1;
            component.setRect(selectedRect, x, y);
}

Similar Messages

  • Purchase order not appearing as commitment for next fiscal year in KOB2

    Hi Experts
    Any help on this is highly appreciated.Our Fiscal year 2008 is ending on 27th september and fiscal year 2009 will start on 28th September.
    We have some purchase orders created with delivery date as 30th september which falls into next fiscal year. Somehow these purchase orders are not appearing as commitments in KOB2 report even with data ranges for next fiscal year.
    However we have many similar Purchase orders with delivery date in fiscal year 2008 with same internal order as account assignment and they are correctly appearing as commitments in KOB2 report.
    Can you please let us know what could be the reason for purchase orders with delivery date as 30th september not appearing in KOB2 report.
    Regards,
    Santosh

    Hi Ashok
    Thanks for your continued support on this. I was going through these notes today.
    One observation I made was cost elements in our system were valid till 27th september only when problematic POs were created.However their validity was subsequently extended after the creation of Purchase orders.This might be the reason for system not recognising these POs as commitments.
    SAP Note 534993 seems to suggest that we need to run report RKANBU01 for all such purchase orders to redetermine commitments.I am in the process of testing this out in our systems.
    Could you please let me know if my understanding is correct. Thanks again.
    Regards,
    Santosh

  • How to test the firewall is opened for a internal server

    should I use
    ping -t <IP of the internal server>  36<nr>?
    Thanks! Points!

    Hi Jennifer
    try to execute the following command from the shell prompt
    tracert -d  <Ip address for the internal server>
    try to note down the IP address where the packets are not transferring to other hops
    ask your network person to resolve the IP to pass the packet to next hop
    if your tracert session has been ended with all resolved IPs
    then try to telnet <IP address for the Internal server> 36<nr>
    if not, then Firewall has been blocking you, or Portal not yet configured proper.
    REgards
    Anwer Waseem

  • Next internal review date in status view

    Hi,
    Customer credit management transaction FD33, in status view, we have field "Next internal review". Can any one  let me know how this data is populated automatically.
    And how the documents will be selected for report "RVKRED08"
    Thanks
    Alokam Chandra Sekhar

    Hi,
    In OVA8 automatic credit contol settings, there you can define next review date. If you maintain number of days here it will be copied to credit maseter...
    regards
    sankar
    Edited by: sankar sankar on Jul 9, 2008 1:48 PM

  • Where are the settings for the internal Airport Extreme Card?

    Here is my problem.
    I have a Xbox Slim. It was connected wirelessly to my old Mac computer which had a external Airport Extreme b/g. Connection worked perfectly and had no issues.
    I bought a new computer a iMac with OS X 10.6.7. It comes with a built in Airport Extreme Card that has wireless connection for b/g/n.
    I set up my wireless connection on my new computer. We have two iphones and they both connect to the new wireless network with no problems.
    When I go to connect my xbox slim it asks me for WEP, which I enter, but when I go to test connection I get a error message. The connection fails between the xbox and my network. Says unable to connect and then gives me a bunch of troubleshooting messages which none seem to work.
    Under the IP Settings is says Automatic and has a IP address listed and a Subnet Listed. The Gateway is all zeros.
    When I go into the Airport settings the DHCP is turned on.
    Now I know my next option is enter the numbers manually which I have tried several times. I don't really know if I'm getting the right numbers or not because its a new iMac and everywhere I search people are getting the IP addresses, router numbers, etc. from PC's or from external routers. I need to get mine from the internal Airport Extreme Card.
    I have also read posts for setting your options for Mac Filtering. But I don't know where to adjust these. I don't see any options for configuration for a internal Airport Card.
    Where do I adjust the settings for Mac Filtering, Signal Strength, b/g/n, etc?
    I know my Xbox's connection is fine because I plug in my old Airport Extreme and it connects just fine. But I don't want to use my old wireless router. I would like to just use the connection that is built into my iMac because it has the 'n' network. Is that even possible?
    Any help would be greatly appreciated. Thanks in advance.

    ImperialStout wrote:
    I don't see any options for configuration for a internal Airport Card.
    there aren't any.
    check out [this|http://discussions.info.apple.com/message.jspa?messageID=3797169] discussion. it is rather old but the facts remain unchanged.
    you might want to have another look @ your airport extreme or get a newer, [refurbished_|http://store.apple.com/us/browse/home/specialdeals/mac/macaccessories?mco=MjEwNzM3NjE] extreme (there currently aren't any) or time capsule. these base station are *simultaneous dual-band* capable, meaning they broadcast on both the 2.4 and 5 GHz bands @ the same time.

  • Wait for Next Sample Clock error, or 'How do I put this VI on a diet'?

    Hello!
    In the attached VI I've been running since June, I have all the functionality I need.  No questions there at all, thanks to much time and help from this board!
    My nagging problem is that any time I use the PC for other minor tasks other than Labview, it will display the following error:
    209802 occurred at DAQmx Wait For Next Sample Clock.vi:1
    A search earlier in the month indicated that it could have been a result of my old and outdated PC; I've since replaced it with a brand-new dell dimension 1100.  Celeron 2.53ghz with 1.00gb of ram.  Should be enough to service Labview and other minor tasks (automatic antivirus updating and also maintenance tasks).  However, any time any other program opens or even if the screen is scrolled around on Labview quickly, I get that same error.
    Resource usage when idle, with nothing but this VI running is 5-10%, all labview.  Upon scrolling the VI, it quickly jumps to the 58-60% and above mark and soon throws that error.
    I know that there's a lot of code here that can be cleaner--I know that even though it's functioning correctly, there could be a less resource-hogging way to go about it.  Can anyone give me any suggestions on how to make this VI a little 'lighter'?
    Thanks so much in advance,
    Ralph
    Still confused after 8 years.
    Attachments:
    Currently Running 063006.vi ‏899 KB

    Hi Ralph,
    The wait.vi waits until the amount of time has passed. While the wait on next ms.vi uses some kind of quotient and remainder on the computer time until the remainder passed zero.
    In this way you can synchronize 2 loops, and somehow it is less time-consuming. The only difference you will see is in the first run!
    There you see a smaller amount of time:
    Message Edited by TonP on 10-04-2006 04:21 PM
    Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
    Nederlandse LabVIEW user groep www.lvug.nl
    My LabVIEW Ideas
    LabVIEW, programming like it should be!
    Attachments:
    Example_BD.png ‏2 KB

  • Standard report for settled internal orders

    Hi All,
    Is there any standard report available in Asset for settled internal orders.
    We can able to see in S_ALR_87013019.  But all Internal orders are appearing.  I am not able to see settled orders.  How to identify those... (Like flag color difference should be required for settled and open).
    Thanx in advance.
    Regs,
    Bhaskar

    Hi All,
    Is there any standard report available in Asset for settled internal orders.
    We can able to see in S_ALR_87013019. But all Internal orders are appearing. I am not able to see settled orders. How to identify those... (Like flag color difference should be required for settled and open).
    Thanx in advance.
    Regs,
    Bhaskar

  • I want to change the settings (brightness, contrast, gamma) for my internal cam on Macbook pro. I find having to but a third party software (iglasses, webcam settings) to control basic settings as unnecessary and exploitative. Does anyone have a solution?

    I want to change the settings (brightness, contrast, gamma) for my internal cam on Macbook pro. I find having to but a third party software (iglasses, webcam settings) to control basic settings as unnecessary and exploitative. Does anyone have a solution?

    It is not about payment of $19.95 (Igalsses) or $7.99(webcam settings). This is a very basic setting that should be available in the system settings. The automatic setting of the internal cam does not work great on low lighting as everyone is aware.
    i am just amazed how users take in lying down and suggest solutions such as paying for a 3rd party paid app or improving the lighting in your room.

  • How to get a Monthly Depreciation Simulation for next fiscal year?

    I need a report that give me the depreciation simulation for next fiscal year, but I need it monthly wise. I run report S_ALR_87012936 with report date 31.12.2011 and evaluation period = month.
    The report gives the error message AA669 Fiscal year 2011 is already closed in Financial Accounting
    I read that this report doesn't work monthly wise for future years. Is there a workarround?
    Best regards!

    Hi,
    I'm sorry there is only RASIMU02. Note 396974 describes, this is a missing functionality and there  is no workaround.
    Reports on derived depreciation areas that do not post any values to the
    general ledger are allowed with the evaluation period year. An
    evaluation using month, quarter or half-year is not supported.
    In general, the depreciation forecasted by monthly in report RASIMU02 are only for depreciation area which posts depreciation to GL. For non-GL posting area, we recommend you simulate the depreciation 
    in 'fiscal year' mode. if you simulate the depreciation 
    Basically RASIMU02 is NOT designed to provide period simulation for these non posting areas. This because RASIMU02 uses for periods which have been posted already the created ANLP. But ANLP´s  are not created for non-posting areas. So in these periods where   a depreciation run had been executed already, RASIMU02 will not show
    values.                                                                               
    For AA 669 please see:
    Best Regards Bernhard
    Edited by: Bernhard Kirchner on Nov 25, 2010 9:20 AM

  • Request for next updates of Zen Mi

    I have a request for next updates of Zen Micro!
    Please, add an option in the Zen Micro allowing to disable the blue fading lighting during charging, it is very beautiful, but very disturbing in a bedroom all the night!

    Hello,
    Some of the javascripts are automatically inserted into every page that is one of them it will be fixed in a future version. It doesn't harm anything though.
    Using some of the more advanced functionality in HTML DB even in future version will keep the pages from validating correctly. While it is our intention to get as fully standards compliant as possible we will always lean to the side of providing more functionality/browser compatibility over compliance.
    Carl

  • Get location/coordinates for a field using JavaScript in Acrobat Professional

    Good day,
    I am looking for a way to get the coordinates of a text field.
    I would like to create a listbox and set the location of the listbox top left to the text fields bottom left coordinates, I have had a look at the scripting guides ... could not turn up anything.
    I know how to create and populate this listbox using the JavaScript code, only problem is, to get the coordinates of the text box.

    Try this:
    1. Move or change the dimensions of the text boxes on the extracted page in the configuration that you want.
    2. When you are satisfied with the new configuration, modify the following JavaScript to use the names of the text boxes that you want to include on the page.
    //find_rect //find coordinates of text boxes whose names are included in the var rct,ary = ["fld_1","fld_2","fld_3","fld_4"]; //...etc.
    for (j = 0; j<ary.length; j++){
    console.println(ary[j]);
    rct = this.getField(ary[j]).rect;
    for (i= 0; i< rct.length; i++) console.println(rct[i]);
    3. Add the modified code to the document level of form. (as a doc level javascript but with no function name or brackets included.
    4. When you run the code, the coordinates for the fields that you have included in the array will be printed in the console window:
    Example:
    fld_1
    21
    777
    296
    717
    fld_2
    30
    769
    65
    729

  • For Next loop in allocations

    Request help in writing a allocation logic code.
    The current runs for 2600 Projects and 12000 customers. This causes memory issue and the code is aborted when run.
    Please suggest if this code can be run in a For/Next loop for each project..
    *XDIM_MEMBERSET CATEGORY = %CATEGORY_SET%
    *XDIM_MEMBERSET TIME = %TIME_SET%
    *WHEN ACCOUNT
    *IS "A1100001"
    *REC(EXPRESSION = ([ACCOUNT].[A1100001])*((%VALUE%)),ACCOUNT = "A3100001")
    *ENDWHEN
    *XDIM_MEMBERSET TIME = %TIME_SET%
    *XDIM_MEMBERSET ACCOUNT = BAS(MET-SAL.3.1)
    *XDIM_MEMBERSET P_PROJECT = BAS(AllProjects)
    *XDIM_ADDMEMBERSET P_PROJECT = NO_PROJECT
    *XDIM_MEMBERSET P_DEPARTMENT = ESG_Input
    *XDIM_MEMBERSET P_ENTITY = TTEU_INP
    *XDIM_MEMBERSET P_CUSTOMER = No_Customer
    *XDIM_ADDMEMBERSET P_CUSTOMER = BAS(AllCustomers)
    *XDIM_MEMBERSET P_ANALYSIS = BAS(AllAnalysis)
    *XDIM_ADDMEMBERSET P_ANALYSIS = NO_ANALYSIS
    *RUNALLOCATION
    *FACTOR = 1
    *DIM ACCOUNT WHAT = BAS(MET-SAL.3.1) ; WHERE = <<<;USING = <<<;TOTAL = <<<
    *DIM P_PROJECT WHAT = NO_PROJECT ;WHERE = <<< ;USING = <<<;TOTAL = <<< 
    *DIM P_DEPARTMENT WHAT = ESG_Input ;WHERE = <<< ;USING = <<<;TOTAL = <<< 
    *DIM P_ENTITY WHAT = TTEU_INP ;WHERE = <<< ;USING = <<<;TOTAL = <<< 
    *DIM P_ANALYSIS WHAT = NO_ANALYSIS ;WHERE = BAS(AllAnalysis) ;USING = <<<;TOTAL = <<< 
    *DIM P_CUSTOMER WHAT = No_Customer ;WHERE = BAS(AllCustomers) ;USING = <<<;TOTAL = <<<
    *ENDALLOCATION
    next

    I realized that while checking and have removed the section for recording expression.. and now only focusing to correct the Allocation logic. Based on your advice I have added the FOR/NEXT as below.
    The code is now only running for EDCTM-0007 but fails to generate any records for EDCTM-0014.
    *XDIM_MEMBERSET CATEGORY = %CATEGORY_SET%
    *XDIM_MEMBERSET TIME = %TIME_SET%
    *XDIM_MEMBERSET ACCOUNT AS %SAL% = BAS(MET-SAL.3.1)
    //*XDIM_MEMBERSET P_PROJECT = BAS(AllProjects)
    *XDIM_MEMBERSET P_PROJECT AS %PRJ% = EDCTM-0007, EDCTM-0014
    *XDIM_ADDMEMBERSET P_PROJECT = NO_PROJECT
    *XDIM_MEMBERSET P_DEPARTMENT = BAS(AllDepartments)
    *XDIM_MEMBERSET P_ENTITY = BAS(AllEntities)
    *XDIM_MEMBERSET P_CUSTOMER = BAS(AllCustomers)
    *XDIM_MEMBERSET P_ANALYSIS = BAS(AllAnalysis)
    *XDIM_MEMBERSET RPTCURRENCY = INR, CAD, EUR, GBP, KRW, MXN, SGD, THB, USD
    *FOR %PRJ% = EDCTM-0007, EDCTM-0014
    *RUNALLOCATION
    *FACTOR = 1
    *DIM ACCOUNT WHAT = %SAL%; WHERE = <<<; USING = <<<; TOTAL = <<<
    *DIM P_DEPARTMENT WHAT = ED_Input; WHERE = ED16; USING = <<<; TOTAL = <<<
    *DIM P_ENTITY WHAT = PUN_C; WHERE = <<<; USING = <<<; TOTAL = <<<
    *DIM P_CUSTOMER WHAT = No_Customer; WHERE = C100700; USING = <<<; TOTAL = <<<
    *DIM P_PROJECT WHAT = NO_PROJECT; WHERE = %PRJ%; USING = <<<; TOTAL = <<<
    *DIM P_ANALYSIS WHAT = NO_ANALYSIS; WHERE = TM_S; USING = <<<; TOTAL = <<<
    *ENDALLOCATION
    *COMMIT
    *NEXT
    log..
       FILE:\ROOT\WEBFOLDERS\ENVIRONMENTSHELL1\ADMINAPP\Planning_TTL\CP_RAVINNINE.LGF
    USER:RAVINDRA.S
    APPSET:ENVIRONMENTSHELL1
    APPLICATION:Planning_TTL
    FACTOR:1
    ALLOCATION DATA REGION:
    CATEGORY:Budget,
    P_PROJECT:NO_PROJECT,
    P_DEPARTMENT:Admin_Entity,Admin_Group,BRT_Entity,CEO_Entity,CEO_Group,COO_Entity,COO_Group,CSR_Entity,CSR_Group,ED01,ED02,ED03,ED04,ED05,ED06,ED07,ED08,ED09,ED10,ED11,ED12,ED13,ED14,ED15,ED16,ED_Input,ESG01,ESG02,ESG03,ESG04,ESG05,ESG06,ESG07,ESG08,ESG09,ESG10,ESG_Input,Finance_Entity,Finance_Group,GDO_Entity,HR_Entity,HR_Group,IT_Ent_Apps_Entity,IT_Ent_Apps_Group,IT_Ops_Infra_Entity,IT_Ops_Infra_Group,Legal_Entity,Legal_Group,Mktg_Entity,Mktg_Group,NO_DEPT,OSM_Entity,OSM_Group,PL01,PL02,PL03,PL04,PL05,PL06,PL07,PL08,PL09,PLM_P_Input,PLM_P_Services_Input,PLM_S_Input,PP01,PP02,PP03,PP04,PP05,Products_Autodesk,Products_Dassault,Products_IBM,Products_IKS,Products_MSC,Products_Others,Products_UGS,Quality_Entity,Quality_Group,VP01,VPD01,VPD_Input,
    P_ENTITY:BLO_C,BLO_Input,BLO_NC,BLR_C,BLR_Input,BLR_NC,BOM_C,BOM_Input,BOM_NC,BRG_C,BRG_Input,BRG_NC,BRZ_C,BRZ_Input,BRZ_NC,CAN,DEL_C,DEL_Input,DEL_NC,GER,GIP,HNJ_C,HNJ_Input,HNJ_NC,JSE_C,JSE_Input,JSE_NC,JSR_C,JSR_Input,JSR_NC,LKQ_C,LKQ_Input,LKQ_NC,MEX,NLD,PNQ_C,PNQ_Input,PNQ_NC,PUD_C,PUD_Input,PUD_NC,PUN_C,PUN_Input,PUN_NC,SAS,SIG,SKR,THD,THE,TTCN_INP,TTEU_INP,TTL_INP,TTMX_INP,TTPL_INP,TTTH_INP,TTUS_INP,UKG_Input,UKG_J,UKG_N,USA,
    P_CUSTOMER:C000001,C000002,C000003,C000004,C000005,C000006,C000007,C000008,C000009,C000010,C000011,C000012,C000013,C000014,C000015,C000016,C000017,C000018,C000019,C000020,C000021,C000022,C000023,C000024,C000025,C000026,C000027,C000028,C000029,C000030,C000031,C000032,C000033,C000034,C000035,C000036,C000037,C000038,C000039,C000040,C000041,C000042,C000043,C000044,C000045,C000046,C000047,C000048,C000049,C000050,C000051,C000052,C000053,C000054,C000055,C000056,C000057,C000058,C000059,C000060,C000061,C000062,C000063,C000064,C000065,C000066,C000067,C000068,C000069,C000070,C000071,C000072,C000073,C000074,C000075,C000076,C000077,C000078,C000079,C000080,C000081,C000082,C000083,C000084,C000085,C000086,C000087,C000088,C000089,C000090,C000091,C000092,C000093,C000094,C000095,C000096,C000097,C000098,C000099,C000100,C000101,C000102,C000103,C000104,C000105,C000106,C000107,C000108,C000109,C000110,C000111,C000112,C000113,C000114,C000115,C000116,C000117,C000118,C000119,C000120,C000121,C000122,C000123,C000124,C000125,C000126,C000127,C000128,C000129,C000130,C000131,C000132,C000133,C000134,C000135,C000136,C000137,C000138,C000139,C000140,C000141,C000142,C000143,C000144,C000145,C000146,C000147,C000148,C000149,C000150,C000151,C000152,C000153,C000154,C000155,C000156,C000157,C000158,C000159,C000160,C000161,C000162,C000163,C000164,C000165,C000166,C000167,C000168,C000169,C000170,C000171,C000172,C000173,C000174,C000175,C000176,C000177,C000178,C000179,C000180,C000181,C000182,C000183,C000184,C000185,C000186,C000187,C000188,C000189,C000190,C000191,C000192,C000193,C000194,C000195,C000196,C000197,C000198,C000199,C000200,C000201,C000202,C000203,C000204,C000205,C000206,C000207,C000208,C000209,C000210,C000211,C000212,C000213,C000214,C000215,C000216,C000217,C000218,C000219,C000220,C000221,C000222,C000223,C000224,C000225,C000226,C000227,C000228,C000229,C000230,C000231,C000232,C000233,C000234,C000235,C000236,C000237,C000238,C000239,C000240,C000241,C000242,C000243,C000244,C000245,C000246,C000247,C000248,C000249,C000250,C000251,C000252,C000253,C000254,C0002
    P_ANALYSIS:FB_M,FB_S,NO_ANALYSIS,TM_M,TM_S,
    RPTCURRENCY:CAD,EUR,GBP,INR,KRW,MXN,SGD,THB,USD,
    ACCOUNT:WHAT:MET-SAL.1.1,MET-SAL.5.1, MET-SAL.1.2,MET-SAL.5.2, MET-SAL.1.3,MET-SAL.5.3, MET-SAL.1.4,MET-SAL.5.4, MET-SAL.1.5,MET-SAL.5.5, MET-SAL.1.6,MET-SAL.5.6, MET-SAL.1.7,MET-SAL.5.7, MET-SAL.1.8,MET-SAL.5.8,WHERE:<<<,USING:<<<,TOTAL:<<<
    P_DEPARTMENT:WHAT:ED_Input,WHERE:ED16,USING:<<<,TOTAL:<<<
    P_ENTITY:WHAT:PUN_C,WHERE:<<<,USING:<<<,TOTAL:<<<
    P_CUSTOMER:WHAT:No_Customer,WHERE:C100700,USING:<<<,TOTAL:<<<
    P_PROJECT:WHAT:NO_PROJECT,WHERE:EDCTM-0007,USING:<<<,TOTAL:<<<
    P_ANALYSIS:WHAT:NO_ANALYSIS,WHERE:TM_S,USING:<<<,TOTAL:<<<
    --Read WHAT region
    [P_DEPARTMENT] =ED_Input
    [P_CUSTOMER] =No_Customer
    [P_PROJECT] =NO_PROJECT
    [P_ANALYSIS] =NO_ANALYSIS
    [CATEGORY] =Budget
    [RPTCURRENCY] =CAD,EUR,GBP,INR,KRW
    --Time to load WHAT :0.2066 second(s).
    WHAT data:1680 records.
    --Apply factor
    WHERE=WHAT *1
    --Time to apply factor :0.003074 second(s).
    --Read destination and calculate difference
    [P_DEPARTMENT] =ED16
    [P_CUSTOMER] =C100700
    [P_PROJECT] =EDCTM-0007
    [P_ANALYSIS] =TM_S
    [CATEGORY] =Budget
    [RPTCURRENCY] =CAD,EUR,GBP,INR,KRW
    --Time to read destination and calculate difference :0.14611 second(s).
    --Records succeeded to write back :1680
    --Records failed to write back
    --Time to run Allocation :0.390015 second(s).
    FACTOR:1
    ALLOCATION DATA REGION:
    CATEGORY:Budget,
    ACCOUNT:WHAT:MET-SAL.1.1,MET-SAL.5.1, MET-SAL.1.2,MET-SAL.5.2, MET-SAL.1.3,MET-SAL.5.3, MET-SAL.1.4,MET-SAL.5.4, MET-SAL.1.5,MET-SAL.5.5, MET-SAL.1.6,MET-SAL.5.6, MET-SAL.1.7,MET-SAL.5.7, MET-SAL.1.8,MET-SAL.5.8,WHERE:<<<,USING:<<<,TOTAL:<<<
    P_DEPARTMENT:WHAT:ED_Input,WHERE:ED16,USING:<<<,TOTAL:<<<
    P_ENTITY:WHAT:PUN_C,WHERE:<<<,USING:<<<,TOTAL:<<<
    P_CUSTOMER:WHAT:No_Customer,WHERE:C100700,USING:<<<,TOTAL:<<<
    P_PROJECT:WHAT:NO_PROJECT,WHERE:EDCTM-0014,USING:<<<,TOTAL:<<<
    P_ANALYSIS:WHAT:NO_ANALYSIS,WHERE:TM_S,USING:<<<,TOTAL:<<<
    "LC" has been added as default currency in allocation.
    --Read WHAT region
    [P_DEPARTMENT] =ED_Input
    [P_CUSTOMER] =No_Customer
    [P_PROJECT] =NO_PROJECT
    [P_ANALYSIS] =NO_ANALYSIS
    [CATEGORY] =Budget
    [ACCOUNT] =MET-SAL.1.1,MET-SAL.1.2,MET-SAL.1.3,MET-SAL.1.4,MET-SAL.1.5
    --Time to load WHAT :0.060259 second(s).
    WHAT data:0 records.
    --Apply factor
    WHERE=WHAT *1
    --Time to apply factor :0.000028 second(s).
    --Read destination and calculate difference
    [P_DEPARTMENT] =ED16
    [P_CUSTOMER] =C100700
    [P_PROJECT] =EDCTM-0014
    [P_ANALYSIS] =TM_S
    [CATEGORY] =Budget
    [ACCOUNT] =MET-SAL.1.1,MET-SAL.1.2,MET-SAL.1.3,MET-SAL.1.4,MET-SAL.1.5
    --Time to read destination and calculate difference :0.05125 second(s).
    --Records succeeded to write back
    regards, Prashant

  • In flex charts the label for next month get dropped

    I found for DatatTimeAxis if you set disabledRanges to the last date of the month the label for next month gets dropped using property labelUnits='months". Any ideas? Below is the code:
    <?xml version="1.0"?>
    <!-- Simple example to demonstrate the DateTimeAxis class. -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
         <mx:Script>
              <![CDATA[
                   import mx.collections.ArrayCollection;
                   [Bindable]
                   public var stockDataAC:ArrayCollection=new ArrayCollection([{date: "2005, 6, 1",
                             close: 30}, {date: "2005, 7, 31", close: 25}, {date: "2005, 8, 3",
                             close: 40}, {date: "2005, 9, 4", close: 30}, {date: "2005, 10, 5",
                             close: 50}, {date: "2005, 11, 6", close: 43}]);
                   private var d:Date=new Date("7/31/2005");
                   [Bindable]
                   private var offDays:Array=[d];
                   public function myParseFunction(s:String):Date
                        // Get an array of Strings from the comma-separated String passed in.
                        var a:Array=s.split(",");
                        // Create the new Date object. Subtract one from
                        // the month property because months are zero-based in
                        // the Date constructor.
                        var newDate:Date=new Date(a[0], a[1] - 1, a[2]);
                        return newDate;
              ]]>
         </mx:Script>
         <mx:Panel title="DateTimeAxis Example"
                     height="100%"
                     width="100%">
              <mx:LineChart id="mychart"
                               height="100%"
                               width="100%"
                               paddingRight="5"
                               paddingLeft="5"
                               showDataTips="true"
                               dataProvider="{stockDataAC}">
                   <mx:horizontalAxis>
                        <mx:DateTimeAxis dataUnits="days"
                                             parseFunction="myParseFunction"
                                             disabledRanges="{offDays}"
                                             labelUnits="months"/>
                   </mx:horizontalAxis>
                   <mx:verticalAxis>
                        <mx:LinearAxis baseAtZero="false"/>
                   </mx:verticalAxis>
                   <mx:series>
                        <mx:LineSeries yField="close"
                                          xField="date"
                                          displayName="AAPL"/>
                   </mx:series>
              </mx:LineChart>
         </mx:Panel>
    </mx:Application>

    I found your posted code to be messed up. I fixed it and could not see your problem.
    Here is the fixed code.
    <?xml version="1.0"?>
    <!-- Simple example to demonstrate the DateTimeAxis class. -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
         <mx:Script>
              <![CDATA[
                   import mx.collections.ArrayCollection;
                   [Bindable]
                   public var stockDataAC:ArrayCollection=new ArrayCollection([
                     {date: "2005, 6, 1", close: 30},
                     {date: "2005, 7, 31", close: 25},
                     {date: "2005, 8, 3", close: 40},
                     {date: "2005, 9, 4", close: 30},
                     {date: "2005, 10, 5", close: 50},
                     {date: "2005, 11, 6", close: 43}]);
                   private var d:Date=new Date(2005,8,31);
                   [Bindable]
                   private var offDays:Array=[d];
                   public function myParseFunction(s:String):Date
                        // Get an array of Strings from the comma-separated String passed in.
                        var a:Array=s.split(",");
                        // Create the new Date object. Subtract one from
                        // the month property because months are zero-based in
                        // the Date constructor.
                        var newDate:Date=new Date(a[0], a[1] - 1, a[2]);
                        return newDate;
              ]]>
         </mx:Script>
         <mx:Panel title="DateTimeAxis Example"
                     height="100%"
                     width="100%">
              <mx:LineChart id="mychart"
                               height="100%"
                               width="100%"
                               paddingRight="5"
                               paddingLeft="5"
                               showDataTips="true"
                               dataProvider="{stockDataAC}">
                   <mx:horizontalAxis>
                        <mx:DateTimeAxis dataUnits="days"
                                             parseFunction="myParseFunction"
                                             disabledRanges="{offDays}"
                                             labelUnits="months"/>
                   </mx:horizontalAxis>
                   <mx:verticalAxis>
                        <mx:LinearAxis baseAtZero="false"/>
                   </mx:verticalAxis>
                   <mx:series>
                        <mx:LineSeries yField="close"
                                          xField="date"
                                          displayName="AAPL"/>
                   </mx:series>
              </mx:LineChart>
         </mx:Panel>
    </mx:Application>
    If this post answers your question or helps, please mark it as such.
    Greg Lafrance - Flex 2 and 3 ACE certified
    www.ChikaraDev.com
    Flex / AIR Development, Training, and Support Services

  • How to send a text message to a group of people and save the list for next time?

    how to send a text message to a group of people and save the list for next time from an iphone 4s?

    Hey there ipremacha,
    It sounds like you need to enable Text Message Forwarding on your iPhone for your iPad to send MMS/SMS messages through your phone.
    Connect your iPhone, iPad, iPod touch, and Mac using Continuity
    Go to Messages > Text Message Forwarding, and enable the device(s) you would like to forward messages to.
    Your Mac, iPad, or iPod touch will display a code. Enter this code on your iPhone to verify the SMS feature.
    Thank you for using Apple Support Communities.
    Regards,
    Sterling

  • Nokia C3-01, suggestions for next S/W update

    I am using Nokia C3-01 from 2 weeks. It is nice phone with touch and type combination. I would like to add some suggestions for next software update.
    1.   Brightness control
    2.  When writing a text message, tapping # change only alphabet from capital to lower case, but missing numeric. I have to press 3-4 times to write numeric in text. Also have no 'option' to insert numeric. If I change other language (not English, which is automatic), then I can get numeric by tapping #. Nokia, please care it for next firmware update.
    Solved!
    Go to Solution.

    You can do a long press on the keys to get the numeric value instead of pressing it three to four times. This works for all Nokia since years, if they have keys  
    Or do a long press on the # key. This gives you the option to activate numeric input. Also a quite old feature for Nokia phones.

Maybe you are looking for

  • Insert order by records into a view with a instead of trigger

    Hi all, I have this DML query: INSERT INTO table_view t (a,                           b,                           c,                           d,                           e)       SELECT   a,                b,                c,                d,   

  • Can't find Lightroom 1.3 upgrade

    All the links I've found say I'm going to a download page for 1.3 (I'm on a Mac), but all I can see is 1.1 and 1.2. i.e Downloads center>Lightroom> Upgrade>Mac. All that visible are 1.1 and 1.2, even if the previous page mentions 1.3. Frustrating! An

  • Mavericks default location for "save as" on word and excel

    Having just installed Mavericks, it appears that if I open a Word or Excel file, and then go to "save as", rather than defaulting the save as location to the location the original file came from, it is now defaulting to my top level Documents folder.

  • Update Z-Field in EKPO with BAPI_PO_CHANGE

    Hello! I need to update my field - called ZSERNR - in the table EKPO. I found the FM BAPI_PO_CHANGE, but I do not know how it works. I tried it so, but I just get the message (table RETURN), that no datas got changed. I found some threads but I didn'

  • Aperture 3 adjustments presets help!!!!!

    HELP..... i  was using my aperture 3, and i always use the ready to use "adjustemnts presets" under the presets pop-up menu that come with program.However i somehow pressed delete and now there all gone ... which include the color preset, the white a