Announcement

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

    form dataBinding

    Hi,
    I have
    isc.DynamicForm.create({
    ID:"docForm",
    dataSource: docDetails,
    useAllDataSourceFields: true,
    width:350

    })

    ]
    });

    and isc.DataSource.create({
    ID:"docDetails",
    dataFormat:"xml",
    dataURL:"/viewDocumentProperties.xml",
    recordXPath:"//document",
    fields:[
    {title:"Index No. & *Title", type:"text", name:"indexNum"}


    ],
    showPrompt:false

    });

    The field shows up but doesn't pull data from XML file.
    What am I declaring incorrectly. Pl help
    Thankyou

    #2
    Hi Stem,
    The declaration looks correct.
    You will need to call fetchData to retrieve the data from the dataSource, and then call editRecord on the form in the fetchData() callback to actually populate it with the returned data.

    Something like this:
    Code:
    myDataSource.fetchData(
        [optional criteria for record to edit], 
        "myForm.editRecord(data[0])"
    );

    Comment

    Working...
    X