Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    getSelectedRecord()

    I am trying to access data from Grids's DS.
    The DS is defined like this:
    isc.DataSource.create({
    ID:"ConsistPersonnel",
    dataFormat:"xml",
    dataURL:"../../accidents/forms/accidents.asp?requesttype=post&datarequest=xml&methodexecute=mSaveApplicationData&formname=consistPersonnel&consistid=",
    dataProtocol:"postParams",
    recordXPath:"//consistpersonnel",
    fields:[
    {name:"id", primaryKey:true, hidden:true, type:"sequence"},
    {name:"header_id", primaryKey:true},
    {name:"person"},
    {name:"name"},
    {name:"worknum"}
    ]
    });


    Grid.getSelectedRecord() returns a record object but it does not have "header_id" field. "header_id" is not a column in Grids. How can I access it? I had simular question before and was told that in 5.7 this method should return complete DS record. Please help.

    #2
    getSelectedRecord() is just returning exactly what is found in listGrid.data, which in turn is exactly what your DataSource returned. If there is no header_id in the record as returned from getSelectedRecord(), then you didn't include it in your "consistpersonnel" XML elements

    Comment

    Working...
    X