3.2.0

How to change the format of a cell in a table

How can I change the format of a date tht is in a AW.XML.Table?
I read documentation about it, but only I have found information about date format in a grid , how can I apply date format in a table field.
I try this:
var tabla = new AW.XML.Table;
CrearTabla(); //function that creates a table
var string = new AW.Formats.String;
var number = new AW.Formats.Number;
var date = new AW.Formats.Date;
date.setTextFormat("DD-MM-YYYY hh:mm:ss");
tabla.setCellFormat([number,number,date,date,number,string]);

Now, my table has the following format ("YYYY-MM-DDThh:mm:ss") in the fields of date, and I need this format ("DD-MM-YYYY hh:mm:ss") in a field of the table
Tecnora
May 16,
The AW.XML.Table class only extracts the data from the XML file and does not change data format. The formatting is applied when you retrieve the data from the AW.XML.Table source into the grid control by the cell format object.
Alex (ActiveWidgets)
May 19,
This is my problem. I am not using a grid, i am using a table and I donĀ“t know how to change date format in a table. Only I have seen examples of changing the format into a grid.
This is what I do:

1 => Create and fill AW.XML.Table
2 => var time = table.getData(3,1);
3 => How to change format of "time"?

I need to load data into a table, not into a grid,
and I need "dd-mm-yyyy hh:mm:ss" format. I have tried methods that I see in examples but all of this were applyed into a grid, not to a table


TECNORA
May 20,

This topic is archived.

See also:


Back to support forum