Purchase Order with Sub-Purchase Order?

Hello,
We are trying to purchase a box from vendor 1, have vendor 1 ship the box to vendor 2, and then have vendor 2 add some additional components and then ship the finished material to us.
Can anyone help me with this scenario from a Purchasing point of view?  I only have a purchase requisition for the finished box.
Thanks very much,
Timothy

Hello Timothy
This process is called Subcontracting with Third-Party Order Processing and you can map it using MRP areas.
Take a look on the following link from the on-line help, where this process is described in detail:
Subcontracting/Third-Party Order Processing - Special Planning Processes - SAP Library
BR
Caetano

Similar Messages

  • Cs 6 blu-ray with sub menus, only go back to main menu

    I have burned a blu-ray with a main menu then sub menus: audio setup, chapters, extras.
    (note: they are regular menus NOT pop-up menus and I would rather not do pop-up menus at this time)
    when I am playing any of the sub menu content (trailer or making of or picking a chapter button from the chapter menu etc...) and press the menu button on the Blu-Ray player while it plays that content, it goes to the main menu instead of the sub menu.
    I checked it in the simulator and it was working perfectly....just as I would expect it to.
    each sub menu item (a trailer or making of featurette for example) is set to go back to the sub menu and it's button
    when done playing...and it does. 
    It just refuses to do that when the menu button on a blu-ray player is used and instead goes to the main menu.
    I ran the link checker before building the folders and burning it...no conflicts found.
    This seems to be an issue with Encore in general, reading about this here and in
    other forums.
    Can Encore simply not create a proper blu-ray disc with sub-menu's you can
    return to when the menu button on a remote is pressed?
    Do I have to buy BluStreak in order to correct these rather obvious navigation errors?

    Let us know what you find.
    I think the original poster in the other thread observed that commercial BDs were showing the same behavior.
    Even if true, it does not mean that some kind of scripting might not work.
    But Encore would not have the option.

  • 'Contacts' folder with sub folder cannot be removed after synching via iTunes

    'Contacts' folder with sub folder cannot be removed after synching via iTunes
    I am trying to remove a 'Contacts' subfolder
    ie Contacts < default folder
    - Contacts Mysubfolder 1 < Trying to remove this subfolder folder
    via my microsoft outlook onto my iPhone.
    Despite not having 'Contacts Mysubfolder 1' on my PC's outlook after deleting it, it does not delete the subfolder in my iPhone.
    I even restored my iPhone settings to the original via iTunes.
    I also replaced my physical iPhone but still synching with my original Apple ID + iTunes on the same desktop.
    All I did was after replacement of my iP, i setup my microsoft Exchange account, and there it was, the Contacts subfolder which is no longer around, appears on my iPhone contacts folder list.
    My outlook is on Microsoft exchange and I am on iP 3Gs
    Please help
    Thank you

    For general advice see Troubleshooting issues with iTunes for Windows updates.
    The steps in the second box are a guide to removing everything related to iTunes and then rebuilding it which is often a good starting point unless the symptoms indicate a more specific approach. Review the other boxes and the list of support documents further down the page in case one of them applies.
    Your library should be unaffected by these steps but there is backup and recovery advice elsewhere in the user tip.
    If you are running 64-bit Windows and the above steps haven't helped try installing the version of iTunes that can be downloaded from this support document. iTunes 12.1 for Windows (64-bit — for older video cards)
    If you still have no luck try reinstalling iTunes 12.0, links in the user tip.
    tt2

  • How to create folder with sub folder ?

    How to create folder with sub folder ?

    Hi,
    Questions. 17 / 17 unresolved -> very bad reputation
    but ok - let's help anyway ...
    1. create everything in Screen Painter
    2. set FromPane and ToPane property correct.
    example:
    Items in MainFolder: FromPane & ToPane: 1 to 3
    Items in SubFolderA (From 2 To 2) - SubFolderB (From 3 To 3)
    shouldn't be that difficult
    in your Code set oForm.PaneLevel when the user clicks on the Folder
    lg David

  • Problem with sub-screen actions on Cancel button

    Hi all,
    I have a problem with sub-screen.
    I created a subscreen (screen sequence in MM01/MM02/MM03). When users leave this screen, I call POPUP_TO_CONFIRM to ask if they want to save the data.
    1) My goal is: when they choose Cancel, no actions are performed and users will see the current screen. However, I cannot use command: SET SCREEN 0 or LEAVE TO SCREEN 0 because the system gives an error message:
    *SET SCREEN not allowed in subscreens*.
    2) How can we determine when the user leaves the screen? which value of SY-UCOMM will be used to check this?
    Thanks in advance.

    for dis SET SCREEN is not required.
    Consider d code given below as n eg:
    CALL FUNCTION 'POPUP_TO_CONFIRM'
        EXPORTING
          titlebar              = 'SAVE'
          text_question         = 'SOME _QUS'
          text_button_1         = 'YES'
          text_button_2         = 'NO'
          default_button        = '2'
          display_cancel_button = ' '
        IMPORTING
          answer                = l_ans
        EXCEPTIONS
          text_not_found        = 1
          OTHERS                = 2.
      IF sy-subrc <> 0.
        MESSAGE e066.
      ENDIF.
    IF l_ans EQ '1'.    " when yes is pressed
       MODIFY db.
       commit work.
       leave program.
    ELSEIF l_ans EQ '2'.  "when no is pressed
        leave program.
    ELSE.     " when cancel is pressed
    ENDIF.
    In above module when Yes is pressed it saves data den leave prog.
    As no action is specified for cancel button it will remain on that screen only from which popup is called, in this way ur problem can be solved.
    Reward properly.

  • Simple BOM with sub-items (very very urgent)--1 item & 2 subitem

    Hi all,
    i am creating a BOM with sub-items using  'BAPI_MATERIAL_BOM_GROUP_CREATE'. while  creating sub-item, it is taking only one subitem. but i am giving multiple sub-items per item.
    i am giving a program where i am assigning 2 subitems to one item.
    after tha bapi call, 1 subitem is creating.
    i have tried so many times by clearing the work area & calling the bapi for each sub-item.but it is creating only one sub-item only.
    i am giving an example of my report.plz correct it if i am wrong.it is veryt very urgent.
    any idea will be highly appreaciated.
    Regards
    pabitra
    REPORT ZTEST_CHIN message-id 01.
    This code will create a material BoM for the material
    MAINMATERIAL with the components COMPON1 and COMPON2.
    Data Declaration
    DATA:
        it_bomgroup LIKE bapi1080_bgr_c OCCURS 0 WITH HEADER LINE,
        it_variants LIKE bapi1080_bom_c OCCURS 0 WITH HEADER LINE,
        it_items LIKE bapi1080_itm_c OCCURS 0 WITH HEADER LINE,
        it_matrel LIKE bapi1080_mbm_c OCCURS 0 WITH HEADER LINE,
        it_itemas LIKE bapi1080_rel_itm_bom_c OCCURS 0 WITH HEADER LINE,
        it_return LIKE bapiret2 OCCURS 0 WITH HEADER LINE,
        it_subitems LIKE bapi1080_sui_c OCCURS 0 WITH HEADER LINE,
        it_subitemas LIKE BAPI1080_REL_SUI_ITM_C OCCURS 0 WITH HEADER LINE.
    Fill the data
    Material BoM Group Header Data
    CLEAR it_bomgroup.
    it_bomgroup-bom_group_identification = 'BAPI_SMP_COL1'.
    it_bomgroup-object_type = 'BGR'.
    it_bomgroup-object_id = 'SIMPLE1'.
    it_bomgroup-bom_usage = '1'.  " YOU COULD CHANGE THE BOM USAGE TO YOUR
    it_bomgroup-ltxt_lang = sy-langu.
    it_bomgroup-technical_type = ' '.
    it_bomgroup-bom_text = 'Simple BoM - FM'.
    APPEND it_bomgroup.
    Header Details of the different variants
    CLEAR it_variants.
    it_variants-bom_group_identification = 'BAPI_SMP_COL1'.
    it_variants-object_type = 'BOM'.
    it_variants-object_id = 'SIMPLE1'.
    it_variants-alternative_bom = '01'.
    it_variants-bom_status = '01'.
    it_variants-base_qty = '1.000'.
    it_variants-valid_from_date = sy-datum.
    it_variants-function = 'NEW'.
    APPEND it_variants.
    Details of the materials of the different variants
    CLEAR it_matrel.
    it_matrel-bom_group_identification = 'BAPI_SMP_COL1'.
    it_matrel-material = 'BAPIBOMFG1'.
    it_matrel-bom_usage = '1'.
    it_matrel-alternative_bom = '01'.
    APPEND it_matrel.
    Linking subitems to the corresponding variants
    CLEAR it_subitemas.
    it_subitemas-bom_group_identification = 'BAPI_SMP_COL1'.
    it_subitemas-sub_object_type = 'SUI'.
    it_subitemas-sub_object_id = 'SIM1'.
    it_subitemas-super_object_type = 'ITM'.
    it_subitemas-super_object_id = 'SIMPLE1'.
    APPEND it_subitemas.
    Linking items to the corresponding variants
    CLEAR it_itemas.
    it_itemas-bom_group_identification = 'BAPI_SMP_COL1'.
    it_itemas-sub_object_type = 'ITM'.
    it_itemas-sub_object_id = 'SIMPLE1'.
    it_itemas-super_object_type = 'BOM'.
    it_itemas-super_object_id = 'SIMPLE1'.
    it_itemas-valid_from_date = sy-datum.
    it_itemas-function = 'NEW'.
    APPEND it_itemas.
    Details of the items of the variants
    CLEAR it_items.
    it_items-bom_group_identification = 'BAPI_SMP_COL1'.
    it_items-object_type = 'ITM'.
    it_items-object_id = 'SIMPLE1'.
    it_items-item_no = '0010'.
    it_items-item_cat = 'L'.
    it_items-component = 'BAPIBOMRW1'.
    it_items-comp_qty = '2'.
    it_items-valid_from_date = sy-datum.
    APPEND it_items.
    CLEAR it_subitems.
    it_subitems-bom_group_identification = 'BAPI_SMP_COL1'.
    it_subitems-object_type = 'SUI'.
    it_subitems-object_id = 'SIM1'.
    it_subitems-subitem_no = '0001'.
    it_subitems-INSTALLATION_POINT = 'ab1'.
    it_subitems-subitem_qty = '1'.
    APPEND it_subitems.
    CALL FUNCTION 'BAPI_MATERIAL_BOM_GROUP_CREATE'
      EXPORTING
        all_error         = 'X'
      TABLES
        bomgroup          = it_bomgroup
        variants          = it_variants
        items             = it_items
        materialrelations = it_matrel
        itemassignments   = it_itemas
        subitems          = it_subitems
        subitemassignments = it_subitemas
        return            = it_return.
    CLEAR it_subitems.
    it_subitems-bom_group_identification = 'BAPI_SMP_COL1'.
    it_subitems-object_type = 'SUI'.
    it_subitems-object_id = 'SIM1'.
    it_subitems-subitem_no = '0002'.
    it_subitems-INSTALLATION_POINT = 'ab2'.
    it_subitems-subitem_qty = '1'.
    APPEND it_subitems.
    CALL FUNCTION 'BAPI_MATERIAL_BOM_GROUP_CREATE'
      EXPORTING
        all_error         = 'X'
      TABLES
        bomgroup          = it_bomgroup
        variants          = it_variants
        items             = it_items
        materialrelations = it_matrel
        itemassignments   = it_itemas
        subitems          = it_subitems
        subitemassignments = it_subitemas
        return            = it_return.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    LOOP AT it_return.
      WRITE:/ it_return-type, it_return-id, it_return-number,
              it_return-message.
    ENDLOOP.

    Hi rich,
    Thanks. i will do the same.can u plz suggest me , where i am doing mistake in my coding to create sub-items in a BOM?
    Thanks & Regards
    pabi

  • Vi's with sub panel

    hi
    i want to run an aplication on fp-2010 which have sub panels(panel embedding)
    but i got the following problems
    1.vi's with sub panel are not loaded on fp-2010
    2.and not supported by Lab VIEW Real Time
    can any one help me in this regard or suggest any other method that i run my application with fp-2010
    OR can i use any other tecnique which give the same functionality as sub panels and compatible Lab VIEW Real Time
    regards
    mazhar

    duplicate post

  • HT4623 i have installed ios7 and when 'i agree to terms' etc, with sub menu....nothing happens. please tell me if i have missed something

    i have installed ios7 and when 'i agree to terms' etc, with sub menu....nothing happens. please tell me if i have missed something

    By the way, the safari setting is: private browsing off and accept cookies from visited. Much help is appreciated!

  • Importing Main Folders with Sub-folders

    I am a new Mac user and I am trying to import my photos into iPhoto6.0. I have created main folders with sub-folders (eg. Main Folder = Holiday, Sub-folder = Australia Trip) and would like the sub-folders to appear when I open iPhoto. However, I cannot seem to get the main folder or sub-folder names to appear in iPhoto. The photos just get imported into the library and segregated by year.
    I tried reading the forum, and seem to infer that iPhoto cannot handle sub-folder names. However, when I read iPhoto 6.0 Help page, it states:
    "You can also drag individual photos or an entire folder from the Finder into iPhoto's photo viewing area. If you drag a folder, a film roll is created with the folder's name. If the folder you import contains subfolders, film rolls are created with each subfolder's name."
    I tried the above, but I don't seem to manage to get the film rolls named as described.
    Please help!!
    MacBook   Mac OS X (10.4.8)  

    Could it be confusion with what you are viewing in the iPhoto window?
    iPhoto always shows you a "last roll", which is really more like a smart album than a Film Roll. It is simply a quick way to find the photos from your most recent import session. When I drag in 2 folders to import, it only shows the second folder when I select "last roll." Are you seeing photos from one of your folders, or both of them together?
    Select "Library" from the top of your Source Pane to see your entire library. It doesn't mattter if you already have photos in your library or if you're beginning fresh. Under the "View" menu, select "Film Rolls" so that it is checked. Also under View, select "Sort Photos" > "by Film Roll". Now try to select the name/icon of 2 folders in Finder, then drag over the iPhoto window onto where the thumbnails display your library. (Or display nothing, if your library is empty.) Release when the curser is a green plus sign. When the import is finished you should see the 2 folder names (now as rolls) each with a set of thumbnails below it. Check the slider near the bottom right of the iPhoto window; moving it all the way to the left will give you the smallest thumbnails and allow you to see more photos at once.
    Please try this again and let me know how it goes. If this does not solve it, then I can tell you how to check what's in your library. But the Film Roll view should work.

  • Working with Sub Menus

    I've been having some issues with the latest version of iDVD 7.0.1 in working with sub menus. Sometimes I need a sub menu button to click through to 1 full screen still image with the option to hit the "back button" to get to the main menu. How I've been doing this is when in the main menu, I click "add sub menu," then it brings me to a new menu where I can drop something in the drop zone, etc. I bring my full screen static image in and drop it while holding down the option or cntl key, which gets rid of the drop zones and gives me a full screen image. This has worked fine for me in the past. But now I get issues where the "back" button won't work to get back to the main menu. The "back" button simply flashes and won't let me select it once the disc has been burned.
    Am I going about this all wrong? Should I be utilizing the slideshow function instead?
    Thanks in advance!

    Needless to say, it had been a while since I sorted through my hotmail account. Last I looked I had 861 messages and I was starting to feel a bit like Jim Carrey in the movie Bruce Almighty....
    Better late than never.

  • How do we create a a main podcast category with sub-categories similar to the way many bands have subcategories and artwork for each of their albums?

    How does a content producer create a main category with sub-categories similar to the way many bands have subcategories and artwork for each of their albums?

    I think you're talking about an 'Artist Page' in which several podcasts are 'aggregated' into one iTunes Store page?  This Apple Tech note deals with the subject (scroll to the bottom of the page):
    http://www.apple.com/itunes/podcasts/creatorfaq.html
    Although your mention of albums makes me wonder whether there you are talking about albums and songs in the music Library? - podcasts don't come in albums.
    You've also asked this in another forum:
    I have created a feed for our podcasts, but they are all under one umbrella. We would like to have subcategories under one main category.
    'A feed for your podcasts' doesn't make sense - a podcast has one feed (and vice versa). Are you confusing 'episodes' with 'podcasts'? A podcast is a collection of episodes - you can't categorize the episodes separately. The category shows only on the Store page and applies to the entire podcast. The 'Artist' page may again be what you are aiming for - if not perhaps you could post an example of what someone else is doing that you would like to.

  • 2 domain, each with 2 way transitive truts, with sub domains pointing to the same DNS server (how should forward and reserver look zone be configured)

    Hello,
    I found a test environment and I just trying to understand how it works.
    If I have two domains (a.com and b.com) with sub domains(a1.com and b1.com) with two way trust and I want them to point to a Windows DNS server. How should the Forward lookup zones and Reverse lookup zones be configured? In forward lookup
    zones do I just add a new zone, make them all primary since only one DNS server, add a.com and b.com and do the same for reverse zones.
    Do the sub domains need to be added? What about pointers? Do I add the IP address of a.com and b.com in reverse lookup zones.
    A side question: When you create a Domain with dns AD intergrated the forward and reserve lookup are automatically created. You don't need to add the zone of the domain you just created but have to add zones of other domains.

    Hello,
    I found a test environment and I just trying to understand how it works.
    If I have two domains (a.com and b.com) with sub domains(a1.com and b1.com) with two way trust and I want them to point to a Windows DNS server. How should the Forward lookup zones and Reverse lookup zones be configured? In forward lookup
    zones do I just add a new zone, make them all primary since only one DNS server, add a.com and b.com and do the same for reverse zones.
    Do the sub domains need to be added? What about pointers? Do I add the IP address of a.com and b.com in reverse lookup zones.
    A side question: When you create a Domain with dns AD intergrated the forward and reserve lookup are automatically created. You don't need to add the zone of the domain you just created but have to add zones of other domains.
    Make each domain controller as a DNS server too. Reverse lookup zones & forwarders are not replicated automatically. You can create AD-Integrated reverse lookup zone & set the replication scope.
    You can create AD-Integrated DNS zones in the parent/root domain, set the replication scope to the forest-wide & delegate the zones for handling request locally. Once you create AD-Integrated DNS zone & set the replication scope forest wide, all
    the zones will appear automatically in each domain's DNS server.
    http://awinish.wordpress.com/2011/04/09/configuring-dns-in-child-domain/
    Awinish Vishwakarma - MVP
    My Blog: awinish.wordpress.com
    Disclaimer This posting is provided AS-IS with no warranties/guarantees and confers no rights.

  • Excess material remain with sub contracting vendor

    HI expert
    I have made subcontracting po for which migo, miro had done, we had made manual BOM in the po, usually my BOM ratio 1:1, But now end user had done mistake, by taking 1:3 ratio, tht mean for 100 he taken  300. My 200 stock I lying with sub contractor, I want to take it back that 200.
    I donu2019t want to reverse any thing from the system, is there any solution for the above except reverse
    how should i go about
    Regard
    Nabil

    Use 542 mvt type and provide vendor in MB1B transaction to get material back to your plant.

  • All navigational subheadings near top of screen in previous version of ff disappeared when installed ff4. they included Wikipidia, news(with sub-options LA times, NY times,BBC etc), YouTube, mail & others. how do i recover previous version?

    all navigational subheadings near top of screen in previous version of ff disappeared when installed ff4. they included wikipedia, news(with sub-options LA times, NY times, BBC etc),YouTube, mail & others. how do i recover previous version?

    You are welcome. I'm glad you got it back up.
    (1) You say you did the symbolic link. I will assume this is set correctly; it's very important that it is.
    (2) I don't know what you mean by "Been feeding the [email protected] for several weeks now, 700 emails each day at least." After the initial training period, SpamAssassin doesn't learn from mail it has already processed correctly. At this point, you only need to teach SpamAssassin when it is wrong. [email protected] should only be getting spam that is being passed as clean. Likewise, [email protected] should only be getting legitimate mail that is being flagged as junk. You are redirecting mail to both [email protected] and [email protected] ... right? SpamAssassin needs both.
    (3) Next, as I said before, you need to implement those "Frontline spam defense for Mac OS X Server." Once you have that done and issue "postfix reload" you can look at your SMTP log in Server Admin and watch as Postfix blocks one piece of junk mail after another. It's kind of cool.
    (4) Add some SARE rules:
    Visit http://www.rulesemporium.com/rules.htm and download the following rules:
    70sareadult.cf
    70saregenlsubj0.cf
    70sareheader0.cf
    70sarehtml0.cf
    70sareobfu0.cf
    70sareoem.cf
    70sarespoof.cf
    70sarestocks.cf
    70sareunsub.cf
    72sare_redirectpost
    Visit http://www.rulesemporium.com/other-rules.htm and download the following rules:
    backhair.cf
    bogus-virus-warnings.cf
    chickenpox.cf
    weeds.cf
    Copy these rules to /etc/mail/spamassassin/
    Then stop and restart mail services.
    There are other things you can do, and you'll find differing opinions about such things. In general, I think implementing the "Frontline spam defense for Mac OS X Server" and adding the SARE rules will help a lot. Good luck!

  • HTMLDocument ending with SUB TAG=bad formatting

    Hi, I have a problem when tring to format text in JTextPane in HTMLDocument. When the text ends with </SUB> and I call document..setCharacterAttributes(0, doc.getLength(), attrs, false) text formatting goes wrong!!
    Why? Is it not possible to end text in document with "text<SUB>sub text</SUB>"?
    I prepared some sample code below, which should clarify what I want. Click one of 4 buttons to setText, then click repeatedly Format button to change its format.
    I want to know what am I doing wrong and how to do it right. Problem lies in calling method setCharacterAttributes. When changing its parameters I get different formattings, and not the one I expect :-( .
    When the formatting goes wrong all characters are put inside SUB tag. HTML code then looks like this:
    <html>
      <head>
        <font color="#000000" size="4" face="Arial"><sub>//<--This SUB tag is is added too
    </sub></font>  </head>
      <body>
        <font color="#000000" size="4" face="Arial"><sub>text that had many sub tags and now has none and is inside this sub tag, when this tag shouldnt exist</sub></font>
      </body>
    </html>Please HELP!!!
    Sample code below
    import javax.swing.text.*;
    import java.awt.*;
    import javax.swing.text.html.*;
    import javax.swing.text.html.HTML.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class Example extends JFrame {
      JScrollPane sp;
      JTextPane textPane = new JTextPane();
      HTMLEditorKit htmlKit;
      JButton text1Button = new JButton("short SUB text");
      JButton text2Button = new JButton("long SUB text");
      JButton text3Button = new JButton("long SUB text ending with text");
      JButton text4Button = new JButton("long normal text");
      JButton formatButton = new JButton("Format");
      StringBuffer text1,text2,text3,text4;
      Font font = new Font("Arial",Font.ITALIC,14);
      public Example() {
        this.setTitle("SUB TAG bad formatting Example");
        this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        this.setSize(700, 400);
        htmlKit = new HTMLEditorKit();
        HTMLDocument doc = (HTMLDocument)htmlKit.createDefaultDocument();
        textPane.setContentType("text/html");
        textPane.setEditorKit(htmlKit);
        textPane.setDocument(doc);
        sp = new JScrollPane(textPane,
                             JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
                             JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
        JPanel menuPanel = new JPanel();
        menuPanel.add(text1Button);
        menuPanel.add(text2Button);
        menuPanel.add(text3Button);
        menuPanel.add(text4Button);
        menuPanel.add(formatButton);
        text1Button.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            textPane.setText(text1.toString());
        text2Button.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            textPane.setText(text2.toString());
        text3Button.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            textPane.setText(text3.toString());
        text4Button.addActionListener(new ActionListener() {
         public void actionPerformed(ActionEvent e) {
           textPane.setText(text4.toString());
        formatButton.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent e) {
            setJTextPaneFont(textPane,font,new Color((float)Math.random(),(float)Math.random(),(float)Math.random()));
        text1 = new StringBuffer();
        for (int i=1;i<10;i++) {
          text1.append("a<SUB>"+i+"</SUB> ");
        //text1.append("<BR>");//<--Add this line to get it working, however moving cursor behind any number and pressing Format, results same format error
        text2 = new StringBuffer();
        for (int i=1;i<1000;i++) {
          text2.append("a<SUB>"+i+"</SUB> ");
        //text2.append("<BR>");//<--Add this line to get it working, however moving cursor behind any number and pressing Format, results same format error
        text3 = new StringBuffer();
        text3.append(text2+"END");//moving cursor behind any number in sub tag and pressing Format, results same format error
        text4 = new StringBuffer();
        for (int i=1;i<2000;i++) {
          text4.append("a_"+i+" ");
        JPanel mainPanel = new JPanel();
        mainPanel.setLayout(new BorderLayout());
        mainPanel.add(menuPanel,BorderLayout.NORTH);
        mainPanel.add(sp,BorderLayout.CENTER);
        this.getContentPane().setLayout(new BorderLayout());
        this.getContentPane().add(mainPanel,BorderLayout.CENTER);
      public static void setJTextPaneFont(JTextPane jtp, Font font, Color c) {
        MutableAttributeSet attrs = jtp.getInputAttributes();
        StyleConstants.setFontFamily(attrs, font.getFamily());
        StyleConstants.setFontSize(attrs, font.getSize());
        StyleConstants.setItalic(attrs, (font.getStyle() & Font.ITALIC) != 0);
        StyleConstants.setBold(attrs, (font.getStyle() & Font.BOLD) != 0);
        StyleConstants.setForeground(attrs, c);
        StyledDocument doc = jtp.getStyledDocument();
        doc.setCharacterAttributes(0, doc.getLength(), attrs, false);
      public static void main(String[] args) {
        Example frame = new Example();
        //Center the window
        Dimension frameSize = frame.getSize();
        Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
        if (frameSize.height > screenSize.height) {
          frameSize.height = screenSize.height;
        if (frameSize.width > screenSize.width) {
          frameSize.width = screenSize.width;
        frame.setLocation((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2);
        frame.setVisible(true);
    }

    Thanks for the dukes.
    Actually I have very little knowledge about html handling in java. On you particular problem, I just went and browsed through the source code in search for the sub tag (which I didn't know before by the way) to see what effect it had on the StyledDocument.
    As far as your performance problem in loading html pages, my best advice would be to conduct experiments and try to see where the bottleneck is. I know that there is a way to make setPage synchronous. It has to do with setting some variable in the Document (I guess searching the forum might help on this). This can make it easier to actually measure how long it takes. Moreover, you might want to try and load a small page first and then your heavy one : that way you'll know if it has to do with loading the classes of the HTMLEditorKit. Another advice would be to make sure you feed your JEditorPane with pure HMTL 3.2. I have no idea about this but maybe parsing unknown tags slows down the loading (pure guess). One last advice would be to make multiple versions of your file with slight modifications in each case (like remove the tables, for instance). That might help determine if it has anything to do with the actual content you're trying to load.

  • Request with sub-query

    I've a report with sub-query. I ran it separately to test it and it was fine. When I ran the whole report, I always get error with it.
    Could someome put some light on it?
    Thanks,
    Ted

    Hi,
    What is the error you are getting
    Regards
    MuRam

Maybe you are looking for