:: Forum >> Version 1 >>

Getting "No Data Found." with the Following Code... Help!!

I am simply getting a "No Data Found." message displayed within my ActiveWidget table. Below is the code that I'm using...

My main page code:
<script language="javascript">
<!--

    
//    create ActiveWidgets data model - XML-based table
    
var table = new Active.XML.Table;

    
//    provide data URL
    
table.setURL("xmldata.php");

    
//    start asyncronous data retrieval
    
table.request();

    
//    define column labels
    
var columns = ["ID""Institution""Country""Status""Exp. Date""Research Collab.""Faculty Exch.""Student Exch.""Grad. Exch.""Undergrad. Exch."];

    
//    create ActiveWidgets Grid javascript object
    
var obj = new Active.Controls.Grid;

    
obj.setAction("click", function(src){  
        var 
src.getProperty("item/index");  
        var 
src.getColumnProperty("index");  
        if (
j==1) {  
            var 
link "imoa_edit.php?imoaid=" this.getDataProperty("text"i0); 
            
parent.hideSearchbox();
            
document.location.href=link
        } ;  
    
    });  

    var 
row = new Active.Templates.Row;
    
row.setEvent("onmouseover""mouseover(this, 'active-row-highlight')");
    
row.setEvent("onmouseout""mouseout(this, 'active-row-highlight')");
    
obj.setTemplate("row"row);         

    
//    provide column labels
    
obj.setColumnProperty("texts"columns);

    
//    provide external model as a grid data source
    
obj.setDataModel(table);

    
//    write grid html to the page
    
document.write(obj);

//-->
</script>
 
The source XML "xmldata.php" page:<imoa>
    <
application>
        <
id>30</id>
        <
institution>Agence de Développement Urbain (A.D.U.), Buskerud University College</institution>
        <
country>MauritaniaNorway</country>
        <
status>Current</status>
        <
expdate>09-18-2006</expdate>
        <
researchcollab>No</researchcollab>
        <
facultyexch>Yes</facultyexch>        
        <
studentexch>No</studentexch>
        <
gradexch>Yes</gradexch>
        <
undergradexch>No</undergradexch>                    
    </
application>
    <
application>
        <
id>31</id>
        <
institution>Al Farabi Kazakh National University</institution>
        <
country>Kazakhstan</country>
        <
status>Pending Renewal</status>
        <
expdate></expdate>
        <
researchcollab>Yes</researchcollab>
        <
facultyexch>Yes</facultyexch>        
        <
studentexch>No</studentexch>
        <
gradexch>No</gradexch>
        <
undergradexch>No</undergradexch>                    
    </
application>
</
imoa>    
 
Any ideas why the widget is not working with this code, and simply saying "No Data Found."??

Thanks for your help!!
Senior Miguel
Saturday, April 8, 2006
Accent in xml file

Agence de Développement
------------?
Saturday, April 8, 2006



This topic is archived.

Back to support forum

Forum search