Proble with Custom JTable Header

Hi
I want create Custom JTable with JTextField on column header, so that user can enter some text. As of now i am able to create the text box on header using custom TableCellRenderer but i am not able to make it editable.....
Please help me. if any one need more info, pls let me know.

KetuRai wrote:
Then what should i do to achieve this functionality. Do any one have sample code?
Or other alternative to achieve this.I don't know If this is the best way but my approach is using a InputDialog and a custom renderer.
just click on the table header and input a text. Good Luck!
import java.awt.Color;
import java.awt.Component;
import javax.swing.*;
import javax.swing.table.*;
import java.awt.event.*;
public class TableHeaderDemo {
    public void createAndShowUI() {
        JFrame frame = new JFrame("Click Table Header to change text");
        String[] columnName = {"CheckBox Column", "Data Column"};
        Object[][] data = {{"Data 1", "Data 2"},
        {"Data 3", "Data 4"}, {"Data 5", "Data 6"}};
        final JTable myTable = new JTable(data, columnName);
        myTable.getTableHeader().setDefaultRenderer(new MyRenderer());
        myTable.getTableHeader().addMouseListener(new java.awt.event.MouseAdapter() {
            public void mousePressed(MouseEvent e) {
                int col = myTable.getTableHeader().columnAtPoint(e.getPoint());
                String str = javax.swing.JOptionPane.showInputDialog("Enter a text: ");
                myTable.getColumnModel().getColumn(col).setHeaderRenderer(new MyRenderer(str));
                myTable.getTableHeader().revalidate();
                myTable.getTableHeader().repaint();
        JScrollPane scrollPane = new JScrollPane(myTable);
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        frame.setResizable(false);
        frame.getContentPane().add(scrollPane);
        frame.pack();
        frame.setLocationRelativeTo(null);
        frame.setVisible(true);
    class MyRenderer implements TableCellRenderer {
        JTextField text = new JTextField();
        MyRenderer(String str) {
            text.setText(str);
        MyRenderer() {
        public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected,
                boolean hasFocus, int row, int column) {
            text.setBorder(BorderFactory.createRaisedBevelBorder());
            text.setBackground(Color.BLUE);
            text.setForeground(Color.WHITE);
            text.setHorizontalAlignment(JTextField.CENTER);
            return text;
    public static void main(String[] args){
        SwingUtilities.invokeLater(new Runnable() {
            public void run() {
                new TableHeaderDemo().createAndShowUI();
}

Similar Messages

  • F2 key not working with custom JTable Column

    I have a custom JTable Column (which is a JPanel with a JTextfield and JButton). Everything works as expected, except when the user presses "F2" to start editing the custom column cell. When the user presses F2, the custom cell goes into editing mode, but I am unable to type anything in it.
    Below is the SSCCE.
    Steps to Reproduce problem:
    1) Run the Program
    2) Select any cell in first Column.
    3) Press "F2" and try to type into the cell. Can't type anything.
    package com.ns;
    import java.awt.BorderLayout;
    import java.awt.Component;
    import java.awt.Dimension;
    import java.awt.Point;
    import java.awt.Toolkit;
    import java.awt.event.ActionEvent;
    import java.awt.event.KeyEvent;
    import java.util.EventObject;
    import javax.swing.DefaultCellEditor;
    import javax.swing.JButton;
    import javax.swing.JOptionPane;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.JTextField;
    import javax.swing.SwingUtilities;
    import javax.swing.UIManager;
    import javax.swing.WindowConstants;
    import javax.swing.table.DefaultTableModel;
    import javax.swing.table.TableCellRenderer;
    public class TextButtonCellFrame extends javax.swing.JFrame {
        // Variables declaration - do not modify                    
        private JTextField inputText;
        private JScrollPane jScrollPane1;
        private JPanel testPanel;
        private JTable testTable;
        // End of variables declaration                  
        public TextButtonCellFrame() {
            initComponents();
        @SuppressWarnings("unchecked")
        // <editor-fold defaultstate="collapsed" desc="Generated Code">                         
        private void initComponents() {
            testPanel = new JPanel();
            jScrollPane1 = new JScrollPane();
            testTable = new JTable();
            inputText = new JTextField();
            setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
            testTable.setModel(new DefaultTableModel(
                new Object [][] {
                    {null, null, null, null},
                    {null, null, null, null},
                    {null, null, null, null},
                    {null, null, null, null}
                new String [] {
                    "Title 1", "Title 2", "Title 3", "Title 4"
            testTable.setCellSelectionEnabled(true);
            testTable.setRowHeight(52);
            testTable.setSurrendersFocusOnKeystroke(true);
            testTable.getColumnModel().getColumn(0).setCellRenderer(new MyTableCellRenderer());
            testTable.getColumnModel().getColumn(0).setCellEditor(new MyTableCellEditor(new JTextField()));
            testTable.getColumnModel().getColumn(0).setPreferredWidth(200);
            jScrollPane1.setViewportView(testTable);
            testPanel.add(jScrollPane1);
            inputText.setPreferredSize(new Dimension(50, 20));
            testPanel.add(inputText);
            getContentPane().add(testPanel, BorderLayout.CENTER);
            Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
            setBounds((screenSize.width-576)/2, (screenSize.height-417)/2, 576, 417);
        }// </editor-fold>                       
        public static void main(String args[]) {
            java.awt.EventQueue.invokeLater(new Runnable() {
                public void run() {
                    new TextButtonCellFrame().setVisible(true);
        public class MyTableCellRenderer extends JPanel implements TableCellRenderer {
            Point point;
            JButton button1 = new JButton("Test 1");
            JTextField txtField = new JTextField();
            public MyTableCellRenderer() {
                setLayout(new BorderLayout());
                this.add(button1, BorderLayout.EAST);
                this.add(txtField,BorderLayout.CENTER);
            public Component getTableCellRendererComponent(JTable table, Object value,
                    boolean isSelected, boolean hasFocus, int rowIndex, int vColIndex) {
                if (isSelected) {
                    txtField.setBackground(testTable.getSelectionBackground());
                    txtField.setBorder(UIManager.getBorder("Table.focusCellHighlightBorder"));
                else {
                    txtField.setBackground(testTable.getBackground());
                    txtField.setBorder(null);
                return this;
        public class MyTableCellEditor extends DefaultCellEditor {
            JPanel panel = new JPanel();
            JButton button1 = new JButton ("Test 1");
            JTextField txtField;
            MyTableCellEditor(JTextField txtField) {
                super (txtField);
                this.txtField = txtField;
                panel.setLayout(new BorderLayout());
                panel.add(button1, BorderLayout.EAST);
                panel.add(txtField,BorderLayout.CENTER);
            public void actionPerformed(ActionEvent e) {
                if (e.getSource() == button1)
                    JOptionPane.showMessageDialog(null, "Action One Successful");
            public Component getTableCellEditorComponent(JTable table, Object value,
                                        boolean isSelected, int row, int column) {
                return panel;
           public boolean isCellEditable(final EventObject anEvent) {
              if (anEvent instanceof KeyEvent) {
                 final KeyEvent keyEvent = (KeyEvent) anEvent;
                 SwingUtilities.invokeLater(new Runnable() {
                    public void run() {
                       if (!Character.isIdentifierIgnorable(keyEvent.getKeyChar())) {
                          txtField.setText(txtField.getText() + keyEvent.getKeyChar());
                       txtField.setCaretPosition(txtField.getText().length());
                       txtField.requestFocusInWindow();
                return super.isCellEditable(anEvent);
    }The code for isCellEditable(final EventObject anEvent) which is needed to edit the cell using keyboard was provided by DarrylBurke here
    regards,
    nirvan.

    The F2 key when pressed generates an action event (either JTable generates it or some other component). I am not sure how to handle the action event in the isCellEditable() method. Also, F(X) range of keys other than F2 dump some junk character in the JTextfield when pressed. I am now stuck at this point and don't know how handle F(X) range of keys.
    regards,
    nirvan.

  • Invoking web service with customized SOAP Header

    Hi,
    how can I invoke web services from my BPEL process with additional elements in the SOAP Header?
    Regards,
    Piotr

    I don't know if I completely understand your question, but here is an attempt at and answer.
    It place variables in the SOAP Header open the invoke popup, click on the Adapters tab and select the variable that you would like to add into the SOAP header.
    I really hope that helps.
    Chris

  • TableSorter with Custom JTable

    I need some straight thinking here.
    I would like to add the TableSorter to a customised JTable (MyJTable).
    MyJTable extends JTable and uses a customsised Model (MyJTableModel) which extends DefaultTableModel.
    Both MyJTable and MyJTableModel are established components which work fine together and have been in use for a long period.
    The TableSorter class from the tutorial expects the Model to be a TableModel and appears to the JTable as a TableModel.
    So
              // Introducing the Sorter
              // TableSorter normally takes a DefaultTableModel
              // The mainModel is a MyJTableModel which Extends DefaultTableModel
              // So This is OK
              TableSorter mainSortModel = new TableSorter(mainModel);
              // mainTable is a MyJTable which normally takes a MyJTableModel
              // but the TableSorter is based on AbstractTableModel
              // So Here I Have a Mis-Match
              mainTable = new MyJTable(mainSortModel);
              // I Tried to Adapt TableSorter to extend MyJTableModel (which extends DefaultTableModel)
              // but this led to other errors in TableSorter
              mainSortModel.setTableHeader(mainTable.getTableHeader());How do I introduce the TableSorter ?

    I am somewhat new, but I was able to use the
    TableSorter without creating my own mouse-event... I
    believed the TableSorter does it automatically for
    you...You right. The TableSorter does normally. Unfortuantely in my case this isn't working because I have a customised table and model. Actually I'm unsure why it doesn't and I'm trying to diagnose where the problem lies. These reason I have focussed on the mose behaviour is because I can see it isn't working. Maybe that is the only problem but I was trying to figure out how to localise the problem more. Hence my last post.
    Thanks

  • How to print jTable with custom header and footer....

    Hello all,
    I'm trying to print a jTable with custom header and footer.But
    jTable1.print(PrintMode,headerFormat,footerFormat,showPrintDialog,attr,interactive)
    does not allow multi line header and footer. I read in a chat that we can make custom header and footer and wrap the printable with that of the jTable. How can we do that..
    Here's the instruction on the chat...
    Shannon Hickey: While the default Header and Footer support in the JTable printing won't do exactly what you're looking for, there is a straight-forward approach. You can turn off the default header/footer and then wrap JTable's printable inside another Printable. This wrapper printable would then render your custom data, and then adjust the size given to the wrapped printable
    But how can i wrap the jTable's Printable with the custom header and footer.
    Thanks in advance,

    I also once hoped for an easy way to modify a table's header and footer, but found no way.
    Yet it is possible.

  • Print JTable with multi line header

    I need to print a JTable with multi line header, I want to know if I can use the method jTable.print(int, MessajeFormat, MessageFormat) by manipulation of the MessageFormat. How I can manipulate it?
    Otherwise, How I can print this?

    hi again,
    To print pdf in a swing application you don't need servlet.jar.
    You'll only need itext.jar and a printer connected to your pc.
    Download the iText source code and unzip it. See the following classes:
    com.lowagie.tools.LPR and com.lowagie.tools.BuildTutorial. This latter is the main class of a swing tool that you can run.
    Silent Print:
    You have only to embed this javascript code in your pdf:
    writer.addJavaScript("this.print(false);", false);
                        document.add(new Chunk("Silent Auto Print"));Then, you have to send the document to the printer.
    Google : java print pdf
    http://forum.java.sun.com/thread.jspa?threadID=523898 or
    http://www.exampledepot.com/egs/javax.print/pkg.html for printing task.
    Under unix system, I used this:
                           String PRINTER = ...;
                   try {
                        String cmd = "lp -d " + PRINTER + " " + PDF_PATH;
                        Runtime.getRuntime().exec(new String[] { "sh", "-c", cmd });
                   } catch (Exception e) {
                                 //handle the exception
                                 e.printStackTrace();
                   }hth

  • OSB to RestFul with Custom Header and Authentication

    I am trying to add to OSB a RestFul service which requires authentication and custom http headers.
    I am able to register the RestFul service as Business Service with following parameter
    - Service Type: Messaging Service
    - Request Message Type: None
    - Response Message Type: Text
    - Http Request Method: Get
    - Authentication: Basic (Service Account)
    When I test the Business Service in the Test Console, I passed in the custom http header and the content type and it did return back the JSON object I was expected.
    However when I then try to create a Proxy against it with the following parameter, I had problem running it in the Test Console. Although I did pass in the http header it still complained that I didn't pass in the header. And as for Authentication, I was not even able to specify a service account like how I did in Business Service.
    - Service Type: Messaging Service
    - Request Message Type: None
    - Response Message Type: Text
    - Http Request Method: Get
    Any ideas?
    Thanks

    What type of service account are you using ? If it is static you need specify the username/password in the PS. Also you do not specify service account for a proxy service. What is the error in the logs.
    If you have to pass the HTTP header use transport headers in your request, select request type as http and then set the content type and custom http header.
    http://docs.oracle.com/cd/E21764_01/doc.1111/e15867/modelingmessageflow.htm#i1125373

  • JTable with Multiple Row Header

    well, Im do an application thats need formated ISOS Sheets, and most of them have a Table with Multiple Row Header , and Groupable Header, and both of them. I have the .java and in the class MultipleRowHeaderExample calls a class AttributiveCellTableModel for setColumnIdentifiers() and setDataVector() the cue is why this print stack :
    Exception in thread "main" java.lang.StackOverflowError
         at java.util.Vector.<init>(Unknown Source)
         at java.util.Vector.<init>(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:54)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
         at jp.gr.java_conf.tame.swing.table.AttributiveCellTableModel.setDataVector(AttributiveCellTableModel.java:55)
         at javax.swing.table.DefaultTableModel.setColumnIdentifiers(Unknown Source)
    .if in main class, have initialized the data, and column vars
    public class MultipleRowHeaderExample extends JFrame {
      Object[][] data;
      Object[] column;
      JTable table;
      MultiSpanCellTable fixedTable;
      public MultipleRowHeaderExample() {
        super( "Multiple Row Header Example" );
        setSize( 400, 150 );
        data =  new Object[][]{
            {"SNo."    ,"" },
            {"Name"    ,"1"},
            {""        ,"2"},
            {"Language","1"},
            {""        ,"2"},
            {""        ,"3"}};
        column = new Object[]{"",""};
        AttributiveCellTableModel fixedModel = new AttributiveCellTableModel(data, column) {
          public boolean CellEditable(int row, int col) {
            return false;
        };

    What's the code in AttributiveCellTableModel?
    * (swing1.1beta3)
    package jp.gr.java_conf.tame.swing.table;
    import java.util.*;
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.table.*;
    import javax.swing.event.*;
    * @version 1.0 11/22/98
    public class AttributiveCellTableModel extends DefaultTableModel {
      protected CellAttribute cellAtt;
      public AttributiveCellTableModel() {
        this((Vector)null, 0);
      public AttributiveCellTableModel(int numRows, int numColumns) {
        Vector names = new Vector(numColumns);
        names.setSize(numColumns);
        setColumnIdentifiers(names);
        dataVector = new Vector();
        setNumRows(numRows);
        cellAtt = new DefaultCellAttribute(numRows,numColumns);
      public AttributiveCellTableModel(Vector columnNames, int numRows) {
        setColumnIdentifiers(columnNames);
        dataVector = new Vector();
        setNumRows(numRows);
        cellAtt = new DefaultCellAttribute(numRows,columnNames.size());
      public AttributiveCellTableModel(Object[] columnNames, int numRows) {
        this(convertToVector(columnNames), numRows);
      public AttributiveCellTableModel(Vector data, Vector columnNames) {
        setDataVector(data, columnNames);
      public AttributiveCellTableModel(Object[][] data, Object[] columnNames) {
        setDataVector(data, columnNames);
      public void setDataVector(Vector newData, Vector columnNames) {
        if (newData == null)
          throw new IllegalArgumentException("setDataVector() - Null parameter");
        dataVector = new Vector();
        setColumnIdentifiers(columnNames);
        dataVector = newData;
        cellAtt = new DefaultCellAttribute(dataVector.size(),
                                           columnIdentifiers.size());
        newRowsAdded(new TableModelEvent(this, 0, getRowCount()-1,
               TableModelEvent.ALL_COLUMNS, TableModelEvent.INSERT));
      @Override
      public void setColumnIdentifiers(Vector arg0) {
              // TODO Auto-generated method stub
              super.setColumnIdentifiers(arg0);
      public void addColumn(Object columnName, Vector columnData) {
        if (columnName == null)
          throw new IllegalArgumentException("addColumn() - null parameter");
        columnIdentifiers.addElement(columnName);
        int index = 0;
        Enumeration enumeration = dataVector.elements();
        while (enumeration.hasMoreElements()) {
          Object value;
          if ((columnData != null) && (index < columnData.size()))
           value = columnData.elementAt(index);
          else
         value = null;
          ((Vector)enumeration.nextElement()).addElement(value);
          index++;
        cellAtt.addColumn();
        fireTableStructureChanged();
      public void addRow(Vector rowData) {
        Vector newData = null;
        if (rowData == null) {
          newData = new Vector(getColumnCount());
        else {
          rowData.setSize(getColumnCount());
        dataVector.addElement(newData);
        cellAtt.addRow();
        newRowsAdded(new TableModelEvent(this, getRowCount()-1, getRowCount()-1,
           TableModelEvent.ALL_COLUMNS, TableModelEvent.INSERT));
      public void insertRow(int row, Vector rowData) {
        if (rowData == null) {
          rowData = new Vector(getColumnCount());
        else {
          rowData.setSize(getColumnCount());
        dataVector.insertElementAt(rowData, row);
        cellAtt.insertRow(row);
        newRowsAdded(new TableModelEvent(this, row, row,
           TableModelEvent.ALL_COLUMNS, TableModelEvent.INSERT));
      public CellAttribute getCellAttribute() {
        return cellAtt;
      public void setCellAttribute(CellAttribute newCellAtt) {
        int numColumns = getColumnCount();
        int numRows    = getRowCount();
        if ((newCellAtt.getSize().width  != numColumns) ||
            (newCellAtt.getSize().height != numRows)) {
          newCellAtt.setSize(new Dimension(numRows, numColumns));
        cellAtt = newCellAtt;
        fireTableDataChanged();
      public void changeCellAttribute(int row, int column, Object command) {
        cellAtt.changeAttribute(row, column, command);
      public void changeCellAttribute(int[] rows, int[] columns, Object command) {
        cellAtt.changeAttribute(rows, columns, command);
    }that's it

  • Problem with JTable with JCheckBox as Header

    Hi,
    We have a JCheckBox as JTable Header. And respective data in that column also check boxes. For data check boxes, just i am sending Boolean object to object[][] data array. I am getting check Boxes as data components.
    For Header, i have create a TableRender object which is returning JCheckBox.
    Here my problem is,
    1) When i select a Header check box, all the check boxes are getting selected.
    2) Now we can reselect an data Check Box. When i reselect any data checkBox, Header CheckBox should be reselected. This is not happening. I was tried lot. Can any body give a solution to solve this problem.
    Please .... Please ...
    Thanks
    Mohan

    just call this method with null param on the JTable
    table.setTableHeader(null);
    cheers
    krishna

  • Not able to save date column with custom date format. in OBIEE 11g

    Hi,
    I have migrated one report from OBIEE 10g to 11g. There is a date column with customized date format(i.e. Default format is 'dd-MMM-yyyy' and I have used 'MMM-yyyy').
    But when I use this custom format and try to save the report in 11g its giving this below error.
    ''Catalog object privilege validation failed for user to path /shared/ALM BI/Finacial Results/History Income Statement Detail.
    You do not currently have sufficient privileges to save a report or dashboard page that contains HTML markup.
    This HTML might be present in column headings, table headings, text views, narrative views, the print header,
    or the print footer and must be removed before saving.''
    Please let me know what changes I need to do for this.
    Regards,
    Ambika Nanda.

    Hi ,
    privilage issues...check the security settings once..
    Thanks,
    Ananth

  • Unable to add custom SOAP header to consumer webservice in CRM( without using PI)

    Hello Experts,
    We have a requirement to consume webservice proxy in CRM without involving PI. We have WSDL file which has many services as depicted in the first screenshot.After checking old posts, I could add custom SOAP header by using if_wsprotocol_ws_header and there is no xml parsing error for ws_header.Have used if_ixml_stream_factory to check xml parsing error for header.
    '<soapenv:Header>'
    '<wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">'
    '<wsse:UsernameToken wsu:Id="UsernameToken-2">'
                '<wsse:Username>user id</wsse:Username>'
                '<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">paswd</wsse:Password>'
                '<wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">MT0B9XFzsZJXXKmVKOsj/Q==</wsse:Nonce>'
                '<wsu:Created>2015-03-30T06:29:17.407Z</wsu:Created>'
    '</wsse:UsernameToken>'
    '</wsse:Security>'
    '</soapenv:Header>' INTO l_string.
    But when my ABAP program as a whole gets executed where consumer proxy is called, then it still throws XML parsing error - undeclared namespace prefix. As mentioned, there is no parsing error for header and WSDL file as a whole in SOAP UI tool works fine,by manually adding SOAP header.
    Have configured SOAMANAGER with logical port.Or any wrong setting in SOAMANAGER can cause this issue? When I tested webservice ping, it gave me attached error but I read in a SAP note that such error can be ignored.
    I want to know if some more setting/coding is required if we manually add custom header to a payload? Is PI really required to implement this requirement? Payload mapping has to be done to add custom header and if that can be taken care by ABAP coding and how?
    Can you please help?
    BR,
    Nisha Verma

    Hello Experts,
    I have not found the solution yet.
    Can anyone provide some insight??
    BR,
    Nisha Verma

  • AP to GL Transfer: How to have a custom Journal Header name in GL.

    Hi,
    Does any one know how to have a custom Journal Header name while transferring the Journals from AP to GL?
    Assume that I am transferring the Journals which belongs to a Single Invoice from AP to GL. When these Journals are transferred from AP to GL, Oracle will create a Journal Header with the default naming convention. The Oracle generated Header name will be as shown below.
    *123456 Purchase Invoices USD*. Where 123456 is AE_HEADER_ID and USD is the Invoice Currency code.
    Our requirement is, we want the Journal Header name something like *"Hello World"+TIMESTAMP*, where TIMESTAMP is the date when the user has ran the AP to GL transfer program.
    I know that when building the AAD(Application Accounting Definition) we can define the Journal Header descriptions and Journal Lines descriptions. But, I did not see any setup option to have the custom Journal Header name in GL.
    Any suggestions on this issue are highly appreciated.
    Advanced Thanks,
    Lokesh.

    Hi Lokesh,
    The best way to have a custom journal header name is using hook package.
    When data move from XLA to GL, every time it creates a new dynamic table as GL_INTERFACE table but the name is different (XLA_GLT_XXXXX).
    This table information stores in 'gl_interface_control' table but after use the record has deleted from 'gl_interface_control'.
    So we can't see table information after finishing create accounting program.
    What the modification you will made in this table it will affect GL base table. So to made custom journal header name, we need to change Reference4 column of dynamic table.
    Here is the code to get the table name and through procedure you can update the Reference4 column.
    FUNCTION pre_module_hook(run_id IN NUMBER,
                   errbuf IN OUT NOCOPY VARCHAR2) RETURN BOOLEAN IS
    chr_errbuf varchar2(50);
    chr_retcode varchar2(50);
    l_interface_Table_name varchar2(2000);
    BEGIN
         SELECT interface_table_name
    into l_interface_Table_name
    FROM gl_interface_control
    WHERE interface_run_id = run_id;
         BEGIN     
    xxdb_gl_icaccntgdist_pkg.gl_int_jrnl_update (chr_errbuf,chr_retcode,l_interface_Table_name);
    RETURN(TRUE);
         END;
    END pre_module_hook;
    Make these changes in GL_IMPORT_HOOK_PKG.pre_module_hook function.
    You can make the changes through calling procedure using dynamic query under the function pre_module_hook.
    Thanks,
    Gaurav K
    Edited by: 972729 on Nov 22, 2012 4:46 AM

  • Problems with a JTable

    Hello folks,
    i got two problems with a JTable.
    1. how do I change the size of a table header???
    2. I know that it is possible to set different column-sizes. The problem in my table is that I don't know how long some cells are. In this case, I want to to get the biggest cell of one column and set its size as the default size of that specific column.
    Is that possilbe?
    Hopefully you can help me out,
    thank you

    A JTableHeader is just another Component, so you ought to be able to set its size like you would
    any other component; however, since its function is to act as a header for a table, it might constrain
    itself to fit the table.
    In order to size the column to fit the largest cell, for each row, go through each column and get the
    renderer component for that column (which configures the component for rendering) and get the width
    of that component. If that's bigger than the column's current width, set its width and preferred width.
    You'll also want to check the renderer component width for the header to make sure the header doesn't
    get truncated if the column doesn't have a cell whose value is longer than the header.
    : jay

  • SOAP Sender Adatper - Read custom http header field

    Hello,
    i try to read a custom http header into the dynamic configuration of a message - but it is not working as expected - in ASMA i configured to get the value of MYHEADER1 into XHEADERNAME1 - when testing with a MYHEADER1 value, the value is not put into XHEADERNAME1.
    Is it possible to get custom HTTP Headers in the message?
    bf
    franz

    I have quite the same problem!
    I try to make the receiver determination based on the content of XHeaderName1, but none of the Dynamic Configuration parameters is shown in the sxi_monitor.
    I've described my scenario in more detail in this thread
    http://scn.sap.com/message/13586532#13586532
    Does anyone have an idea?

  • Maintaining Price for BOM / Bom item with customer

    Hi,
    We are using BOM concept for SO, and price we are maintaining at item level  like we have a FG material  9910    and it has BOM componenet  as , A,B,C  and we are maitaining price at item level for A,B, and C   now I want to maitain price at with  BOM  and customer
    BOM :  9910
    Item A,B,C
    BOM : 9911
    ITEM: A,B,C,D
    Now our requirement is to maiatin price as   CUSTOMER / BOM Header material  / BOM ITEM
    sohow to make the condition table for my requirement,  as MATNR field we can select only one time in table  how to take MATNR of Header and MATNR for item.
    regards,
    zafar

    Hi Prakash,
          Thanks for your reply it is a good link which u have send,  but my requirement is not solve with the given link I want to maiatin price at item level  for this in Main item item category I have maiatin LUMF  and alll price at item level  but  my requirement is I want to maiatin price at item level only but refeence to Main Item
    MEANS  :  I Hva emain item 9910.  with item  , 1.2.3  and i have another main item 9911  with sub items ,1,2,3,4  in such cases I want to maiatin price for sub items 1,2,3,4  but ref. to customer and Main item
    CUSTOMER / MAIN ITEM / SUB ITEM
    how to mainatin price in VK11  as per above requirement.
      regards,
       zafar

Maybe you are looking for

  • Printer Setup Utility will not allow new driver to be added

    I just bought a Canon Pixma MP960, installed the drivers and then downloaded the driver from their website. When I go to add a new driver in Printer Setup Utility--i highlight the MP960 connected thru USB, but the 'add' feature is not lit up. When i

  • How to hide watermark when viewing in acrobat 8 standard

    Hi, 2 of my colleagues (also having same versions of acrobat) manage to open a pdf file without the watermark showing. I have been googling around and found that there is an option to set. To specify when the watermark appears, select or deselect Sho

  • Generating "XSD" from an "XML" file

    Hi, I want a java program through which we can generate an "XSD" for the given "XML" file. I don't want any ready to use tools or ide's. Please send me links or code if exists. Thank You.

  • TS1702 my apps are not downloading in the i tunes on my phone?

    my apps are not downloading in the i tunes on my phone?  itunes app purchases are not downloading since software update. Any suggestions?

  • EJB 3.0 Interceptors

    Hi everyone, I do have a slight challenge while I implementing interceptors for the POJO live-cycle events. I am trying to execute an audit process inside a @PreUpdate and @PrePersist annotated method on an entity A that is the owning side of a 1:M r