You need to sign in to do that
Don't have an account?
AJAX tool kit and log file
Hi Everyone,
I am new to ajax tool kit.
The code works fine,since i am using the log to write the log .
But the log are not getting displayed in debug logs.
Where to see that logs can any one help me out
Thanks
<apex:page >
<script type="text/javascript">
var __sfdcSessionId = '{!GETSESSIONID()}';
alert( __sfdcSessionId);
</script>
<script src="../../soap/ajax/27.0/connection.js"
type="text/javascript"></script>
<script type="text/javascript">
window.onload = setupPage;
function setupPage()
{
try{
result = sforce.connection.query("Select Name, Id from Account");
records = result.getArray("records");
for (var i=0; i< records.length; i++) {
var record = records[i];
alert(record.Name + " -- " + record.Id);
log(record.Name + " -- " + record.Id);
}
}catch(error) {
if (error.faultcode.indexOf("INVALID_QUERY_SCOPE") != -1) {
log("check for the query");
} else {
log(error);
}
}
}
</script>
<div id="output"> </div>
</apex:page>
Suppose if i use the alert i can see all the records
alert(record.Name + " -- " + record.Id);
i want to write the log
log(record.Name + " -- " + record.Id);
where can i see all the records .
Regards
Madhu