GrabFocus to Table Cell -pl help

Hi
I have a GUI where there is a JTable and few other components like JTextField, JCombox etc. When Focus of JTextField is lost, I want focus will go to cell(0,0) or any particular cell in the table. Anyone help me how do I force the focus to such specific cell of the table??
Thanks in advance.
Mortoza

Hi Mortoza
After focusLost() of your last JTextField call the following method:
public void selectRow(int row, int column) {
myTable.changeSelection(row, column, false, false);
myTable.setRowSelectionInterval(row, row);
myTable.requestFocus();
Greetings,
Triple Tuned member of hardcode.ch

Similar Messages

  • Scrolling table cell -- request help

    Hi,
    I would like to make a scrollable table cell (about 300px wide and 400 px high) that can contain both images and text. The content of the cell needs to be scrollable.
    I am a more than a newbie but not very skilled in Dreamweaver CS3 on a PC. I have worked a bit with CSS.
    If someone could assist me, I would really appreciate it especially if you are able to point me to video tutorial in which this is demonstrated. I have a membership in both Lynda.com and Kelby Online Training but didn't see anything there on this subject.
    I have read many posts on "scrollable DIVs" on the forum but haven't been able to apply them successfully.
    I would appreciate anyone's assistance.
    Many thanks.
    Jane

    Are you looking at adding a text box that can also contain pictures?
    Sounds almost like an overflow style in CSS.
    Something like this:
    <div style="width: 300px; height: 400px; background-color: #FFFFFF; font-size: 11px; overflow: auto;">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.</div>

  • Unable to edit a Table Cell. Help required.

    Hello Folks,
    Please I need some help.
    I have a java class which allows a user to enter and delete
    data into a table dynamically.
    So the user can enter any number of rows and once he clicks on the
    concerned row, he can also delete that row.
    I just have one small problem.
    I am unable to 'edit the cell'. i click on.
    can any one please help me on this. I'd like to send this class
    file.
    Can any one please send in their email address so I can attach this file
    Please some one respond.

    Hv u used something like this. What table model u r using. I hv used DefaultTableModel.
    c this piece of code: This might help.
    tblView = new JTable(model)
                   public boolean isCellEditable(int r,int c)
                        try
                             if(r == 0)
                                  return true;
                             else
                                  return false;
                        catch(Exception e)
                             apilError.createErrorLog(e,"Error1 class Bank_Reconciliation.java, in Constructor line no 194");
                             CallErrorMessage(apilError.systemerror,2,"Error");
                        return false;
                   public static final int a1=0;
                   public static final int a2=1;

  • JRadioButton grouped in a table cell. Help Needed.

    Hello...
    I am looking for code samples or exaples of how to implement a group of 3 radio buttons in a column of each row i create. I have not been able to find anything and I would appreciate any leads or code samples.
    basically i have 4 or 5 columns and one of the colums will take 3 radio buttons but only 1 of the 3 can be selected at a time.
    this is kind of what my table looks like.
    ListTable.setModel(new javax.swing.table.DefaultTableModel(
                new Object [][] {
                    {"000000000061", "05/05/2005", "this is where the 3 radio buttons will be grouped","05/05/2004"},
                    {null, null, null, null}
                new String [] {
                    "List ID", "Expiration Date", "Status", "Date Created"
                Class[] types = new Class [] {
                    java.lang.Object.class, java.lang.Object.class, java.lang.Boolean.class, java.lang.Object.class
                boolean[] canEdit = new boolean [] {
                    false, false, true, false
                public Class getColumnClass(int columnIndex) {
                    return types [columnIndex];
                public boolean isCellEditable(int rowIndex, int columnIndex) {
                    return canEdit [columnIndex];
            jPanel2.add(ListTable, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 44, 440, 130));Thanks very much.
    S

    Hope this helps :import javax.swing.*;
    import javax.swing.table.*;
    import java.util.Date;
    import java.util.Vector;
    import java.awt.*;
    import java.awt.event.*;
    import java.text.DateFormat;
    import java.text.SimpleDateFormat;
    public class TableTestPanel extends JPanel {
         private static final String[] COLUMN_NAMES = {"List ID", "Expiration Date", "Status", "Date Created"};
         private static final DateFormat DATE_FORMAT = new SimpleDateFormat("dd/MM/yyyy");
         private static class StatusPanel extends JPanel {
              private JRadioButton theSingleOption;
              private JRadioButton theMarriedOption;
              private JRadioButton theDivorcedOption;
              public StatusPanel() {
                   super(new GridLayout(3, 1));
                   setOpaque(true);
                   ButtonGroup buttonGroup = new ButtonGroup();
                   theSingleOption = new JRadioButton("Single");
                   theSingleOption.setOpaque(false);
                   add(theSingleOption);
                   buttonGroup.add(theSingleOption);
                   theMarriedOption = new JRadioButton("Married");
                   theMarriedOption.setOpaque(false);
                   add(theMarriedOption);
                   buttonGroup.add(theMarriedOption);
                   theDivorcedOption = new JRadioButton("Divorced");
                   theDivorcedOption.setOpaque(false);
                   add(theDivorcedOption);
                   buttonGroup.add(theDivorcedOption);
              public Status getStatus() {
                   if (theMarriedOption.isSelected()) {
                        return Status.MARRIED;
                   } else if (theDivorcedOption.isSelected()) {
                        return Status.DIVORCED;
                   } else {
                        return Status.SINGLE;
              public void setStatus(Status status) {
                   if (status == Status.MARRIED) {
                        theMarriedOption.setSelected(true);
                   } else if (status == Status.DIVORCED) {
                        theDivorcedOption.setSelected(true);
                   } else {
                        theSingleOption.setSelected(true);
         private static class Status {
              static final Status SINGLE = new Status("Single");
              static final Status MARRIED = new Status("Married");
              static final Status DIVORCED = new Status("Divorced");
              private final String myName; // for debug only
              private Status(String name) {
                   myName = name;
              public String toString() {
                   return myName;
         private static class TableEntry {
              private static int instanceNumber;
              private Long theId;
              private Date theExpirationDate;
              private Status theStatus;
              private Date theCreationDate;
              public TableEntry() {
                   instanceNumber++;
                   theId = new Long(instanceNumber);
                   theExpirationDate = new Date();
                   theStatus = Status.SINGLE;
                   theCreationDate = new Date();
              public TableEntry(Long anId, Date anExpirationDate, Status aStatus, Date aCreationDate) {
                   theId = anId;
                   theExpirationDate = anExpirationDate;
                   theStatus = aStatus;
                   theCreationDate = aCreationDate;
              public Long getId() {
                   return theId;
              public Date getExpirationDate() {
                   return theExpirationDate;
              public Status getStatus() {
                   return theStatus;
              public Date getCreationDate() {
                   return theCreationDate;
              public void setId(Long anId) {
                   theId = anId;
              public void setExpirationDate(Date anExpirationDate) {
                   theExpirationDate = anExpirationDate;
              public void setStatus(Status aStatus) {
                   theStatus = aStatus;
              public void setCreationDate(Date aCreationDate) {
                   theCreationDate = aCreationDate;
         private static class MyTableModel extends AbstractTableModel {
              private Vector theEntries;
              public MyTableModel() {
                   theEntries = new Vector();
              public void add(TableEntry anEntry) {
                   int index = theEntries.size();
                   theEntries.add(anEntry);
                   fireTableRowsInserted(index, index);
              public void remove(int aRowIndex) {
                   if (aRowIndex < 0 || aRowIndex >= theEntries.size()) return;
                   theEntries.removeElementAt(aRowIndex);
                   fireTableRowsDeleted(aRowIndex, aRowIndex);
              public int getRowCount() {
                   return theEntries.size();
              public String getColumnName(int column) {
                   return COLUMN_NAMES[column];
              public Class getColumnClass(int columnIndex) {
                   switch (columnIndex) {
                        case 0:
                             return Long.class;
                        case 1:
                             return Date.class;
                        case 2:
                             return Status.class;
                        case 3:
                             return Date.class;
                   return Object.class;
              public void setValueAt(Object aValue, int rowIndex, int columnIndex) {
                   TableEntry entry = (TableEntry) theEntries.elementAt(rowIndex);
                   switch (columnIndex) {
                        case 0:
                             try {
                                  entry.setId(new Long(Long.parseLong(aValue.toString())));
                             } catch (NumberFormatException nfe) {
                                  return;
                             break;
                        case 1:
                             entry.setExpirationDate((Date)aValue);
                             break;
                        case 2:
                             entry.setStatus((Status)aValue);
                             break;
                        case 3:
                             entry.setCreationDate((Date)aValue);
                             break;
                        default :
                             return;
                   fireTableCellUpdated(rowIndex, columnIndex);
              public boolean isCellEditable(int rowIndex, int columnIndex) {
                   return true;
              public int getColumnCount() {
                   return 4;
              public Object getValueAt(int rowIndex, int columnIndex) {
                   TableEntry entry = (TableEntry) theEntries.elementAt(rowIndex);
                   switch (columnIndex) {
                        case 0:
                             return entry.getId();
                        case 1:
                             return entry.getExpirationDate();
                        case 2:
                             return entry.getStatus();
                        case 3:
                             return entry.getCreationDate();
                   return null;
         private static class DateRenderer extends DefaultTableCellRenderer {
              public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
                   super.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, column);
                   if (!(value instanceof Date)) return this;
                   setText(DATE_FORMAT.format((Date) value));
                   return this;
         private static class DateEditor extends AbstractCellEditor implements TableCellEditor {
              private JSpinner theSpinner;
              protected Object value;
              public DateEditor() {
                   theSpinner = new JSpinner(new SpinnerDateModel());
                   theSpinner.setOpaque(true);
                   theSpinner.setEditor(new JSpinner.DateEditor(theSpinner, "dd/MM/yyyy"));
              public Object getCellEditorValue() {
                   return theSpinner.getValue();
              public Component getTableCellEditorComponent(JTable table, Object value,
                                                                      boolean isSelected,
                                                                      int row, int column) {
                   theSpinner.setValue(value);
                   if (isSelected) {
                        theSpinner.setBackground(table.getSelectionBackground());
                   } else {
                        theSpinner.setBackground(table.getBackground());
                   return theSpinner;
         private static class StatusEditor extends AbstractCellEditor implements TableCellEditor {
              private StatusPanel theStatusPanel;
              public StatusEditor() {
                   theStatusPanel = new StatusPanel();
              public Object getCellEditorValue() {
                   return theStatusPanel.getStatus();
              public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
                   theStatusPanel.setStatus((Status)value);
                   if (isSelected) {
                        theStatusPanel.setBackground(table.getSelectionBackground());
                   } else {
                        theStatusPanel.setBackground(table.getBackground());
                   return theStatusPanel;
         private static class StatusRenderer extends StatusPanel implements TableCellRenderer {
              public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
                   setStatus((Status)value);
                   if (isSelected) {
                        setBackground(table.getSelectionBackground());
                   } else {
                        setBackground(table.getBackground());
                   return this;
         private MyTableModel theTableModel;
         private JTable theTable;
         public TableTestPanel() {
              super(new BorderLayout(0, 5));
              setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
              theTableModel = new MyTableModel();
              theTable = new JTable(theTableModel);
              theTable.setDefaultEditor(Date.class, new DateEditor());
              theTable.setDefaultRenderer(Date.class, new DateRenderer());
              theTable.setDefaultEditor(Status.class, new StatusEditor());
              theTable.setDefaultRenderer(Status.class, new StatusRenderer());
    // comment out the two preceding lines and uncomment the following one if you want a more standard editor
    //          theTable.setDefaultEditor(Status.class, new DefaultCellEditor(new JComboBox(new Status[]{Status.SINGLE, Status.MARRIED, Status.DIVORCED})));
              add(new JScrollPane(theTable), BorderLayout.CENTER);
              JToolBar toolBar = new JToolBar();
              toolBar.setFloatable(false);
              toolBar.add(new AbstractAction("Add new") {
                   public void actionPerformed(ActionEvent e) {
                        theTableModel.add(new TableEntry());
                        packTable();
              toolBar.add(new AbstractAction("Remove") {
                   public void actionPerformed(ActionEvent e) {
                        theTableModel.remove(theTable.getSelectedRow());
              add(toolBar, BorderLayout.NORTH);
         private void packTable() {
              TableColumnModel columnModel = theTable.getColumnModel();
              int columnCount = theTable.getColumnCount();
              int rowCount = theTable.getRowCount();
              int[][] preferredHeights = new int[columnCount][rowCount];
              TableCellRenderer renderer;
              Component comp;
              for (int col = 0; col < columnCount; col++) {
                   renderer = columnModel.getColumn(col).getCellRenderer();
                   if (renderer == null) {
                        renderer = theTable.getDefaultRenderer(theTableModel.getColumnClass(col));
                   for (int row = 0; row < rowCount; row++) {
                        comp = renderer.getTableCellRendererComponent(theTable, theTableModel.getValueAt(row, col), false, false, row, col);
                        preferredHeights[col][row] = (int) comp.getPreferredSize().getHeight();
              for (int row = 0; row < rowCount; row++) {
                   int pref = 0;
                   for (int col = 0; col < columnCount; col++) {
                        pref = Math.max(pref, preferredHeights[col][row]);
                   theTable.setRowHeight(row, pref);
         public static void main(String[] args) {
              final JFrame frame = new JFrame("TestRadioButtonRenderer");
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              frame.setContentPane(new TableTestPanel());
              SwingUtilities.invokeLater(new Runnable() {
                   public void run() {
                        frame.setSize(400, 300);
                        frame.show();
    }

  • Search help in case of a table cell editor

    Hi
    I need a search help in case of a table cell editor as well as the the other requirement is that it shld be a reusable one.
    could anyone of u suggest me some methods
    regards
    Nikhil Tapkir

    There are several ways of doing this.
    1. Use OVS
    2. Create a Search help in R3. Call the function module.
    3. Create a Jar file which would provide the result .
    It is upto you on which ever way you want to provide
    Kumar

  • Robohelp HTML 9 hyperlinks in table cells help

    Hi,
    I'm creating a table in robohelp html 9 and adding hyperlinks in the table cells. If the hyperlink is the first word in that cell robohelp is adding styling code to the link eg <td><a href="#" style="color: #0000ff; text-decoration: underline; ">test</a></td>.
    If I add a link to the second word in a table cell the styling does not appear or even if I add a space before the link the code does not appear eg <td>&#160;<a href="#">test</a> </td>.
    The code appears when I flick between design and HTML views but it does not make any difference in which view I create the link.
    No matter how many times I delete this code is keeps coming back. Can  anyone please help me? Is there some default that gives this the styling  code?Does anyone else get this issue?
    A table with the different examples is below. It was created in design view by clicking table>insert table>OK. Links added by clicking the insert hyperlink button.
    <table style="border-collapse: separate; border-collapse: separate;" cellspacing="0"
             width="33.333%" border="1">
        <col style="width: 100%;" />
        <tr>
            <td><a href="#" style="color: #0000ff; text-decoration: underline; ">test
             that has the added code</a></td>
        </tr>
        <tr>
            <td>&#160;<a href="#">test with space in front of link</a> </td>
        </tr>
        <tr>
            <td><a href="#" style="color: #0000ff; text-decoration: underline; ">test</a></td>
        </tr>
        <tr>
            <td>A <a href="#">test</a> </td>
        </tr>
    </table>
    Thanks in advanced

    I have the same problem with those stupid links in tables - I've been working on this for HOURS and HOURS...... Based on previous experience, I assumed it must only be me and an ill-formed stylesheet. The table/link issue just came to my attention because I am in the process of changing styles/formats to a new company standard (new link color) and thought I really screwed my CSS up as I was changing things!
    My only workaround thusfar has been to rewrite some data in the tables so that text will precede the link (yes, I did).  And where I just couldn't do that, I resigned myself to the problem and forced a different color on the links (changing the #0000ff).  One plus was that RH didn't rewrite the color code once it was changed manually..... but then I realized later that I didn't consider the hover color when I did this, so I now have to go back and correct them. 
    So glad to find your post...........
    I played with the idea of adding hidden text, but was worried that the problem was really a result of an issue with my CSS and doing that wasn't the proper way to fix it.   So, without guilt, I took Rick's suggestion and added an invisible dot/period at the beginning of every link in a table, when that link is the first or only content in the td.  Did the trick!  Now the links assume my declared css style! 
    I submitted a bug report.......
    Thank you!!!

  • Help: Jbo Exception non blocking when using table cell renderer?

    Hi,
    JClient 9.5.2.
    When using Table Cell Renderer on an table cell attribute that is defined mandatory and activating the insert button, the (oracle.jbo.AttrValException) JBO-27014 exception is caught but it is not blocking and a new row is still inserted.
    The JClient component demo, table attribute list, has the same behaviour.
    You can add multiple rows even if not all required attributes have been documented.
    Can a Swing specialist help me on this one?
    Example of Table Cell Renderer:
    public class TableBasicStatusRenderer extends DefaultTableCellRenderer
    public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus,
    int row, int column)
    JLabel lb = new JLabel((String) StaticData.getStatusName(value)); // retrieves label from Map
    return lb;
    Regards
    Frederic

    Hi,
    I found something interesting, it could be a WORKAROUND!
    I noticed that in another detail panel with table layout the JBO exception was blocking and adding another row before completing the row was NOT possible.
    In the create method of the entity object of the displayed View Object I iterate over the detail row iterator to retrieve a maximum value.
    By the end of the method the pointer is positionned after the last row.
    So I added to the detail panel that doesn't block following code:
    In create method of detail Entity Object Impl (only one entity object involved for this View)
    // Retrieve master EntityObjectImpl from association:
    PostalTariffImpl postalTariffImpl = getPostalTariffAssoc();
    // Retrieve detail default row iterator
    RowIterator ri = postalTariffImpl.getPostalDetailGroupAssoc();
    // Position pointer after last row
    ri.last();
    ri.next();
    Question: Why does this solve the problem?
    Regards
    Frederic
    PS Les mysteres de l'informatique!

  • Table Cell Contents Disappears Please HELP!!!!

    PROBLEM: I have a different tables within different table cells in the Master table. One table per Master cell. Once I click on a table cell (0,0) and click on another table cell (1,1) the cell (0,0) blanks out. Likewise with other cells so that if I've click on all the cells in the Master Table and then clicked somewhere else all cell contents have disappeared.
    QUESTION: Do I need to call some UI refresh procedure????? I have a cell renderer which returns the table for each Master's Cell.
    I don't if this is clear but please help!
    Thanks

    Hi,
    the problem is that the DefaultCellEditor can't handle tables.
    So you have to write your CellEditor, which returns another table as Editor.
    class YourTableCellRenderer implements  TableCellRenderer{
        private  JTable table = new JTable();
        public Component getTableCellRendererComponent(JTable table,
                                                       Object value,
                                                       boolean isSelected,
                                                       boolean hasFocus,
                                                       int row,
                                                       int column){
             // set Data and Layout
             return table;
    }then set the Editor to your MasterTable (master) with.
    master.setCellEditor(TableCellEditor anEditor) or
    master.setDefaultEditor(Class columnClass,
                                 TableCellEditor editor);Hope this Helps.
    Michael

  • Need help: checkbox or radiobutton in table cell

    So basically i am looking for code samples or links to where i can find an implementation of 2 or 3 radiobuttons or checkboxes in a table cell/column, so that for each row, i can have a selection of A, B or C for a particular string in the first column. I can create a table with one checkbox, but i cant figure out 2 or more inside the same cell.
    thanks :)

    The JTable tutorial has a section titled "Using a Combo Box as an Editor". Take a look at their example for how to do this.
    http://java.sun.com/docs/books/tutorial/uiswing/components/table.html

  • Make Table Cells Transparents in InDesign CC 2014?? HELP!

    Hi!
    I used to be able to make the fill on my table cells different transparencies in indesign. I could make it so the background would lightly show through, and the text would still be legible. I also was able to make the table border be transparent so the background would totally shine through. I can't do this anymore with the new 2014 release.
    Does anyone know how to fix this??? Thanks!!!

    I think it works like this here:

  • How to highlight the table cell color in respective colors as needed per the requirements??

    var aData = [
        {notificationNo: "10000000", description: "Maintenance for boiler", location: "G001-STG-UTLR-BLR", equipmentNo: "100000053", orderStatus: "ordered"},
        {notificationNo: "10000010", description: "Genreal Maintenance for boiler", location: "G001-STG-UTLR-BLR", equipmentNo: "100000053", orderStatus: "notordered"},
        {notificationNo: "10000011", description: "boiler Maintenance", location: "G001-STG-UTLR-BLR", equipmentNo: "100000053", orderStatus: "ordered"},
        {notificationNo: "10000012", description: "Pump breakdown", location: "G001-STG-UTLR-BLR", equipmentNo: "100000053", orderStatus: "ordered"},
        {notificationNo: "10000013", description: "External service boiler", location: "G001-STG-UTLR-BLR", equipmentNo: "100000053", orderStatus: "notordered"},
    jQuery.sap.require("sap.ui.model.json.JSONModel");
    var oEnterpriseAsset_NotificationConsole;
    sap.ui.model.json.JSONModel.extend("EAM_Notification_Console", {
        CreateNotificationConsole:function(){
            oEnterpriseAsset_NotificationConsole = this;
                var oTable = new sap.ui.table.Table({
                //title: "Table Example",
                visibleRowCount: 7,
                firstVisibleRow: 3,
                selectionMode: sap.ui.table.SelectionMode.Single,
            /*    toolbar: new sap.ui.commons.Toolbar({items: [
                    new sap.ui.commons.Button({text: "Button in the Toolbar", press: function() { alert("Button pressed!"); }})
                extension: [
                    new sap.ui.commons.Button({text: "Button in the Extension Area", press: function() { alert("Button pressed!"); }})
            }).addStyleClass("tableform");;
            oTable.addColumn(new sap.ui.table.Column({
            label: new sap.ui.commons.Label({text: "Notification"}),
            template: new sap.ui.commons.Link().bindProperty("text", "notificationNo").bindProperty("href", "href",
                    function(aValue)
            //    sortProperty: "notificationNo",
                //filterProperty: "notificationNo",
                width: "200px"
            oTable.addColumn(new sap.ui.table.Column({
                label: new sap.ui.commons.Label({text: "Description"}),
                template: new sap.ui.commons.Link().bindProperty("text", "description").bindProperty("href", "href"),
                //sortProperty: "notificationNo",
                //filterProperty: "notificationNo",
                //width: "200px"
            var oModel = new sap.ui.model.json.JSONModel();
            oModel.setData({modelData: aData});
            oTable.setModel(oModel);
            oTable.bindRows("/modelData");
        var idForTable= "DimTable"
            //alert("id of tbale " + idForTable);
            var htmlOutput = '<table id=' + idForTable + ' name="DimTab" style="border: 1px solid black;margin-left:15px;" cellpadding=6 cellspacing=0><tr style="background-color:#E5E5E5"><td><b>Dimension</b></td><td><b>Value</b></td></tr>';
            for(var i=0;i<aData.length;i++)
             alert(aData[i].notificationNo);
            htmlOutput += '<tr style="display:none;"><td style="border-right:1px solid #e5e5e5;">Contract No</td><td>'+ aData[i].notificationNo+'</td></tr>';
            htmlOutput += '<tr style="display:none;"><td  style="border-right:1px solid #e5e5e5;">Unit No</td><td>'+ aData[i].description+'</td></tr>';
            htmlOutput += '</table>';   
             var html2 = new sap.ui.core.HTML({
                 // static content
                 //content : "<div style='position:relative;background-color:white;'>Weather</div><script src='//www.gmodules.com/ig/ifr?url=http://www.google.com/ig/modules/builtin_weather.xml&synd=open&w=320&h=200&title=__MSG_weather_title__&lang=en&country=ALL&border=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fimages%2F&output=js'></script>",
            content : htmlOutput,
                  //2 wrkng sydney content : '<div id="cont_Mzc0NjN8NXwxfDF8NHxlZGY1ZjV8M3xGRkZGRkZ8Y3wx"><div id="spa_Mzc0NjN8NXwxfDF8NHxlZGY1ZjV8M3xGRkZGRkZ8Y3wx"><a id="a_Mzc0NjN8NXwxfDF8NHxlZGY1ZjV8M3xGRkZGRkZ8Y3wx" href="http://www.weather-wherever.co.uk/australia/sydney_v37463/" target="_blank" style="color:#333;text-decoration:none;">Weather forecast</a> © weather</div><script type="text/javascript" src="http://widget.weather-wherever.co.uk/js/Mzc0NjN8NXwxfDF8NHxlZGY1ZjV8M3xGRkZGRkZ8Y3wx"></script></div>',
                  //content : '<div style="margin-left:-10px;margin-top:10px;width:100%;"><LINK rel="StyleSheet" href="http://weatherandtime.net/new_wid/w_5/style.css" type="text/css" media="screen"><div class="ww_5" id="ww_5_2119"><div class="l_b"></div><div class="c_b"><div class="day" id="d_0"><span class="den"></span><br><span class="date"></span><br><span class="temp"></span><div class="pict"></div><span class="press"></span><br><span class="hum"></span><br><span class="vet"></span><br></div><div class="day" id="d_1"><span class="den"></span><br><span class="date"></span><br><span class="temp"></span><div class="pict"></div><span class="press"></span><br><span class="hum"></span><br><span class="vet"></span><br></div><div class="day" id="d_2"><span class="den"></span><br><span class="date"></span><br><span class="temp"></span><div class="pict"></div><span class="press"></span><br><span class="hum"></span><br><span class="vet"></span><br></div><div class="cl"></div><div class="links"><a target="_blank" title="Pune Weather forecast" href="http://weatherandtime.net/en/Asia/India/Pune-weather.html">Pune Weather forecast</a><br><a style="font-size:12px !important;color:#12A0D7 !important;text-decoration:none !important;" href="http://weatherandtime.net/en/widgets-gallery.html" title="weather"></a></div></div><div class="r_b"></div></div><script type="text/javascript" src="http://weatherandtime.net/w_5.js?city=2119&lang=en&type=2&day=3"></script></div>',
              // initially behaves the same as Sample 1
                 preferDOM : false,
                 // use the afterRendering event for 2 purposes
        return     oTable;
    /* In the screen shot as u can see.. I have to highlight the table cell in green color and red color for ordered and unordered status(which is binded to a json data) respectively....anyone please help??

    Hi Abhi,
                   Check this link it may helpHow I made highlight of specific values in Table

  • Looping table cells....... is it possible to loop more than one table cell?

    Hi there
    Hope everyone is doing well
    I have been using the addt looper wizard and it works great.....
    I usually put all the things I want to loop into one cell.... then select all the things and apply the looper.... which works fine....
    But..... it is hard to align all the elements I want to loop
    I have been using transparent gif images to space the loops evenly but when I space dynamic taxt on top of each other there is a large gap.....
    It is a nightmare to get it looking even
    Ok say I want to loop this.....
    A thumbnail
    Product ID
    Price
    It would look like this
    A thumbnail
    Product ID
    Price
    Because I cannot reduce the space between the lines......
    So I would like to place all the different elements in separate table cells and loop them..... I have tried and get really strange results....
    When you look at most online shops, their product pages have a thumbnail image the id, price, description, etc.... all spaced evenly.... and looks like is looped...... So.... how do I do it?
    Is there any easier way to align the things I want to loop?
    Any help would be great

    Hi there
    I seem to have figured out how to loop cells....
    Should have thought of it earliar but anyway
    Was easy....
    Just create a looped (repeat) region and insert a table into the region and edit the table to align all the looped elements easily....
    Cool

  • How Do I Change the Padding in Table Cells

    Hi, I am trying to set up a table that will allow text to fill the entire cell. I know that if I double click an individual cell, the left and right boundaries of the cell will be displayed on the ruler. However, I can't select multiple cells (even in a column) to adjust the boundaries. By default, all cells are created with no padding on the left, but half an inch on the right. I want no padding on the right as well. I know I can change the the tab for the table with the text inspector, after the fact.
    So, #1. How can I change the default right cell wrap for all cells in a table?
    Additionally, I know how to get rid of the padding above the text (via text property "instant margins"), but I also need to eliminate the padding at the bottom of the text. When I adjust the instant margin, it just moves the text the upper-left corner of the cell, but does not change the vertical size of the cell. I can change the individual row height by grabbing the border and dragging it up, but, again, this is a pain for large table. I know I can also change the overall cell height by dragging the lower table boundary.
    #2. How do I change the default cell height so the cell is tight against the text, regardless of the font size, for all cells in a table?
    Any help or suggestion will be greatly appreciated.
    Thanks
    Gary

    Thanks for the reply.
    Unfortunately, those options will not do what I need.
    If I turn off "Wrap text", the text overflows the cell and the text in the adjacent cell to the right will hidden. I still want the text to wrap, just not half an inch from the right border.
    And the "Resize to fit" changes the cell width, which I want to keep the cell at a static width.
    One workaround I found, was to modify the table as needed, using text properties, and then save the table as the table default. Unfortunately, that overwrites the factory default, and new table's tabs in other templates (all other properties seem to be retained)
    The second option that seems to work, is to save my entire document as a template. That seems to hold all the properties for graphics, tables, etc.
    A bit kludgy, but those methods seem to do the trick.
    Now, how do I get the default table properties back?
    Gary

  • Changing the color of a Basic line object nested in a table cell

    Can anyone help me out here...I have inserted a line object from the Basic palette into a table cell on my web page and it displays fine but is default black color...I would like to change the color but haven't been successful in doing so..any ideas

    Hmm - doesn't sound right.
    "color=#hex" is not appropriate HTML markup.... Can you show us where you
    made this change?
    Murray

  • Table cell color in webdynpro for ABAP

    Hai,
    I need to differentiate some table cell values using color change or some other way.
    while populating table values, I have a field like mandatory or optional. According to mandatory field, I need to chage color the text of the another column in the same table called "name".
    Another help about the table cell popin, I have a column name like "Name" in the table like link to action. If a person clicks on any of the "name" cells, the descriptive value should come as table cell popin.
    If you have sample code, that will help me lot.
    Thanks,
    I will reward points any type of helpful answer.
    Tamil

    Hi,
    did you take a look at the information under http://help.sap.com/saphelp_nw2004s/helpdata/en/b5/ac884118aa1709e10000000a155106/frameset.htm and WDR_TEST_TABLE in the system?
    Regards, Heidi

Maybe you are looking for

  • Display of names in the TO: filed from the Exchange Global Address List

    We have a user whose "FIRST" name in Active Directory consists of two names. Like Mary Ellen or Bobby Jo. But both names have been enetered in the TO: field. She is very adamant that she be addressed by both names. When she receives a message, and if

  • Issues in Sales Order for Customs invoice.

    Hi Experts, Have created a S/O 'A' is for a part at no charge, with value on Sales Order = 0.00 Woth refernce to this SO we created the delivery 'B' and then the customs invoice 'C' through VF01 with billing type ZF8. The Customs Invoice brings in a

  • Payment term in display.

    Hi, I want to make payment term in display mode in  MIRO. Can  we do that through document change rules but please not that i want it only for F-53 t code. Please guide how can this be achieved.

  • Stuck with install/first use of Adobe forms in NWDS

    Hi I'm trying to use interactive forms in NWDS, but there seems to be nowhere in NWDS that I can access anything Adobe like. I'm not sure if this a very simple thing I'm missing in NWDS, or my installation has gone wrong. From the beginning, I've ins

  • PO amount isn't reflected in the liquidity forecast

    Dear Gurus, I have completed all the cash management configuration, but somehow the liquidity forecast only captures the balance of PO that has been converted to invoice through MIRO. I think CM retrieves the invoice balance through planning group wh