Loading from JSON

Loading from json and keep the references






Source code

<html>
<script src="https://jspreadsheet.com/v7/jspreadsheet.js"></script>
<script src="https://jsuites.net/v4/jsuites.js"></script>
<link rel="stylesheet" href="https://jsuites.net/v4/jsuites.css" type="text/css" />
<link rel="stylesheet" href="https://jspreadsheet.com/v7/jspreadsheet.css" type="text/css" />

<div id="spreadsheet"></div>

<script>
var data = [
    {
        name:'Jorge',
        id:'3',
        age:'40',
        gender:'Male'
    },
    {
        name:'Rogerio Sergio',
        id:'4',
        age:'48',
        gender:'Male'
    },
    {
        name:'Jorgina Santos',
        id:'5',
        age:'32',
        gender:'Female'
    },
    {
        name:'Arnaldo Antunes',
        id:'6',
        age:'63',
        gender:'Male'
    },
];

jspreadsheet(document.getElementById('spreadsheet'), {
    json: data,
    columns: [
        {
            type:'text',
            width:'300',
            name:'id'
        },
        {
            type:'text',
            width:'200',
            name:'name'
        },
        {
            type:'text',
            width:'100',
            name:'age'
        },
        {
            type:'hidden',
            name:'gender'
        },
     ],
     license: 'ZTNkZWM0NjU5YzY1YzM4NjhhNWNlNzlhM2YzNDg2Y2QyNjk2MDcxMWZmZTQ5YjJmMzhhYmFkMmMwYmU4ODAyYTJkYzFmMDg5ZjcwZGY2ZTA1NjU3YWEwMTVkZDVjMGVkMDg5MTkxNTg1ODBkOTQ0MjUwYjFkNTU0MWZhZWZjNjQsZXlKdVlXMWxJam9pU25Od2NtVmhaSE5vWldWMElpd2laR0YwWlNJNk1UWTJORFF4T0RJMk5Dd2laRzl0WVdsdUlqcGJJbXB6Y0hKbFlXUnphR1ZsZEM1amIyMGlMQ0pqYjJSbGMyRnVaR0p2ZUM1cGJ5SXNJbXB6YUdWc2JDNXVaWFFpTENKamMySXVZWEJ3SWl3aWJHOWpZV3hvYjNOMElsMHNJbkJzWVc0aU9pSXpJaXdpYzJOdmNHVWlPbHNpZGpjaUxDSjJPQ0lzSW5ZNUlpd2lZMmhoY25Seklpd2labTl5YlhNaUxDSm1iM0p0ZFd4aElpd2ljR0Z5YzJWeUlpd2ljbVZ1WkdWeUlpd2lZMjl0YldWdWRITWlMQ0pwYlhCdmNuUWlMQ0ppWVhJaUxDSjJZV3hwWkdGMGFXOXVjeUlzSW5ObFlYSmphQ0pkTENKa1pXMXZJanAwY25WbGZRPT0=',
});
</script>

<textarea id='log' style='width:400px;height:100px;'></textarea>

<input type='button' onclick="document.getElementById('log').value =
    JSON.stringify(document.getElementById('spreadsheet').jexcel.getJson())"
    value='Get JSON'>
    
</html>