Sort drawing lines to a xy (out of a dxf)

hello all
i wrote a parser for dxf where i extract multiple line elements.
in the dxf, this lines together forms a countour, so the order of lines is unique to get the right visible output.
now, the dxf itself stores this lines in an own, random order (an unordered list).
i have to concatenate them by myself. as i want to show it in an xy graph, it is necessary to have the correct sort of circulation. otherwise crossing lines are shown (from an end of a line to the begin of another).
does anyone know, or already have, an existing algorithm to do this?
(taking an endpoint of a line, compare it with the both endpoints of all other lines, take the line with the nearest end, take this line out of the selection and starts again for the endpoint of this line)
thanks in advance for any help

picture is not possible, because i have to add the data to an existing xy graph (with zooming, alignment and a lot of other operations on it).
in meantime i think i have found the solution: between points in a plot where no line should be drawn, simply a 'Nan' can be inserted.
(http://forums.ni.com/t5/LabVIEW/How-to-create-Pen-up-and-Pen-down-option-in-X-Y-graph/m-p/1332722/hi...)
i will test it as soon as i am back in the office later....

Similar Messages

  • Sorting Invoice line items after they've been summed

    Hi,
    I'm working on a template for the out-of-box invoice using the XML it generates. The body of the document contains the line items, and I've successfully been able to print and sum (net amount and tax) these line items by Item Description and Unit Price using the following code:
    <?for-each@section:G_INVOICE?>
    <?for-each-group:G_LINE_TOTAL;./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE']?>
    <?for-each-group:current-group();./LIST_G_LINES/G_LINES/LINE_UNIT_SELLING_PRICE[../LINE_TYPE='LINE']?>
    <?./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE']?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_QTY_INVOICED[../LINE_TYPE='LINE'])?>
    <?./LIST_G_LINES/G_LINES/LINE_UNIT_SELLING_PRICE[../LINE_TYPE='LINE']?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_ITEM_AMOUNT[../LINE_TYPE='LINE'])?>
    <?sum(current-group()/./LIST_G_LINES/G_LINES/LINE_EXTENDED_AMOUNT[../LINE_TYPE='TAX'])?>
    What I need to do now is also SORT the summed line items by Item Description and Unit Price, but everything I've tried is giving me errors.
    One thing I've tried is adding the SORT command to the element that is printing the Item Description as in the following:
    <?sort:./LIST_G_LINES/G_LINES/LINE_ITEM_DESCRIPTION[../LINE_TYPE='LINE'];'ascending';data-type='text'?>
    I've also tried adding a separate field to do the sorting, but I'm getting different errors then.
    Thanks in advance for any suggestions.

    Thanks! This helped to some extent.
    Adding the sort for the LINE_ITEM_DESCRIPTION after the for-each-group for it worked to sort the lines by item description, but when I added the sort command for the LINE_UNIT_SELLING_PRICE within its for-each-group, I get the following error:
    FOProcessor setLocale: en-us
    java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeProcessXSL(XSLT10gR1.java:593)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:390)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:208)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:161)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:1019)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:972)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:211)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1577)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:952)
         at RTF2PDF.runRTFto(RTF2PDF.java:626)
         at RTF2PDF.runXDO(RTF2PDF.java:460)
         at RTF2PDF.main(RTF2PDF.java:251)
    Caused by: java.util.EmptyStackException
         at java.util.Stack.peek(Unknown Source)
         at java.util.Stack.pop(Unknown Source)
         at oracle.xdo.parser.v2.XSLTContext.popCurrentGroupingKey(XSLTContext.java:905)
         at oracle.xdo.parser.v2.XSLForEachGroup.processGroups(XSLForEachGroup.java:468)
         at oracle.xdo.parser.v2.XSLForEachGroup.process01(XSLForEachGroup.java:282)
         at oracle.xdo.parser.v2.XSLForEachGroup.process(XSLForEachGroup.java:210)
         at oracle.xdo.parser.v2.XSLForEachGroup.processAction(XSLForEachGroup.java:94)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLForEachGroup.processGroups(XSLForEachGroup.java:465)
         at oracle.xdo.parser.v2.XSLForEachGroup.process01(XSLForEachGroup.java:282)
         at oracle.xdo.parser.v2.XSLForEachGroup.process(XSLForEachGroup.java:210)
         at oracle.xdo.parser.v2.XSLForEachGroup.processAction(XSLForEachGroup.java:94)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLForEach.processAction(XSLForEach.java:142)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLResultElement.processAction(XSLResultElement.java:180)
         at oracle.xdo.parser.v2.XSLNode.processChildren(XSLNode.java:417)
         at oracle.xdo.parser.v2.XSLTemplate.processAction(XSLTemplate.java:191)
         at oracle.xdo.parser.v2.XSLStylesheet.execute(XSLStylesheet.java:508)
         at oracle.xdo.parser.v2.XSLStylesheet.execute(XSLStylesheet.java:485)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:264)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:150)
         at oracle.xdo.parser.v2.XSLProcessor.processXSL(XSLProcessor.java:187)
         ... 16 more
    I would appreciate to know what is wrong with this and, also, how to interpret these errors.....is there any sort of error code manual?

  • SmartForms - draw line in template

    Hi!
      I am new to SF, so have a question on drawing line in a template. I use template as the data is only printed out once and is static. I have many columns in my template and I would like to draw lines on the columns so that it is tidy & looks nicer.
      I double click the template & in the "output options" tab, I checked the check box "line with..", but error prompt out to stop me, saying "Boxes/Shadings are not allowed within a table".
      Does anyone know how can I draw lines in a template?
      Kindly advise.
    best regards,
    Ginnie

    Hi,
             Click on the template under the template tab, and then click on the select pattern just under the template heading , there you use lines.
    regards,
    Santosh Thorat
    Edited by: santosh thorat on Dec 26, 2007 10:09 AM

  • Draw line in illustrator cs2

    hi,
    i am new to adobe illustrator cs2.
    is there any other method to draw line other than s
    setEntirePath().
    thanks in advance,

    Hello David,
    It sounds to me like you're witnessing the double edged sword of an incredibly sharp display. The contrast and clarity of LCD displays makes it very easy to see razor-thin lines with ultra fine definition, but this comes at a cost.
    Font smoothing (a.k.a. font aliasing) is one example of where most LCDs are so sharp that most people prefer to have their text "fuzzed" up a little bit.
    A one pixel wide diagonal line is another example that you've discovered - the display is so sharp that there is no blurring around the "steps" of the line. You can see every change in gradient, because as sharp as your CRT might've been, it was blurring the line just slightly - enough to enhance the illusion that your diagonal line was a line rather than a series of adjacent "steps". No software package that I know of has bothered to implement "line smoothing" yet, probably because you need the detail for accuracy when putting lines together.
    Sort of related to this, big screen HDTV plasma and LCD monitors look amazing in the store when tuned to an HD station, but most people would be floored if they say how grainy and pixelated a standard cable signal looks on the same display. It's literally like watching an old VHS tape, because the display is so sharp it resolves detail that is invisible on a "lesser" display.
    Neat human trick: get used to working with your LCD, and then go back to the CRT if you have a chance. How does the CRT look? I thought I needed glasses the first time I switched back!
    -Shawn

  • Need to draw line after the 2nd line item(Smart Forms)

    Dear Friends,
    I need to draw horizontal line after the 2nd line item  and 3rd line item in smart forms.How can i achive this.
    Plz help.
    Edited by: farook shaik on May 19, 2009 8:19 AM

    This is what you need to do:
    1> In the tables->details section define two line types LT1 and LT2.
    2> Come back to tables section pressing the table painter button.
    3> Select a line type for which you want to have an underline(say LT2).
         a] If the anchor cursor does not come click the draw lines and columns button( the pencil icon nutton)
         b] select the line type ( it will become black after selection. Press and hold down ctrl to select
             multiple cells.
         c] after selection click the lower 'frame button' ( which is right at the top of box and shading).
    4> Now goto data section where you have given your internal table name and work area.
         a] in the sort criteria put your field POSNR and check the Event on Sort end chk box.
         b] you will see an extra node under the main area of the table.
         c] Create a table line with the line type LT2 in the node.
         d]Also in the Main area add another table line with LT1 as the line type.
    5> If POSNR remains unchnged LT1 will be triggered.
    6> if Posnr changes then LT2 will be triggered with the underline.
    This will suffice your requirement.

  • Draw line with Gradient

    Hi,
    I am trying to implement drawing on canvas with two colors, red and blue.
    For example, to draw with the mouse "with two colors".
    I do not need a filled rectangle.
    I am looking into gradient but without any success.
    Is there a better way to draw a line with two colors?
    I also tried to use BasicStroke, but the line had an inner/outer strokes.
    Please help with suggestions.

    devboris wrote:
    ..For example, to draw with the mouse "with two colors".
    import java.awt.*;
    import javax.swing.*;
    class GradientLine {
        public static void main(String[] args) {
            GradientPanel gp = new GradientPanel();
            gp.setPreferredSize( new Dimension(600,400) );
            JOptionPane.showMessageDialog(null, gp);
    class GradientPanel extends JPanel {
        public void paintComponent(Graphics g) {
            // cast the Graphics objkect to a Graphics2D object
            // (G2D includes setPaint() method)
            Graphics2D g2 = (Graphics2D)g;
            GradientPaint bgPaint = new GradientPaint(
                0,
                0,
                Color.black,
                getWidth(),
                getHeight(),
                Color.white );
            g2.setPaint(bgPaint);
            g2.fillRect( 0, 0, getWidth(), getHeight() );
            GradientPaint fgPaint = new GradientPaint(
                0,
                0,
                Color.yellow,
                getWidth(),
                getHeight(),
                Color.red );
            // set the paint to a gradient.
            g2.setPaint(fgPaint);
            for (int ii=0; ii<getWidth()/10; ii++) {
                g2.drawLine( ii*10, 0, ii*10, getHeight() );
            for (int ii=0; ii<getHeight()/10; ii++) {
                g2.drawLine( 0, ii*15, getWidth(), ii*15 );
    }

  • Draw line(s)

    Hi,
    I am wondering how can I draw lines b/w two points. I assume there should be spatial function where I can pass lat,lon of first and second point.......
    any help is appreciated.
    Al

    You can use Luc's function, but it's quite easy to insert newly created geometry:
    INSERT INTO cola_markets VALUES(
    2,
    'cola_b',
    SDO_GEOMETRY(
    2002, -- two-dimensional line
    NULL, -- SRID - identifies coordinate system
    NULL, -- If it's a point, you can put that here
    SDO_ELEM_INFO_ARRAY(1,2,1), -- single line, points connected by straight lines
    SDO_ORDINATE_ARRAY(5,1, 8,1)
    and it's not that difficult to create a function that you call which takes 4 parameters (x1,y1,x2,y2) which calls something like the above statement.
    If you have WKT or WKB (Well Known Text or Well Known Binary info, you can use these:
    SDO_GEOMETRY(wkt CLOB, srid NUMBER DEFAULT NULL);
    SDO_GEOMETRY(wkt VARCHAR2, srid NUMBER DEFAULT NULL);
    SDO_GEOMETRY(wkb BLOB, srid NUMBER DEFAULT NULL);
    But there is no specific function to 'draw' a line (you can use third-party tools for that though, there's a lot of them out there that do offer graphical interfaces to Oracle Spatial Data).

  • How do you get a list of your contacts nick names and their phone numbers on line and print them out?

    How do you get a list of your contacts nick names and their phone numbers on line and print them out?  I've been trying to figure out how to get the list to print out but I can't even find a complete list to view on Verizon's web site.  Does anyone know how to do this?

    Log into your online account. In the, 'I want to', box type, Manage Contacts.
    Place your cursor over any contact, a pop screen will appear with the option to print your contacts

  • How to draw line on SAP form

    Hi everyone,
    Who have a good way to draw lines on SAP form?
    I created a Wizard form, and use Rectangle (Height=0) as the two lines between title and bottom button, but I met a problem, when show another form which cover the line, after close this form, some part of lines disappear, I have tried using SAP form refresh, it still can not restore showing line completely, who have good way to workaround the problem or give me another way to draw line.
    Thanks in advance!
    Kathy

    The only way I found to get a form looking really close to a standard B1 Wizard form is to use bitmaps.  I use 3 - one each for the top, bottom and left hand side.  The bitmaps include the line drawing and appropriate pictures/background colours.  I normally define these in the XML used to create the form as in the following example:-
    <item uid="PTOP" type="117" left="0" width="566" top="0" height="80" visible="1" enabled="1" from_pane="0" to_pane="0">
            <AutoManagedAttribute/>
            <specific picture="AZU_SPC_WIZ_TOP2.bmp">
                    <databind databound="0" table="" alias=""/>
            </specific>
    </item>
    <item uid="PBOT" type="117" left="0" width="566" top="336" height="40" visible="1" enabled="1" from_pane="0" to_pane="0">
            <AutoManagedAttribute/>
            <specific picture="AZU_SPC_WIZ_BOT.bmp">
                    <databind databound="0" table="" alias=""/>
            </specific>
    </item>
    <item uid="PLEFT" type="117" left="0" width="100" top="0" height="336" visible="1" enabled="1" from_pane="1" to_pane="1">
            <AutoManagedAttribute/>
            <specific picture="AZU_SPC_WIZ9.bmp">
                    <databind databound="0" table="" alias=""/>
            </specific>
    </item>
    John.

  • New line character in c:out

    hi!
    I need to print a string in a table , and i am using <c:ForEach> and <c:out> tags to retrieve the data from a session scoped collection. the problem is that i need the data to be printed with new line characters to separate paragraphs, but if i put <br> into the string that i want to print it prints the word <br> and when i look at the page code, it shows the <br>�s as
    How can i put new line characters using <c:out>?
    thanks!!!

    hi!
    I need to print a string in a table , and i am using
    <c:ForEach> and <c:out> tags to retrieve the data from
    a session scoped collection. the problem is that i
    need the data to be printed with new line characters
    to separate paragraphs, but if i put <br> into the
    string that i want to print it prints the word <br>
    and when i look at the page code, it shows the <br>?s
    as
    How can i put new line characters
    using <c:out>?
    thanks!!!ups , i mean , when i look at the page code it shows the <br> as & l t ; br / & g t ; (this is the problem)

  • Reducing PDF-size: automatic reduction of datapoints that are used to draw lines in a 2d-axis system within report

    Creating fancy pdf-files for costumers and other purposes is great. However, if the experimental data include many datapoints (>200000) a line-2d-graph ends up in a very big pdf-file. Especially when many pages need to be used.
    Explanation:
    When I use lines to show experimental data in 2d-plots the size of my PDF-file is directly influenced by the number of datapoints used. The more datapoints are used to draw lines within the graph, the bigger the exported PDF-files of the report are.
    It would be great to limit the number of points used to draw a line as it can be done with markers without using the curve transformation option. - Hence, e.g. plotting a line with the help of 200 datapoints is usually as good as showing the same line based on 200000 datapoints but the pdf-size is significantly reduced. You can imagine that when this would be done via the transformation option a long lasting script would be needed for each line to reduce the number of datapoints shown. Hence, the plotting within the report and the actualisation of data would need very long.
     

    Since a while DIAdem optimizes the size of exported PDF-files in a related way as it is suggested here. In principle the PDF-file is exported in a very high resolution, so you can display it in a reader with a very high zoom value (e. g. 6000 %) to look into details of your data. If you have a huge dataset, this could lead in fact to a bigger file size, if data points could be displayed because the high PDF-resolution. But in general, DIAdem only saves information in a PDF-file which is really necessary - but with a high resolution.

  • HTTP Receiver Adapter payload as single line plain text with out any tags.

    Hi PI experts,
    I have a strange problem in http receiver adapter.
    Sender RFC (SAP)  Receiver: HTTP.
    Receiver system expects the output from XI in the below format in a single line plain text with out any tags in the payload. and the content type should be application/x-www-form-urlencoded
    Group=Test&Sentinel=Web%20Server&Facility=5345&Order Number=XT-XWHM-Y-NA&Serial Number=123456&@LABEL_QUANTITY=5&@LABEL_NAME=111114_Q
    Is there any way to achieve this using http receiver adapter. Business is not ready to accept the output from XI not even in a single element instead they only need it as a JUST a plain text.
    Appreciate early response on this.
    Thanks in Advance,
    Jitender

    Dear Ola,
    Could you elaborate how you achieved in catching the response data from the receiver in case of HTTP receiver adapter?
    The target service is not a WebService but some python script that must to receive some paramters via POST request.
         HOW can I post this parameters?
    Here you entered the fields of the message type of the request in the header parameters of the receiver adapter? Thats fine.
    But what about the message type and vice versa of the response from the receiver?
    Regards
    Rebecca

  • I don't want to show the e-mail address in the "from" line when I send out e-mails.  Is there a way to hide that? Thank you!

    I don't want to show the e-mail address in the "from" line when I send out e-mails.  Is there a way to hide that?
    Thank you!

    No.

  • I would like to cut and paste information from a word file onto a pdf file, as well as draw lines onto the pdf file.  How can I accomplish that task?  Is there software I can purchase?

    I would like to cut and paste information from a word file onto a pdf file, as well as draw lines onto the pdf file.  How can I accomplish that task?  Is there software I can purchase?

    Hi jgallu7382,
    The latter is easily accomplished using the Drawing Markup tools, which are available in both the free Adobe Reader, and in Acrobat. Copying/pasting text into the PDF is something that you could do using the editing tools that are available only in Acrobat. Note, however, that Acrobat isn't intended to be a text-editing application, so editing there won't be as robust as in an application designed specifically for that purpose. (It's also worth mentioning that you won't be able to alter a PDF if it has document permissions applied that would prevent you from doing so.)
    I hope that answers your questions.
    Best,
    Sara

  • Problem in sorting tableview line item

    Hi,
    I have only one main page with with one tableview.
    For example, i have the fields in header say field1, field2, field3, field4, field5.
    When i click the header of the field say field2, it sorts the line item which is in table display w.r.t field2.
    But i intend to sort the internal table line item  , which is responsible to display the line item on page.
    Is it possible. If so how?
    Cheers
    RK

    Hi,
    You have to use SORT = "SERVER"  and in input processing validate the code:
    Please see the below example:
    In the view the code should something as below:
    <htmlb:tableView id="tv2"  table="<%=it_vbak%>"
                                          selectionMode     = "none"
                                         onHeaderClick    = "some"
                                         sort             = "SERVER"
                                         iterator        = "<%=controller%>" >
      <htmlb:tableViewColumn columnName="VBELN" > </htmlb:tableViewColumn>
      <htmlb:tableViewColumn columnName="ERDAT" > </htmlb:tableViewColumn>
      <htmlb:tableViewColumn columnName="ERZET" > </htmlb:tableViewColumn>
      <htmlb:tableViewColumn columnName="ANGDT"> </htmlb:tableViewColumn>
      <htmlb:tableViewColumn columnName="ERNAM"> </htmlb:tableViewColumn>
      <htmlb:tableViewColumn columnName="VBTYP" > </htmlb:tableViewColumn>
    </htmlb:tableView>
    In the event handler the code would be something as below:
    data: tv type ref to cl_htmlb_tableview.
    tv ?= cl_htmlb_manager=>get_data(
                            request      = runtime->server->request
                            name         = 'tableView'
                            id           = 'tv2' ).
    sort it_vbak by (tv->data->column_key).
    Bhavana.G

Maybe you are looking for

  • What do I need to support my FireWire 800 gear on a new iMac

    I need to replace my antique mac pro 1.1 I am now retired and my needs tend more towards games than av creation so the new Mac Pro is not only overkill but the dual video I here is not optimized for games in any case. The problem is all of my existin

  • Directv and airport extreme

    I'm trying to connect my directv receiver via ethernet to my airport extreme and the receiver isn"t find the proper settings.  I can connect my macbook with the same ethernet cable, so it is working.  Any suggestions or ideas?  Thanks in advance.

  • File to database adapter error

    I am trying to run the File2Database example shipped as part of database adapter samples.Though i have created the tables and modified oc4j-ra.xml as mentioned in readme file.I am getting merge error followed by table or view does not exist,but table

  • Can't open Outlook on mac

    I have been using outlook on my mac air form some time now and a couple of days ago it just wouldnt open,  this is the message I am getting, can anyone help ?

  • Three days to download updates; iPhoto, IMovie, Evernote

    Hi, I bought a MacBook air approx 3 months ago (a mid-2011model recently and within a month/6weeks the new one & Pro were out - not happy). OS is Lion. I have had trouble downloading updates since I got it. I tried, tried and tried again. Constantly